コード例 #1
0
ファイル: entry2-modal.py プロジェクト: lhjdark/python
def ask():
    popup = Toplevel()
    ents = makeform(popup, fields)
    Button(popup, text='OK', command=(lambda: show(ents, popup))).pack()
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()
コード例 #2
0
def ask():
    popup = Toplevel()  # отобразить форму в виде модального диалога
    ents = makeform(popup, fields)
    Button(popup, text='OK', command=(lambda: show(ents, popup))).pack()
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()  # ждать закрытия окна
コード例 #3
0
ファイル: entry2-modal.py プロジェクト: death-finger/Scripts
def ask():
    popup = Toplevel()
    ents = makeform(popup, fields)
    btn = Button(popup, text='OK', command=(lambda: show(ents, popup))).pack(side=BOTTOM)
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()
コード例 #4
0
ファイル: entry2-modal.py プロジェクト: liubiggun/PP4E
def ask():
    popup = Toplevel()              # show form in modal dialog window
    ents = makeform(popup, fields)
    Button(popup, text='OK', command=(lambda: show(ents, popup))).pack()
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()             # wait for destroy here
コード例 #5
0
def ask():
    popup = Toplevel()  # show form in modal dialog window
    ents = makeform(popup, fields)
    Button(popup, text='OK', command=(lambda: show(ents, popup))).pack()
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()  # wait for destroy here
コード例 #6
0
def ask():
    popup = Toplevel()  # 基于弹出窗口创建表单
    ents = makeform(popup, fields)
    Button(popup, text='Ok', command=lambda: show(ents, popup)).pack()
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()  # 模态窗口,会阻止其它界面直至该窗口关闭
コード例 #7
0
ファイル: entry2-modal.py プロジェクト: zhwren/Python
def ask():
    popup = Toplevel()
    ents = makeform(popup, fields)
    Button(popup, text="OK", command=(lambda: show(ents, popup))).pack()
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()
コード例 #8
0
def ask():
    '''
    Creates the dialog and shows it as modal
    '''
    popup = Toplevel()  # show form in modal dialog window
    ents = makeform(popup, FIELDS)
    Button(popup, text='OK', command=(lambda: show(ents, popup))).pack()
    popup.grab_set()
    popup.focus_set()
    popup.wait_window()  # wait for destroy here