From 0c1836f13bc3587f3a7bd74073cef63ef9a17b4c Mon Sep 17 00:00:00 2001 From: Jack Jansen Date: Fri, 25 Aug 2000 22:06:19 +0000 Subject: [PATCH] Call GetDialogWindow to convert dialogs to windows. --- Mac/Lib/EasyDialogs.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Mac/Lib/EasyDialogs.py b/Mac/Lib/EasyDialogs.py index 87f38a37674..f4cdbbf55d6 100644 --- a/Mac/Lib/EasyDialogs.py +++ b/Mac/Lib/EasyDialogs.py @@ -56,7 +56,7 @@ def Message(msg, id=260, ok=None): h.SetControlTitle(ok) d.SetDialogDefaultItem(1) d.AutoSizeDialog() - d.ShowWindow() + d.GetDialogWindow().ShowWindow() while 1: n = ModalDialog(None) if n == 1: @@ -95,7 +95,7 @@ def AskString(prompt, default = "", id=261, ok=None, cancel=None): d.SetDialogDefaultItem(1) d.SetDialogCancelItem(2) d.AutoSizeDialog() - d.ShowWindow() + d.GetDialogWindow().ShowWindow() while 1: n = ModalDialog(None) if n == 1: @@ -127,7 +127,7 @@ def AskPassword(prompt, default='', id=264, ok=None, cancel=None): ## SetControlData(pwd, kControlEditTextPart, kControlEditTextTextTag, bullets) SetControlData(pwd, kControlEditTextPart, kControlEditTextPasswordTag, default) d.SelectDialogItemText(4, 0, 999) - Ctl.SetKeyboardFocus(d, pwd, kControlEditTextPart) + Ctl.SetKeyboardFocus(d.GetDialogWindow(), pwd, kControlEditTextPart) if ok != None: h = d.GetDialogItemAsControl(1) h.SetControlTitle(ok) @@ -137,7 +137,7 @@ def AskPassword(prompt, default='', id=264, ok=None, cancel=None): d.SetDialogDefaultItem(Dialogs.ok) d.SetDialogCancelItem(Dialogs.cancel) d.AutoSizeDialog() - d.ShowWindow() + d.GetDialogWindow().ShowWindow() while 1: n = ModalDialog(None) if n == 1: @@ -196,7 +196,7 @@ def AskYesNoCancel(question, default = 0, yes=None, no=None, cancel=None, id=262 elif default == -1: d.SetDialogDefaultItem(4) d.AutoSizeDialog() - d.ShowWindow() + d.GetDialogWindow().ShowWindow() while 1: n = ModalDialog(None) if n == 1: return default @@ -221,7 +221,7 @@ class ProgressBar: self._update(0) self.d.AutoSizeDialog() self.title(title) - self.d.ShowWindow() + self.d.GetDialogWindow().ShowWindow() self.d.DrawDialog() def __del__( self ):