diff -r ffa851df0825 -r 2fb8b9db1c86 symbian-qemu-0.9.1-12/python-2.6.1/Mac/IDLE/idlemain.py --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/symbian-qemu-0.9.1-12/python-2.6.1/Mac/IDLE/idlemain.py Fri Jul 31 15:01:17 2009 +0100 @@ -0,0 +1,30 @@ +""" +Bootstrap script for IDLE as an application bundle. +""" +import sys, os + +from idlelib.PyShell import main + +# Change the current directory the user's home directory, that way we'll get +# a more useful default location in the open/save dialogs. +os.chdir(os.path.expanduser('~/Documents')) + + +# Make sure sys.executable points to the python interpreter inside the +# framework, instead of at the helper executable inside the application +# bundle (the latter works, but doesn't allow access to the window server) +if sys.executable.endswith('-32'): + sys.executable = os.path.join(sys.prefix, 'bin', 'python-32') +else: + sys.executable = os.path.join(sys.prefix, 'bin', 'python') + +# Look for the -psn argument that the launcher adds and remove it, it will +# only confuse the IDLE startup code. +for idx, value in enumerate(sys.argv): + if value.startswith('-psn_'): + del sys.argv[idx] + break + +#argvemulator.ArgvCollector().mainloop() +if __name__ == '__main__': + main()