Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/mfc
In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv2444/Pythonwin/pywin/mfc
Modified Files:
dialog.py
Log Message:
tweaks to locals named 'thread', 'window' or 'dialog' to be 2to3-friendly
Index: dialog.py
===================================================================
RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/mfc/dialog.py,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** dialog.py 27 Nov 2008 09:42:41 -0000 1.8
--- dialog.py 4 Dec 2008 07:00:21 -0000 1.9
***************
*** 221,228 ****
# uses a simple dialog to return a string object.
if title is None: title=win32ui.GetMainFrame().GetWindowText()
! class DlgSimpleInput(Dialog):
def __init__(self, prompt, defValue, title ):
self.title=title
! Dialog.__init__(self, win32ui.IDD_SIMPLE_INPUT)
self.AddDDX(win32ui.IDC_EDIT1,'result')
self.AddDDX(win32ui.IDC_PROMPT1, 'prompt')
--- 221,230 ----
# uses a simple dialog to return a string object.
if title is None: title=win32ui.GetMainFrame().GetWindowText()
! # 2to3 insists on converting 'Dialog.__init__' to 'tkinter.dialog...'
! DlgBaseClass = Dialog
! class DlgSimpleInput(DlgBaseClass):
def __init__(self, prompt, defValue, title ):
self.title=title
! DlgBaseClass.__init__(self, win32ui.IDD_SIMPLE_INPUT)
self.AddDDX(win32ui.IDC_EDIT1,'result')
self.AddDDX(win32ui.IDC_PROMPT1, 'prompt')
***************
*** 231,235 ****
def OnInitDialog(self):
self.SetWindowText(self.title)
! return Dialog.OnInitDialog(self)
dlg=DlgSimpleInput( prompt, defValue, title)
--- 233,237 ----
def OnInitDialog(self):
self.SetWindowText(self.title)
! return DlgBaseClass.OnInitDialog(self)
dlg=DlgSimpleInput( prompt, defValue, title)
|