[pywin32-checkins] pywin32/Pythonwin/pywin/framework intpyapp.py, 1.14, 1.15
OLD project page for the Python extensions for Windows
Brought to you by:
mhammond
From: Mark H. <mha...@us...> - 2009-01-03 05:45:42
|
Update of /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework In directory ddv4jf1.ch3.sourceforge.com:/tmp/cvs-serv11355/pywin/framework Modified Files: intpyapp.py Log Message: 'locate file' now just stops on error rather than asking for another name Index: intpyapp.py =================================================================== RCS file: /cvsroot/pywin32/pywin32/Pythonwin/pywin/framework/intpyapp.py,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** intpyapp.py 6 Dec 2008 00:39:16 -0000 1.14 --- intpyapp.py 3 Jan 2009 05:45:36 -0000 1.15 *************** *** 354,374 **** global lastLocateFileName # save the new version away for next time... ! # Loop until a good name, or cancel ! while 1: ! name = dialog.GetSimpleInput('File name', lastLocateFileName, 'Locate Python File') ! if name is None: # Cancelled. ! break ! lastLocateFileName = name ! # if ".py" supplied, rip it off! ! # should also check for .pys and .pyw ! if lastLocateFileName[-3:].lower()=='.py': ! lastLocateFileName = lastLocateFileName[:-3] ! lastLocateFileName = lastLocateFileName.replace(".","\\") ! newName = scriptutils.LocatePythonFile(lastLocateFileName) ! if newName is None: ! win32ui.MessageBox("The file '%s' can not be located" % lastLocateFileName) ! else: ! win32ui.GetApp().OpenDocumentFile(newName) ! break # Display all the "options" proprety pages we can find --- 354,371 ---- global lastLocateFileName # save the new version away for next time... ! name = dialog.GetSimpleInput('File name', lastLocateFileName, 'Locate Python File') ! if name is None: # Cancelled. ! return ! lastLocateFileName = name ! # if ".py" supplied, rip it off! ! # should also check for .pys and .pyw ! if lastLocateFileName[-3:].lower()=='.py': ! lastLocateFileName = lastLocateFileName[:-3] ! lastLocateFileName = lastLocateFileName.replace(".","\\") ! newName = scriptutils.LocatePythonFile(lastLocateFileName) ! if newName is None: ! win32ui.MessageBox("The file '%s' can not be located" % lastLocateFileName) ! else: ! win32ui.GetApp().OpenDocumentFile(newName) # Display all the "options" proprety pages we can find |