ó
    Ö›‘h®  ã                   óö   • S r SSKJr  SSKJr  SSKJr  SSKJr  SSK	J
r
  \" \SS5      b  \R                  " 5          " S	 S
\R                  5      r " S S\R                  5      rSS\S\\\4   4S jjrS/rg)aÕ  
This module provides support for Twisted to interact with the glib
mainloop via GObject Introspection.

In order to use this support, simply do the following::

    from twisted.internet import gireactor
    gireactor.install()

If you wish to use a GApplication, register it with the reactor::

    from twisted.internet import reactor
    reactor.registerGApplication(app)

Then use twisted.internet APIs as usual.

On Python 3, pygobject v3.4 or later is required.
é    )ÚUnion)ÚGLib)Ú	_glibbase)ÚReactorAlreadyRunning)ÚruntimeÚthreads_initNc                   ó,   • \ rS rSrSrSrSS jrS rSrg)Ú	GIReactoré$   z•
GObject-introspection event loop reactor.

@ivar _gapplication: A C{Gio.Application} instance that was registered
    with C{registerGApplication}.
Nc                 óN   • [         R                  R                  U [        S 5        g ©N)r   ÚGlibReactorBaseÚ__init__r   )ÚselfÚuseGtks     Ú^C:\Users\psant\Downloads\Noiseback\school\venv\Lib\site-packages\twisted/internet/gireactor.pyr   ÚGIReactor.__init__/   s   € Ü×!Ñ!×*Ñ*¨4´°tÕ<ó    c                 óî   ^• U R                   b  [        S5      eU R                  (       a  [        S5      e[	        TS5      (       d  [        S5      eTU l         U4S jnX l        TR                  U l        g)aK  
Register a C{Gio.Application} or C{Gtk.Application}, whose main loop
will be used instead of the default one.

We will C{hold} the application so it doesn't exit on its own. In
versions of C{python-gi} 3.2 and later, we exit the event loop using
the C{app.quit} method which overrides any holds. Older versions are
not supported.
Nz2Can't register more than one application instance.z5Can't register application after reactor was started.ÚquitzPApplication registration is not supported in versions of PyGObject prior to 3.2.c                  óH   >• T R                  5         T R                  S 5        g r   )ÚholdÚrun)Úapps   €r   r   Ú+GIReactor.registerGApplication.<locals>.runI   s   ø€ Ø�H‰HŒJØ�G‰G�D�Mr   )Ú_gapplicationÚRuntimeErrorÚ_startedr   ÚhasattrÚ_runr   Ú_crash)r   r   r   s    ` r   ÚregisterGApplicationÚGIReactor.registerGApplication2   sv   ø€ ð ×ÑÑ)ÜÐSÓTÐTØ�=�=Ü'ØGóð ô �s˜F×#Ñ#Üð7óð ð !ˆÔõ	ð Œ	à—h‘hˆ�r   )r!   r   r    ©F)	Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__r   r   r"   Ú__static_attributes__© r   r   r
   r
   $   s   † ñð €Mô=õr   r
   c                   ó@   ^ • \ rS rSrSrSU 4S jjrS rSS jrSrU =r	$ )	ÚPortableGIReactoréR   z4
Portable GObject Introspection event loop reactor.
c                 ó,   >• [         TU ]  [        S US9  g )N©r   )Úsuperr   r   )r   r   Ú	__class__s     €r   r   ÚPortableGIReactor.__init__W   s   ø€ Ü‰Ñœ˜t¨FÐÒ3r   c                 ó   • [        S5      e)zo
Register a C{Gio.Application} or C{Gtk.Application}, whose main loop
will be used instead of the default one.
z3GApplication is not currently supported on Windows.)ÚNotImplementedError)r   r   s     r   r"   Ú&PortableGIReactor.registerGApplicationZ   s   € ô
 "Ð"WÓXÐXr   c                 ó   • g)z%
For compatibility only. Do nothing.
Nr+   )r   s    r   ÚsimulateÚPortableGIReactor.simulatea   s   � r   r+   r$   )ÚreturnN)
r%   r&   r'   r(   r)   r   r"   r8   r*   Ú__classcell__)r2   s   @r   r-   r-   R   s   ø† ñ÷4òY÷ò r   r-   r   r:   c                 óŒ   • [         R                  R                  5       S:X  a
  [        U S9nO	[	        U S9nSSKJn  U" U5        U$ )z³
Configure the twisted mainloop to be run inside the glib mainloop.

@param useGtk: A hint that the Gtk GUI will or will not be used.  Currently
    does not modify any behavior.
Úposixr0   r   )ÚinstallReactor)r   ÚplatformÚgetTyper
   r-   Útwisted.internet.mainr>   )r   Úreactorr>   s      r   ÚinstallrC   g   s?   € ô ×Ñ×ÑÓ! WÓ,Ü 6Ñ*‰ä#¨6Ñ2ˆå4á�7ÔØ€Nr   rC   r$   )r)   Útypingr   Úgi.repositoryr   Útwisted.internetr   Útwisted.internet.errorr   Útwisted.pythonr   Úgetattrr   r   r
   r-   ÚboolrC   Ú__all__r+   r   r   Ú<module>rL      s‚   ðñõ( å å &Ý 8Ý "á
ˆ4� Ó&Ñ2Ø×ÒÔô+�	×)Ñ)ô +ô\˜	×1Ñ1ô ñ*�Dð  U¨9Ð6GÐ+GÑ%Hõ ð& ˆ+�r   