[Python-checkins] CVS: python/dist/src/Mac/Tools/IDE PyEdit.py,1.26,1.26.6.1
Jack Jansen
jackjansen@users.sourceforge.net
Sun, 24 Feb 2002 15:17:25 -0800
Update of /cvsroot/python/python/dist/src/Mac/Tools/IDE
In directory usw-pr-cvs1:/tmp/cvs-serv25983
Modified Files:
Tag: release22-maint
PyEdit.py
Log Message:
Backport of 1.27 and 1.28:
- Added minimal support for floating windows.
- Changes by Donovan Preston (and a few minor ones by me) to make IDE run under
MachoPython. Mainly making sure we don't call routines that don't exist
and representing pathnames in a os.separator-neutral format.
These shouldn't interfere too much with Just's work on the next generation IDE,
I hope.
Index: PyEdit.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/Tools/IDE/PyEdit.py,v
retrieving revision 1.26
retrieving revision 1.26.6.1
diff -C2 -d -r1.26 -r1.26.6.1
*** PyEdit.py 18 Nov 2001 14:12:43 -0000 1.26
--- PyEdit.py 24 Feb 2002 23:17:23 -0000 1.26.6.1
***************
*** 18,21 ****
--- 18,27 ----
import re
+ if hasattr(Win, "FrontNonFloatingWindow"):
+ MyFrontWindow = Win.FrontNonFloatingWindow
+ else:
+ MyFrontWindow = Win.FrontWindow
+
+
try:
import Wthreading
***************
*** 1129,1133 ****
PyDebugger.startfromhere()
elif not haveThreading:
! MacOS.EnableAppswitch(0)
try:
if profiling:
--- 1135,1140 ----
PyDebugger.startfromhere()
elif not haveThreading:
! if hasattr(MacOS, 'EnableAppswitch'):
! MacOS.EnableAppswitch(0)
try:
if profiling:
***************
*** 1146,1150 ****
finally:
if not haveThreading:
! MacOS.EnableAppswitch(-1)
except W.AlertError, detail:
raise W.AlertError, detail
--- 1153,1158 ----
finally:
if not haveThreading:
! if hasattr(MacOS, 'EnableAppswitch'):
! MacOS.EnableAppswitch(-1)
except W.AlertError, detail:
raise W.AlertError, detail
***************
*** 1188,1192 ****
def findeditor(topwindow, fromtop = 0):
! wid = Win.FrontWindow()
if not fromtop:
if topwindow.w and wid == topwindow.w.wid:
--- 1196,1200 ----
def findeditor(topwindow, fromtop = 0):
! wid = MyFrontWindow()
if not fromtop:
if topwindow.w and wid == topwindow.w.wid: