summaryrefslogtreecommitdiffstats
path: root/Mac/Lib
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>2002-08-02 12:56:21 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>2002-08-02 12:56:21 (GMT)
commit6e1986ba9c8d014565c72217c3f946c67fcd34f6 (patch)
tree160c96aabfee420eab4cec55ec60088fab9ece12 /Mac/Lib
parentd5049e734fc9237f0d905fcf659ebbc2e160a514 (diff)
downloadcpython-6e1986ba9c8d014565c72217c3f946c67fcd34f6.zip
cpython-6e1986ba9c8d014565c72217c3f946c67fcd34f6.tar.gz
cpython-6e1986ba9c8d014565c72217c3f946c67fcd34f6.tar.bz2
- Remove -psn-xxxx argument added by the Finder.
- "Open Document" appleevent is "odoc", not "open".
Diffstat (limited to 'Mac/Lib')
-rw-r--r--Mac/Lib/argvemulator.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/Mac/Lib/argvemulator.py b/Mac/Lib/argvemulator.py
index 032a167..2df597a 100644
--- a/Mac/Lib/argvemulator.py
+++ b/Mac/Lib/argvemulator.py
@@ -17,8 +17,11 @@ class ArgvCollector:
def __init__(self):
self.quitting = 0
self.ae_handlers = {}
+ # Remove the funny -psn_xxx_xxx argument
+ if sys.argv[0][:4] == '-psn':
+ del sys.argv[0]
self.installaehandler('aevt', 'oapp', self.open_app)
- self.installaehandler('aevt', 'open', self.open_file)
+ self.installaehandler('aevt', 'odoc', self.open_file)
def installaehandler(self, classe, type, callback):
AE.AEInstallEventHandler(classe, type, self.callback_wrapper)