Your IP : 3.145.79.214


Current Path : /lib64/python3.6/site-packages/gi/overrides/__pycache__/
Upload File :
Current File : //lib64/python3.6/site-packages/gi/overrides/__pycache__/GObject.cpython-36.pyc

3

��<_�e�*@s~ddlZddlZddlmZddlZddlZddlmZmZddl	m
Z
ddlmZddlmZ
ddlmZddlmZejjd	�ZgZdd
lmZeZx6d�D].Zee
e�e�e<ed	ed$e�eje�q�WxXd�D]PZej��"ejdOe�ee
e�e�e<WdQRXed	ed$e�eje��q�WxHd�D]@Zejd\d]�d�Zee
e�e�e<ed	ed$e�eje��q0WxHd�D]@Zejd\d]�d�Zee
e�e�e<ed	ed$e�eje��qzWejdp�Z ejdq�Z!ejdr�Z"ejds�Z#ejdt�Z$ejdu�Z%ejdv�Z&ejdw�Z'ejdx�Z(ejdy�Z)ejdz�Z*ejd{�Z+ejd|�Z,ejd}�Z-ejd~�Z.ejd�Z/ejd��Z0ejd��Z1ejd��Z2ejd��Z3ejd	�Z4ejd��Z5ejd��Z6ejd��Z7ejd��Z8ejd��Z9ej:j;Z<e'Z=ed�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�g7Zx8d�D]0Zee
e�e�e<ed	ed$e�eje��qWxJd�D]BZejd\d]�d�Zeej>e�e�e<ed	ed�e�eje��qNWej>j?ej>j@BZAejd��eBej>d���r�ed	d�d��xLd�D]DZejd\d]��dZeejCe�e�e<ed	ed�e�eje��q�WejDZDejEZEejFZFejGZGejHZHejIZIejJZJejKZKejLZLejMZMed�d|d}drd	d�d�d�d�d�g
7ZejNZNejOZOejPZPejQZQe
jRZRejSZSed�d�d�d�d�d�g7ZGd�dńd�ej:�Z:ee:�Z:ejdŃd�dDŽZejdǃd�dɄZTejdɃd�d˄ZUd�d̈́ZVejd̓d�dτZWejdσd�dфZXejdуed�d�d�d�d�d�d�g�ZY�dd�dڄZZejdڃGd�d܄d�e[�Z\d�dބZ]ejdރd�d�Z^ejd�d�d�Z_ejd��dd�d�Z`ejd��dd�d�Zaejd�ejbZbejcZced�d�g7ZGd�d�d�e[�Zdd�d�ZeGd�d�d�ejf�Zfeef�ZfefZHed�d	g7ZGd�d�d�ejg�Zgeeg�Zgejd�e
jhZhejiZiejjZjehZked	d�d�ed�d�d�d�g7ZdS(�N)�
namedtuple)�override�deprecated_attr)�GLib)�PyGIDeprecationWarning)�_propertyhelper)�
_signalhelper)�_gi�GObject)�_option�markup_escape_text�get_application_name�set_application_name�get_prgname�set_prgname�
main_depth�filename_display_basename�filename_display_name�filename_from_utf8�uri_list_extract_uris�MainLoop�MainContext�main_context_default�
source_remove�Source�Idle�Timeout�PollFD�idle_add�timeout_add�timeout_add_seconds�io_add_watch�child_watch_add�get_current_time�spawn_asynczGLib.�PRIORITY_DEFAULT�PRIORITY_DEFAULT_IDLE�
PRIORITY_HIGH�PRIORITY_HIGH_IDLE�PRIORITY_LOW�IO_IN�IO_OUT�IO_PRI�IO_ERR�IO_HUP�IO_NVAL�IO_STATUS_ERROR�IO_STATUS_NORMAL�
IO_STATUS_EOF�IO_STATUS_AGAIN�IO_FLAG_APPEND�IO_FLAG_NONBLOCK�IO_FLAG_IS_READABLE�IO_FLAG_IS_WRITEABLE�IO_FLAG_IS_SEEKABLE�IO_FLAG_MASK�IO_FLAG_GET_MASK�IO_FLAG_SET_MASK�SPAWN_LEAVE_DESCRIPTORS_OPEN�SPAWN_DO_NOT_REAP_CHILD�SPAWN_SEARCH_PATH�SPAWN_STDOUT_TO_DEV_NULL�SPAWN_STDERR_TO_DEV_NULL�SPAWN_CHILD_INHERITS_STDIN�SPAWN_FILE_AND_ARGV_ZERO�OPTION_FLAG_HIDDEN�OPTION_FLAG_IN_MAIN�OPTION_FLAG_REVERSE�OPTION_FLAG_NO_ARG�OPTION_FLAG_FILENAME�OPTION_FLAG_OPTIONAL_ARG�OPTION_FLAG_NOALIAS�OPTION_ERROR_UNKNOWN_OPTION�OPTION_ERROR_BAD_VALUE�OPTION_ERROR_FAILED�OPTION_REMAINING�glib_version�ignore�	G_MININT8�	G_MAXINT8�
G_MAXUINT8�
G_MININT16�
G_MAXINT16�G_MAXUINT16�
G_MININT32�
G_MAXINT32�G_MAXUINT32�
G_MININT64�
G_MAXINT64�G_MAXUINT64�_��
G_MINFLOAT�
G_MAXFLOAT�G_MINDOUBLE�G_MAXDOUBLE�
G_MINSHORT�
G_MAXSHORT�G_MAXUSHORT�G_MININT�G_MAXINT�	G_MAXUINT�	G_MINLONG�	G_MAXLONG�
G_MAXULONG�	G_MAXSIZE�
G_MINSSIZE�
G_MAXSSIZE�G_MINOFFSET�G_MAXOFFSETZinvalid�void�
GInterfaceZgcharZgucharZgbooleanZgintZguintZglongZgulongZgint64Zguint64�GEnum�GFlagsZgfloatZgdoubleZ
gchararrayZgpointer�GBoxedZGParamZPyObject�GTypeZGStrvZGVariantZGString�TYPE_INVALID�	TYPE_NONE�TYPE_INTERFACE�	TYPE_CHAR�
TYPE_UCHAR�TYPE_BOOLEAN�TYPE_INT�	TYPE_UINT�	TYPE_LONG�
TYPE_ULONG�
TYPE_INT64�TYPE_UINT64�	TYPE_ENUM�
TYPE_FLAGS�
TYPE_FLOAT�TYPE_DOUBLE�TYPE_STRING�TYPE_POINTER�
TYPE_BOXED�
TYPE_PARAM�TYPE_OBJECT�
TYPE_PYOBJECT�
TYPE_GTYPE�	TYPE_STRV�TYPE_VARIANT�TYPE_GSTRING�TYPE_UNICHAR�
TYPE_VALUE�Pid�GError�OptionGroup�
OptionContext�PARAM_CONSTRUCT�PARAM_CONSTRUCT_ONLY�PARAM_LAX_VALIDATION�PARAM_READABLE�PARAM_WRITABLEzGObject.ParamFlags.�PARAM_READWRITEZ	READWRITEz)GObject.ParamFlags.READWRITE (glib 2.42+)�
SIGNAL_ACTION�SIGNAL_DETAILED�SIGNAL_NO_HOOKS�SIGNAL_NO_RECURSE�SIGNAL_RUN_CLEANUP�SIGNAL_RUN_FIRST�SIGNAL_RUN_LASTzGObject.SignalFlags.�GObjectWeakRef�
GParamSpec�GPointer�Warning�features�list_properties�new�pygobject_version�threads_init�
type_registercsNeZdZddd�Z�fdd�Zdd�Zdd	�Zd
d�Zdd
�Zdd�Z	�Z
S)�ValueNcCs4tjj|�|dk	r0|j|�|dk	r0|j|�dS)N)�
GObjectModuler��__init__Zinit�	set_value)�selfZ
value_type�py_value�r��/usr/lib64/python3.6/GObject.pyr��s

zValue.__init__cs*|jr|jtkr|j�tt|�j�dS)N)Z_free_on_dealloc�g_typervZunset�superr��__del__)r�)�	__class__r�r�r��sz
Value.__del__cCstj||�dS)N)r	Z_gvalue_set)r�Zboxedr�r�r��	set_boxed�szValue.set_boxedcCs
tj|�S)N)r	Z_gvalue_get)r�r�r�r��	get_boxed�szValue.get_boxedcCs�|j}|tjkrtd���nb|tkr2|j|��nL|tkrH|j|��n6|tkr^|j	|��n |t
krt|j|��n
|tkr�|j
|��n�|tkr�|j|��n�|tkr�|j|��n�|tkr�|j|��n�|tkr�|j|��n�|tkr�|j|��n�|tk�r|j|��nn|tk�r�t|t��r0t|�}nNtjdk�rjt|t��rT|j d�}nt!d|t"|�f��nt!d|t"|�f��|j#|�n�|t$k�r�|j%|�n�|j&t'��r�|j(|�n�|j&t)��r�|j*|�n�|j&t+��r�|j,|�n�|t-k�r�|j.|�n�|j&t/��r|j0|�nh|t1k�r0|j
t2|��nN|t3k�rF|j4|�n8|t5k�r\|j6|�n"|t7k�rr|j,|�ntd|��dS)	Nz+GObject.Value needs to be initialized first�rzUTF-8z'Expected string or unicode but got %s%szExpected string but got %s%szUnknown value type %s)r�r)8r�r	rv�	TypeErrorr{Zset_booleanryZset_charrzZ	set_ucharr|Zset_intr}Zset_uintr~Zset_longrZ	set_ulongr�Z	set_int64r�Z
set_uint64r�Z	set_floatr�Z
set_doubler��
isinstance�str�sys�version_infoZunicode�encode�
ValueError�typeZ
set_stringr�Z	set_param�is_ar�Zset_enumr�Z	set_flagsr�r�r�Zset_pointerr�Z
set_objectr��intr�Z	set_gtyper�Zset_variantr�)r�r��gtyper�r�r�r��sr









zValue.set_valuecCs�|j}|tkr|j�S|tkr&|j�S|tkr6|j�S|tkrF|j�S|t	krV|j
�S|tkrf|j�S|t
krv|j�S|tkr�|j�S|tkr�|j�S|tkr�|j�S|tkr�|j�S|tkr�|j�S|tk�r�|j�S|jt��r�|j�S|jt��r|j�S|jt ��r|j!�S|t"k�r&|j#�S|jt$��r:|j%�S|t&k�rL|j
�S|t'k�r^|j(�S|t)k�rp|j*�S|t+k�r|ndSdS)N),r�r{Zget_booleanryZget_charrzZ	get_ucharr|Zget_intr}Zget_uintr~Zget_longrZ	get_ulongr�Z	get_int64r�Z
get_uint64r�Z	get_floatr�Z
get_doubler�Z
get_stringr�Z	get_paramr�r�Zget_enumr�Z	get_flagsr�r�r�Zget_pointerr�Z
get_objectr�r�Z	get_gtyper�Zget_variantr�)r�r�r�r�r��	get_value-s\





zValue.get_valuecCsd|jj|j�fS)Nz<Value (%s) %s>)r��namer�)r�r�r�r��__repr___szValue.__repr__)NN)�__name__�
__module__�__qualname__r�r�r�r�r�r�r��
__classcell__r�r�)r�r�r��s
A2r�cCs"tj|�}|tkrtd|��|S)Nzunknown type name: %s)r��type_from_namerv�RuntimeError)r��type_r�r�r�r�gs
r�cCstj|�}|tkrtd��|S)Nzno parent for type)r��type_parentrvr�)r��parentr�r�r�r�qs
r�cCs4t|d�r|j}|j�r0|j�r0td|��dS)N�	__gtype__z1type must be instantiable or an interface, got %s)�hasattrr�Zis_instantiatableZis_interfacer�)r�r�r�r�� _validate_type_for_signal_method{s
r�cCst|�tj|�S)N)r�r��signal_list_ids)r�r�r�r�r��sr�cCst|�}tdd�|D��S)Ncss|]}tj|�VqdS)N)r��signal_name)�.0�ir�r�r��	<genexpr>�sz$signal_list_names.<locals>.<genexpr>)r��tuple)r�Zidsr�r�r��signal_list_names�sr�cCst|�tj||�S)N)r�r��
signal_lookup)r�r�r�r�r�r��sr��SignalQuery�	signal_idr��itype�signal_flags�return_type�param_typescCsX|dk	rt||�}tj|�}|dkr(dS|jdkr6dSt|j|j|j|j|jt	|j
��S)Nr)r�r��signal_queryr�r�r�r�r�r�r�r�)Z
id_or_namer��resr�r�r�r��s


r�c@s$eZdZdd�Zdd�Zdd�ZdS)�_HandlerBlockManagercCs||_||_dS)N)�obj�
handler_id)r�r�r�r�r�r�r��sz_HandlerBlockManager.__init__cCsdS)Nr�)r�r�r�r��	__enter__�sz_HandlerBlockManager.__enter__cCstj|j|j�dS)N)r��signal_handler_unblockr�r�)r��exc_type�	exc_value�	tracebackr�r�r��__exit__�sz_HandlerBlockManager.__exit__N)r�r�r�r�r�r�r�r�r�r�r��sr�cCstj||�t||�S)a�Blocks the signal handler from being invoked until
    handler_unblock() is called.

    :param GObject.Object obj:
        Object instance to block handlers for.
    :param int handler_id:
        Id of signal to block.
    :returns:
        A context manager which optionally can be used to
        automatically unblock the handler:

    .. code-block:: python

        with GObject.signal_handler_block(obj, id):
            pass
    )r��signal_handler_blockr�)r�r�r�r�r�r��sr�cCs4tj|||�\}}}|r ||fStd||f��dS)a%Parse a detailed signal name into (signal_id, detail).

    :param str detailed_signal:
        Signal name which can include detail.
        For example: "notify:prop_name"
    :returns:
        Tuple of (signal_id, detail)
    :raises ValueError:
        If the given signal is unknown.
    z%s: unknown signal name: %sN)r��signal_parse_namer�)�detailed_signalr�Zforce_detail_quarkr�r��detailr�r�r�r��s
r�cCs t||d�\}}tj||�dS)NT)r�r�Zsignal_remove_emission_hook)r�r�Zhook_idr�r�r�r�r��remove_emission_hook�sr�cCsd|fS)NFr�)�ihint�return_accu�handler_return�	user_datar�r�r��signal_accumulator_first_winssr�cCs
||fS)Nr�)r�r�r�r�r�r�r��signal_accumulator_true_handledsr��add_emission_hook�
signal_newc@s$eZdZdd�Zdd�Zdd�ZdS)�_FreezeNotifyManagercCs
||_dS)N)r�)r�r�r�r�r�r�sz_FreezeNotifyManager.__init__cCsdS)Nr�)r�r�r�r�r�sz_FreezeNotifyManager.__enter__cCs|jj�dS)N)r�Zthaw_notify)r�r�r�r�r�r�r�r�sz_FreezeNotifyManager.__exit__N)r�r�r�r�r�r�r�r�r�r�r�sr�cstjj���fdd��}|S)Ncs
�||�S)Nr�)�args�kwargs)�funcr�r��meth'sz_signalmethod.<locals>.meth)�giZ	overrides�wraps)r�rr�)r�r��
_signalmethod#srcsjeZdZdd�Zdd�ZeZeZeZeZeZ	eZ
eZeZeZ
eZeZeZeZeZeZejjZejjZejjZejjZeZeZeZeZejj Z ejj!Z!ejj"Z"ejj#Z#ejj$Z$ejj%Z%ejj&Z&ejj'Z'ejj(Z(ejj)Z)ejj*Z*ejj+Z+ejj,Z,ejj-Z-ejj.Z.ejj/Z/ejj0Z0�fdd�Z1dd�Z2e3Z4e5ej6�Z7e5ej8�Z9e5ej8�Z:e5ej;�Z<e5ej=�Z>d	d
�Z?e?Z@�ZAS)�ObjectcOstd��dS)Nz%This method is currently unsupported.)r�)r�r��kargsr�r�r��_unsupported_method.szObject._unsupported_methodcOstd��dS)NzIData access methods are unsupported. Use normal Python attributes instead)r�)r�r�rr�r�r��_unsupported_data_method1szObject._unsupported_data_methodcstt|�j�t|�S)a�Freezes the object's property-changed notification queue.

        :returns:
            A context manager which optionally can be used to
            automatically thaw notifications.

        This will freeze the object so that "notify" signals are blocked until
        the thaw_notify() method is called.

        .. code-block:: python

            with obj.freeze_notify():
                pass
        )r�r�
freeze_notifyr�)r�)r�r�r�riszObject.freeze_notifycst|jdd�}|tjj@r"tjj}ntjj}|tjj@r^t	|�dkrPt
d|g���fdd�}n�}||||f|��S)aConnect a callback to the given signal with optional user data.

        :param str detailed_signal:
            A detailed signal to connect to.
        :param callable handler:
            Callback handler to connect to the signal.
        :param *data:
            Variable data which is passed through to the signal handler.
        :param GObject.ConnectFlags connect_flags:
            Flags used for connection options.
        :returns:
            A signal id which can be used with disconnect.
        Z
connect_flagsrr]zWUsing GObject.ConnectFlags.SWAPPED requires exactly one argument for user data, got: %scs(t|�}|j�}||g}�|f|��S)N)�list�pop)r�r�Zswap)�handlerr�r��new_handler�s
z(Object.connect_data.<locals>.new_handler)�getr�ZConnectFlagsZAFTERr	r
�
connect_after�connectZSWAPPED�lenr�)r�r�r�datar��flagsZconnect_funcrr�)rr��connect_data{s

zObject.connect_datacCstj|jjtdd�|j|�S)z-Deprecated, please use stop_emission_by_name.�)�
stacklevel)�warnings�warn�
stop_emission�__doc__r�stop_emission_by_name)r�r�r�r�r�r�szObject.stop_emission)Br�r�r�rr�get_dataZ	get_qdata�set_dataZ
steal_dataZsteal_qdataZreplace_dataZ
replace_qdataZbind_property_fullZcompat_controlZinterface_find_propertyZinterface_install_propertyZinterface_list_propertiesZnotify_by_pspecZrun_disposeZ
watch_closurer�r�refZ_refZref_sinkZ	_ref_sinkZunrefZ_unrefZforce_floatingZ_force_floatingr	r
Zget_propertyZget_propertiesZset_propertyZset_propertiesZ
bind_propertyrrZconnect_objectZconnect_object_afterZdisconnect_by_funcZhandler_block_by_funcZhandler_unblock_by_func�emit�chainZweak_ref�__copy__�__deepcopy__rrr�Z
handler_blockrr�Zhandler_unblockZsignal_handler_disconnectZ
disconnectZhandler_disconnectZsignal_handler_is_connectedZhandler_is_connectedZsignal_stop_emission_by_namerrZemit_stop_by_namer�r�r�)r�r�r-sh)




rcs$eZdZdd�Z�fdd�Z�ZS)�BindingcCstjdtdd�|S)Nz�Using parentheses (binding()) to retrieve the Binding object is no longer needed because the binding is returned directly from "bind_property.r)r)rrr)r�r�r�r��__call__�s
zBinding.__call__cs2t|d�rtd��nt|dd�tt|�j�dS)NZ_unboundz$binding has already been cleared outT)r�r��setattrr�r"�unbind)r�)r�r�r�r%�s

zBinding.unbind)r�r�r�r#r%r�r�r�)r�r�r"�sr"�propertyzGObject.Property�Property�Signal�SignalOverride)rr
rrrrrrrrrrrrrrrrrrr r!r"r#r$)*r%r&r'r(r)r*r+r,r-r.r/r0r1r2r3r4r5r6r7r8r9r:r;r<r=r>r?r@rArBrCrDrErFrGrHrIrJrKrLrMrN)rPrQrRrSrTrUrVrWrXrYrZr[���)r^r_r`rarbrcrdrerfrgrhrirjrkrlrmrnror*)r�r�r�r�)r�r�r�r�r�r*)r�r�r�r�r�r�r�r*)N)N)N)lr�r�collectionsrZgi.overridesrZ	gi.modulerrZ
gi.repositoryrrrZpropertyhelperrZsignalhelperr	�moduleZget_introspection_moduler��__all__rZoptionr��getattr�globals�append�catch_warnings�simplefilter�split�new_namer�rvrwrxryrzr{r|r}r~rr�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�Z
ParamFlagsZREADABLEZWRITABLEr�r�ZSignalFlagsrtrrrsrqr
r�r�r�rur�r�r�r�r�r�r�r�r�r�r�r�r�r��objectr�r�r�r�r�r�r�r�r�rrr"r'r(r)r&r�r�r�r��<module>s�

















































?>