| Server IP : 3.111.61.48 / Your IP : 216.73.216.109 Web Server : Apache System : Linux ip-10-0-5-176 6.8.0-1057-aws #60~22.04.1-Ubuntu SMP Wed May 27 08:16:59 UTC 2026 x86_64 User : ubuntu ( 1000) PHP Version : 8.2.31 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/lib/python3.10/tkinter/__pycache__/ |
Upload File : |
o
��bc�- � @ s� d Z ddlT ddlmZmZ ddlmZ G dd� d�ZG dd� de�Zdd
d�Zdd
� Z G dd� de�Z
G dd� de
�Zdd� ZG dd� de
�Z
dd� ZG dd� de
�Zdd� Zedkredd� Ze� d S d S ) a& This modules handles dialog boxes.
It contains the following public symbols:
SimpleDialog -- A simple but flexible modal dialog box
Dialog -- a base class for dialogs
askinteger -- get an integer from the user
askfloat -- get a float from the user
askstring -- get a string from the user
� )�*)�_get_temp_root�_destroy_temp_root)�
messageboxc @ sB e Zd Zdg ddddfdd�Zdd� Zdd� Zd d
� Zdd� ZdS )
�SimpleDialog� Nc C s$ |r
t ||d�| _nt |�| _|r| j�|� | j�|� t| j� t| j|dd�| _| jjdtd� t | j�| _
| j
�� || _|| _|| _
| j�d| j� tt|��D ]&}|| } t| j
| | |fdd�d �}
||krs|
jtd
d� |
jttdd� qU| j�d
| j� | j�|� t| j|� d S )N)�class_i� )�text�aspect� )�expand�fill�<Return>c S s
| � |�S �N)�done��self�num� r �+/usr/lib/python3.10/tkinter/simpledialog.py�<lambda>9 s
z'SimpleDialog.__init__.<locals>.<lambda>�r �command� )�relief�borderwidth)�sider
r �WM_DELETE_WINDOW)�Toplevel�root�title�iconname�
_setup_dialog�Message�message�pack�BOTH�Frame�framer �cancel�default�bind�return_event�range�len�Button�config�RIDGE�LEFT�protocol�wm_delete_window� transient�
_place_window)r �masterr �buttonsr* r) r r r �s�br r r �__init__! s4
�zSimpleDialog.__init__c C s. | j �� | j �� | j �� | j �� | jS r )r �wait_visibility�grab_set�mainloop�destroyr �r r r r �goA s
zSimpleDialog.goc C �( | j d u r| j�� d S | �| j � d S r )r* r �bellr �r �eventr r r r, H �
zSimpleDialog.return_eventc C rB r )r) r rC r r@ r r r r4 N rF zSimpleDialog.wm_delete_windowc C s || _ | j�� d S r )r r �quitr r r r r T � zSimpleDialog.done)�__name__�
__module__�__qualname__r; rA r, r4 r r r r r r s
� r c @ sV e Zd ZdZddd�Zdd� Zdd� Zd d
� Zddd�Zdd
d�Z dd� Z
dd� ZdS )�DialogzZClass to open dialogs.
This class is intended as a base class for custom dialogs
Nc C s� |}|du r t � }t�| |� | �� |dur |�� r | �|� |r'| �|� t| � || _d| _ t
| �}| �|�| _|j
ddd� | �� | jdu rN| | _| �d| j� t| |� | j�� | �� | �� | �| � dS )z�Initialize a dialog.
Arguments:
parent -- a parent window (the application window)
title -- the dialog title
N� )�padx�padyr )r r r; �withdraw�winfo_viewabler5 r r"