
    Eg                     6    d dl mZmZ d dlmZ  G d de      Zy)    )GioCScreensaver)
BaseClientc                   <     e Zd ZdZdZdZ fdZd Zd Zd Z	 xZ
S )CinnamonClientz
    Simple client to talk to Cinnamon's dbus interface.  Currently
    its only use is for attempting to force an exit from overview
    and expo mode (both of which do a fullscreen grab and would prevent
    the screensaver from acquiring one.)
    zorg.Cinnamonz/org/Cinnamonc                     t         t        |   t        j                  j
                  t        j                  | j                  | j                         y N)
superr   __init__r   BusTypeSESSIONr   CinnamonProxyCINNAMON_SERVICECINNAMON_PATH)self	__class__s    ;/usr/share/cinnamon-screensaver/dbusdepot/cinnamonClient.pyr   zCinnamonClient.__init__   s:    nd,S[[-@-@-9-G-G-1-B-B-1-?-?	A    c                      y r	    r   s    r   on_client_setup_completez'CinnamonClient.on_client_setup_complete   s    r   c                     | j                         r9| j                  j                  dd       | j                  j                  dd       y y )Nzoverview-activeFzexpo-active)ensure_proxy_aliveproxyset_propertyr   s    r   exit_expo_and_overviewz%CinnamonClient.exit_expo_and_overview   s<    ""$JJ##$5u=JJ##M59 %r   c                     t        dd       y )NzeFailed to connect to Cinnamon - screensaver will not activate when expo or overview modes are active.T)flush)print)r   argss     r   
on_failurezCinnamonClient.on_failure   s    u  ~B  	Cr   )__name__
__module____qualname____doc__r   r   r   r   r   r"   __classcell__)r   s   @r   r   r      s+     &&MA:
Cr   r   N)gi.repositoryr   r   dbusdepot.baseClientr   r   r   r   r   <module>r*      s    , +CZ Cr   