%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/share/system-config-printer/troubleshoot/__pycache__/
Upload File :
Create Path :
Current File : //usr/share/system-config-printer/troubleshoot/__pycache__/PrinterStateReasons.cpython-312.pyc

�

Hfm��`�ddlmZddlZddlZddlZddlmZddl�ddlm	Z	Gd�de
�Zy)	�)�GtkN)�TimedOperation�)�*)�reducec�$�eZdZd�Zd�Zd�Zd�Zy)�PrinterStateReasonsc�z�tj||d�|jtd�td��}t	j
�|_|jjdd�|jjd�|j|jddd�|j||�y)NzPrinter state reasonszStatus Messagesz5There are status messages associated with this queue.rTF)�Question�__init__�initial_vbox�_r�Label�label�
set_alignment�
set_line_wrap�
pack_start�new_page)�self�troubleshooter�pages   �D/usr/share/system-config-printer/troubleshoot/PrinterStateReasons.pyrzPrinterStateReasons.__init__ s������4��1H�I�� � �!�$5�"6�"#�%2�#3�4���Y�Y�\��
��
�
� � �!�Q�'��
�
� � �$�'�������U�E�1�5�����t�,�c�B�|j}	|jd}|jj�}t	j
d�t
tj|��|_|jj�}t
|j|f|��|_|jj�}tj�}d}|d}|r|td�|zz
}|dz
}|d	}	t|	�tk(r|	g}	||_|	|_g}
g}|	D]�}|d
k(r�	t%j&|||�}
|
j)�\}}|
j+�}|t$j&j,k(r|
j/|��r|t$j&j0k(s��|j/|���|
r&|td�dzz
}|t3d
�|
�z
}|dz
}|r!|td�dzz
}|t3d�|�z
}|j4j7|�|dk(rt9|
�dk(rt9|�dk(ryd|jvr9|jd|j k(r|jd	|j"k(ryy#t$rYywxYw)N�
cups_queueF�)�parent)�argsr�printer-state-messagez%The printer's state message is: '%s'.z

�printer-state-reasons�nonezErrors are listed below:�
c��|dz|zS�Nr"���x�ys  r�<lambda>z-PrinterStateReasons.display.<locals>.<lambda>[����T��A��rzWarnings are listed below:c��|dz|zSr$r%r&s  rr)z-PrinterStateReasons.display.<locals>.<lambda>`r*rrT)r�answers�KeyError�
get_window�cups�	setServerr�
Connection�op�run�getPrinterAttributes�ppdcache�PPDCacher�type�str�
state_message�
state_reasons�statereason�StateReason�get_description�	get_level�ERROR�append�WARNINGrr�set_text�len)rr�queuer�c�dict�the_ppdcache�textr9�state_reasons_list�human_readable_errors�human_readable_warnings�reason�r�title�description�levels                 r�displayzPrinterStateReasons.display,s����,�,��	�"�*�*�<�8�E��$�$�/�/�2������� �$�/�/�&�A����G�G�K�K�N�� �!�"8�"8�(-�x�)/�1����w�w�{�{�~���(�(�+�����4�5�
���A�=�>��N�N�D��F�N�D�!�"9�:���#�$��+�"4�!5��*���/��� "��"$��(�
	=�F������'�'����E�A�#$�#4�#4�#7� �U�K��K�K�N�E���/�/�5�5�5�%�,�,�k�:��+�1�1�9�9�9�'�.�.��<�
	=�!��A�0�1�D�8�8�D��F�5�7L�M�M�D��F�N�D�"��A�2�3�d�:�:�D��F�5�7N�O�O�D��
�
���T�"��R���&�'�1�,��(�)�Q�.��#�n�&<�&<�<��&�&�'>�?��"�"�#��&�&�'>�?��"�"�#����C�	��	�s�J�	J�Jc�P�|jsiS|j|jd�S)N)rr )�	displayedr9r:�rs r�collect_answerz"PrinterStateReasons.collect_answerss*���~�~��I�*.�*<�*<�*.�*<�*<�?�	?rc�8�|jj�y)N)r2�cancelrTs r�cancel_operationz$PrinterStateReasons.cancel_operationzs�������rN)�__name__�
__module__�__qualname__rrQrUrXr%rrr	r	s��
-�E�N?�rr	)�
gi.repositoryrr/r5r;�timedopsr�base�	functoolsrrr	r%rr�<module>r`s*��.����#���\�(�\r

Zerion Mini Shell 1.0