+
     iF  c                  s   R t ^ RIHt ^ RIt^ RIt^ RIHt ^ RIHt ^ RI	t	^ RI
Ht ]	P                  ! RR4       ]	P                  ! RR	4       ]	P                  ! R
R4       ^ RIHt ]P                  ! 4        ^ RIHtHt ^ RIHt ^ RIHtHt ^ RIHt ^ RIHtHt ^ RIHt ^ RIH t  ^ RI!H"t" ^ RI#H$t$ ^ RI%H&t&H't' ^ RI(H)t) ^ RI*H+t+ ^ RI,H-t- ^ RI.H/t/  ! R R4      t0R# )zStarts the user interface.)annotationsN)ArgumentParser)Tuple)ProcessUtilsGtkz3.0ZGLibz2.0Z	GtkSourceZ4)r   )_
LOCALE_DIR)ReaderService)DaemonProxyDaemon)logger)MessageBrokerMessageType)keyboard_layout)DataManager)UserInterface)
Controller)GlobalUInputsFrontendUInput)_Groups)ReaderClient)GlobalConfig)
Migrationsc                  sL    ] tR t^9t]R R l4       t]R 4       t]R 4       tRtR# )InputRemapperGtkBinc               s    V ^8  d   QhRR/# )i   ZreturnzWTuple[UserInterface, Controller, DataManager, MessageBroker, DaemonProxy, GlobalConfig] )formats   "I/usr/lib/python3.14/site-packages/inputremapper/bin/input_remapper_gtk.pyZ__annotate__Z InputRemapperGtkBin.__annotate__;   s     I
 I
  I
    c            	     	s  a	a
 \        4       p V P                  R RRR\        R4      RR7       V P                  \        P
                  R,          4      p\        P                  ! VP                  4       \        P                  ! R4       \        P                  ! R	P                  \        4      4       \        \        4      p\        V4      pVP                  4        \!        4       p\#        4       p\%        V\'        4       4      p\(        P*                  ! R4      ^8  d   \        P,                  ! R
4       \.        P1                  4        \2        P4                  ! 4       o
\7        VVVS
V\8        4      p\;        WG4      o	\=        VS	4      pS	P?                  V4       VPA                  \B        PD                  4       \F        PH                  ! V	V
3R l4       \J        PL                  ! 4        VS	VVS
V3# )z-dz--debugZ
store_truedebugz%Displays additional debug informationF)ZactionZdestZhelpZdefault:i   NNzinput-remapper-gtkzUsing locale directory: {}z[Another input-remapper GUI is already running. This can cause problems while recording keysc                 s0   < \         P                  SS 4      # N)r   stop)
controllerdaemons   r   Z<lambda>Z*InputRemapperGtkBin.main.<locals>.<lambda>x   s     3 8 8 Lr   )'r   Zadd_argumentr   Z
parse_argssysZargvr
   Zupdate_verbosityr   Zlog_infor   r   r   r   r   Zmigrater   r   r   r   r   count_python_processesZwarningr   start_reader_servicer	   Zconnectr   r   r   r   Zset_guiZsignalr   initatexitZregisterr   main)ZparserZoptionsZglobal_uinputsZ
migrationsZmessage_brokerZglobal_configZreader_clientZdata_managerZuser_interfacer   r    s            @@r   r&   ZInputRemapperGtkBin.main:   s     !:; 	 	
 ##CHHRL1.,-188DE&~6/
&$
 %^WY?../CDINN?
 	002!"
  =
&~zB>*k../LM
 
 	
r   c                 	s"   \         P                  ! R 4      ^8  d   \        P                  ! R4       R#  \        P
                  ! 4        R#   \         d8   p \        P                  ! T 4       \        P                  ! ^4        Rp ? R# Rp ? ii ; i)zinput-remapper-reader-servicez<Found an input-remapper-reader-service to already be runningN)
r   r"   r
   Zinfor   Zpkexec_reader_serviceZ	ExceptionZerrorr!   Zexit)Zes    r   r#   Z(InputRemapperGtkBin.start_reader_service   s`    ../NOSTTKKVW	//1 	LLOHHRLL	s   A B,B		Bc                	sr    \        V \        4      '       d   V P                  4        VP                  4        R # r   )Z
isinstancer	   Zstop_allZclose)r    r   s   &&r   r   ZInputRemapperGtkBin.stop   s%    ff%%OOr   r   N)	Z__name__Z
__module__Z__qualname__Z__firstlineno__Zstaticmethodr&   r#   r   Z__static_attributes__r   r   r   r   r   9   s?    I
 I
V 	 	  r   r   )1Z__doc__Z
__future__r    r%   r!   Zargparser   Ztypingr   ZgiZinputremapper.bin.process_utilsr   Zrequire_versionZgi.repositoryr   r$   Zinputremapper.gui.gettextr   r   Z inputremapper.gui.reader_servicer   Zinputremapper.daemonr   r	   Zinputremapper.logging.loggerr
   Z)inputremapper.gui.messages.message_brokerr   r   Z%inputremapper.configs.keyboard_layoutr   Zinputremapper.gui.data_managerr   Z inputremapper.gui.user_interfacer   Zinputremapper.gui.controllerr   Z&inputremapper.injection.global_uinputsr   r   Zinputremapper.groupsr   Zinputremapper.gui.reader_clientr   Z#inputremapper.configs.global_configr   Z inputremapper.configs.migrationsr   r   r   r   r   <module>r'      s   ( ! "  
 #  	 8   5%     65 !   ; $  
 3 : 4 / P A 6 : 3 P ( 8 < 7_ _r   