| Server IP : 209.205.66.10 / Your IP : 216.73.216.173 Web Server : Apache/2.4.52 (Ubuntu) System : Linux ammon 5.15.0-186-generic #196-Ubuntu SMP Sat Jun 20 16:09:34 UTC 2026 x86_64 User : ( 1006) PHP Version : 8.5.8 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/share/hplip/ui5/__pycache__/ |
Upload File : |
o
�K0j�0 � @ s� d dl T d dlmZmZ d dlmZ d dlT ddlT d dlm Z d dl
mZ d dlT d dl
T d dlT ddlmZ d dlZd ZdZG d d
� d
ee�ZdS )� )�*)�device�utils)�cups� )�
pluginhandler)�
to_unicode)� Ui_DialogNc @ s� e Zd Zeefdd�Zdd� Zdd� Zdd� Zd d
� Z dd� Z
d
d� Zdd� Zdd� Z
dd� Zdd� Zdd� Zdd� Zdd� Zdd� Zdd � Zd!d"� Zd&d$d%�Zd#S )'�PluginDialogc C sn t �| |� || _|| _d| _d| _t�� | _| � | � t
� | _| j�� | j�
� | �� t�d| j� d S )N� Fr )�QDialog�__init__�install_mode�
plugin_reason�plugin_path�resultr �PluginHandle� pluginObj�setupUi�UserSettings�
user_settings�load�debug�initUi�QTimer�
singleShot�showSourcePage)�self�parentr r � r �$/usr/share/hplip/ui5/plugindialog.pyr
0 s
zPluginDialog.__init__c C s
| j �� S �N)r � getStatus�r r r r �isPluginInstalledB s
zPluginDialog.isPluginInstalledc C s� | j j�| j� | jj�| j� | �ttdd��� i t d �t
| �d��t| �d��t
| �d��t| �d��td �td �t| �d��t| �d��t| �d ��td �td �t| �d
��t| �d��td �td �| _d S )N�hp_logo�128x128z)This plugin will enable printing support.z%This plugin will enhance print speed.z'This plugin will enhance print quality.z'This plugin will add printing features.z)This plugin will enable scanning support.z(This plugin will enhance scanning speed.z0This plugin will enhance scanning image quality.z'This plugin will enable faxing support.z)This plugin will enhnace faxing features.)�CancelButton�clicked�connect�CancelButton_clicked�
NextButton�NextButton_clicked�
setWindowIcon�QIcon�load_pixmap�PLUGIN_REASON_NONE�PLUGIN_REASON_PRINTING_SUPPORT�_PluginDialog__tr�PLUGIN_REASON_FASTER_PRINTING� PLUGIN_REASON_BETTER_PRINTING_PQ�PLUGIN_REASON_PRINTING_FEATURES�PLUGIN_REASON_RESERVED_10�PLUGIN_REASON_RESERVED_20�PLUGIN_REASON_SCANNING_SUPPORT�PLUGIN_REASON_FASTER_SCANNING� PLUGIN_REASON_BETTER_SCANNING_IQ�PLUGIN_REASON_RESERVED_200�PLUGIN_REASON_RESERVED_400�PLUGIN_REASON_FAXING_SUPPORT�PLUGIN_REASON_FAX_FEATURES�PLUGIN_REASON_RESERVED_20000�PLUGIN_REASON_RESERVED_40000�PLUGIN_REASON_TEXTr# r r r r F sH �
�
�
�
���
�
�
���
�
��
�zPluginDialog.initUic C s | � � }| jtkr%| j�d� d}|d ur|d| 7 }| j�| �|�� n| jtkr?d}|d ur6|d| 7 }| j�| �|�� | j j
t �| j
� | jj
t �| j� | jj
t �| j� | jjd �| j� | jj�| j� t�tjtj� | j�ttdd��� | �t� d S )NFz�An additional driver plug-in is required to operate this printer. You may download the plug-in directly from an HP authorized server (recommended), or, if you already have a copy of the file, you can specify a path to the file (advanced).z
<br><br>%sa( An optional driver plug-in is available to enhance the operation of this printer. You may download the plug-in directly from an HP authorized server (recommended), skip this installation (not recommended), or, if you already have a copy of the file, you can specify a path to the file (advanced).zconst QString &�folder_open�16x16)�plugin_reason_textr �PLUGIN_REQUIRED�SkipRadioButton�
setEnabled�
TitleLabel�setTextr2 �PLUGIN_OPTIONAL�DownloadRadioButton�toggled�boolr) �DownloadRadioButton_toggled�CopyRadioButton�CopyRadioButton_toggled�SkipRadioButton_toggled�PathLineEdit�textChanged�PathLineEdit_textChanged�BrowseToolButtonr( �BrowseToolButton_clicked�signal�SIGINT�SIG_DFL�setIconr. r/ �displayPage�PAGE_SOURCE)r �reason_text�msgr r r r f s(
zPluginDialog.showSourcePagec C �Z |r+| j �d� | j�d� | j�d� z| j �d� W n ty% Y nw d | _d S d S �NFTr �rR rG rU r+ �
setStyleSheet�AttributeErrorr �r �br r r rN � � �
�z(PluginDialog.DownloadRadioButton_toggledc C s<