diff options
author | Jack Jansen <jack.jansen@cwi.nl> | 2001-03-02 16:32:03 (GMT) |
---|---|---|
committer | Jack Jansen <jack.jansen@cwi.nl> | 2001-03-02 16:32:03 (GMT) |
commit | 043732e95d3653960be4e23a84dc6661683001c0 (patch) | |
tree | 507e8bb345b784b5808e16e838a770f014e29f35 /Mac/Modules | |
parent | cfef0096f993c929c2e7f4814b43b273db97bd9c (diff) | |
download | cpython-043732e95d3653960be4e23a84dc6661683001c0.zip cpython-043732e95d3653960be4e23a84dc6661683001c0.tar.gz cpython-043732e95d3653960be4e23a84dc6661683001c0.tar.bz2 |
Enable FSpResourceFileAlreadyOpen only for Carbon. This is not strictly correct: OS9 InterfaceLib has it, but enabling it will make Python refuse to run on 8.6 and earlier.
Diffstat (limited to 'Mac/Modules')
-rw-r--r-- | Mac/Modules/res/Resmodule.c | 6 | ||||
-rw-r--r-- | Mac/Modules/res/resscan.py | 1 |
2 files changed, 7 insertions, 0 deletions
diff --git a/Mac/Modules/res/Resmodule.c b/Mac/Modules/res/Resmodule.c index 42c8800..bd6a42d 100644 --- a/Mac/Modules/res/Resmodule.c +++ b/Mac/Modules/res/Resmodule.c @@ -1353,6 +1353,8 @@ static PyObject *Res_DetachResourceFile(_self, _args) } #endif +#if TARGET_API_MAC_CARBON + static PyObject *Res_FSpResourceFileAlreadyOpen(_self, _args) PyObject *_self; PyObject *_args; @@ -1378,6 +1380,7 @@ static PyObject *Res_FSpResourceFileAlreadyOpen(_self, _args) refNum); return _res; } +#endif #if TARGET_API_MAC_CARBON @@ -1600,8 +1603,11 @@ static PyMethodDef Res_methods[] = { {"DetachResourceFile", (PyCFunction)Res_DetachResourceFile, 1, "(SInt16 refNum) -> (OSErr _rv)"}, #endif + +#if TARGET_API_MAC_CARBON {"FSpResourceFileAlreadyOpen", (PyCFunction)Res_FSpResourceFileAlreadyOpen, 1, "(FSSpec resourceFile) -> (Boolean _rv, Boolean inChain, SInt16 refNum)"}, +#endif #if TARGET_API_MAC_CARBON {"FSpOpenOrphanResFile", (PyCFunction)Res_FSpOpenOrphanResFile, 1, diff --git a/Mac/Modules/res/resscan.py b/Mac/Modules/res/resscan.py index 4b1babc..544e303 100644 --- a/Mac/Modules/res/resscan.py +++ b/Mac/Modules/res/resscan.py @@ -63,6 +63,7 @@ class ResourcesScanner(Scanner): 'FSpOpenOrphanResFile', 'DetachResourceFile', 'InsertResourceFile', + 'FSpResourceFileAlreadyOpen', ])] def makerepairinstructions(self): |