summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib
diff options
context:
space:
mode:
authorTim Peters <tim.peters@gmail.com>2006-06-11 19:43:49 (GMT)
committerTim Peters <tim.peters@gmail.com>2006-06-11 19:43:49 (GMT)
commit231c3c880457dfc09e29fad0254d3b5ebcb28625 (patch)
treeab866c4fc2a9a94f049a44f29858b0ee38408047 /Lib/idlelib
parent4f96f1f2b5068b8e8bd8d0f83f856b6e2883a3ab (diff)
downloadcpython-231c3c880457dfc09e29fad0254d3b5ebcb28625.zip
cpython-231c3c880457dfc09e29fad0254d3b5ebcb28625.tar.gz
cpython-231c3c880457dfc09e29fad0254d3b5ebcb28625.tar.bz2
Add missing svn:eol-style property to text files.
Diffstat (limited to 'Lib/idlelib')
-rw-r--r--Lib/idlelib/macosxSupport.py72
1 files changed, 36 insertions, 36 deletions
diff --git a/Lib/idlelib/macosxSupport.py b/Lib/idlelib/macosxSupport.py
index d55dbcb..10b9aa5 100644
--- a/Lib/idlelib/macosxSupport.py
+++ b/Lib/idlelib/macosxSupport.py
@@ -1,36 +1,36 @@
-"""
-A number of function that enhance IDLE on MacOSX when it used as a normal
-GUI application (as opposed to an X11 application).
-"""
-import sys
-
-def runningAsOSXApp():
- """ Returns True iff running from the IDLE.app bundle on OSX """
- return (sys.platform == 'darwin' and 'IDLE.app' in sys.argv[0])
-
-def addOpenEventSupport(root, flist):
- """
- This ensures that the application will respont to open AppleEvents, which
- makes is feaseable to use IDLE as the default application for python files.
- """
- def doOpenFile(*args):
- for fn in args:
- flist.open(fn)
-
- # The command below is a hook in aquatk that is called whenever the app
- # receives a file open event. The callback can have multiple arguments,
- # one for every file that should be opened.
- root.createcommand("::tk::mac::OpenDocument", doOpenFile)
-
-def hideTkConsole(root):
- root.tk.call('console', 'hide')
-
-
-def setupApp(root, flist):
- """
- Perform setup for the OSX application bundle.
- """
- if not runningAsOSXApp(): return
-
- hideTkConsole(root)
- addOpenEventSupport(root, flist)
+"""
+A number of function that enhance IDLE on MacOSX when it used as a normal
+GUI application (as opposed to an X11 application).
+"""
+import sys
+
+def runningAsOSXApp():
+ """ Returns True iff running from the IDLE.app bundle on OSX """
+ return (sys.platform == 'darwin' and 'IDLE.app' in sys.argv[0])
+
+def addOpenEventSupport(root, flist):
+ """
+ This ensures that the application will respont to open AppleEvents, which
+ makes is feaseable to use IDLE as the default application for python files.
+ """
+ def doOpenFile(*args):
+ for fn in args:
+ flist.open(fn)
+
+ # The command below is a hook in aquatk that is called whenever the app
+ # receives a file open event. The callback can have multiple arguments,
+ # one for every file that should be opened.
+ root.createcommand("::tk::mac::OpenDocument", doOpenFile)
+
+def hideTkConsole(root):
+ root.tk.call('console', 'hide')
+
+
+def setupApp(root, flist):
+ """
+ Perform setup for the OSX application bundle.
+ """
+ if not runningAsOSXApp(): return
+
+ hideTkConsole(root)
+ addOpenEventSupport(root, flist)