[Python-checkins] CVS: python/dist/src/Mac/Modules/cm _Cmmodule.c,1.5,1.5.2.1
Jack Jansen
jackjansen@users.sourceforge.net
Wed, 19 Dec 2001 07:10:46 -0800
- Previous message: [Python-checkins] CVS: python/dist/src/Mac/Modules/cf _CFmodule.c,1.7,1.7.2.1 cfsupport.py,1.12,1.12.4.1
- Next message: [Python-checkins] CVS: python/dist/src/Mac/Modules/dlg _Dlgmodule.c,1.6,1.6.2.1 dlgscan.py,1.14,1.14.4.1 dlgsupport.py,1.27,1.27.2.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Update of /cvsroot/python/python/dist/src/Mac/Modules/cm
In directory usw-pr-cvs1:/tmp/cvs-serv12554/Modules/cm
Modified Files:
Tag: r22rc1-branch
_Cmmodule.c
Log Message:
Merged Mac subtree into the 22c1 branch.
Index: _Cmmodule.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Mac/Modules/cm/_Cmmodule.c,v
retrieving revision 1.5
retrieving revision 1.5.2.1
diff -C2 -d -r1.5 -r1.5.2.1
*** _Cmmodule.c 2001/12/08 18:02:52 1.5
--- _Cmmodule.c 2001/12/19 15:10:14 1.5.2.1
***************
*** 6,11 ****
--- 6,15 ----
+ #ifdef _WIN32
+ #include "pywintoolbox.h"
+ #else
#include "macglue.h"
#include "pymactoolbox.h"
+ #endif
/* Macro to test whether a weak-loaded CFM function exists */
***************
*** 403,406 ****
--- 407,444 ----
}
+ static PyObject *CmpObj_ResolveComponentAlias(ComponentObject *_self, PyObject *_args)
+ {
+ PyObject *_res = NULL;
+ Component _rv;
+ if (!PyArg_ParseTuple(_args, ""))
+ return NULL;
+ _rv = ResolveComponentAlias(_self->ob_itself);
+ _res = Py_BuildValue("O&",
+ CmpObj_New, _rv);
+ return _res;
+ }
+
+ static PyObject *CmpObj_GetComponentPublicIndString(ComponentObject *_self, PyObject *_args)
+ {
+ PyObject *_res = NULL;
+ OSErr _err;
+ Str255 theString;
+ short strListID;
+ short index;
+ if (!PyArg_ParseTuple(_args, "O&hh",
+ PyMac_GetStr255, theString,
+ &strListID,
+ &index))
+ return NULL;
+ _err = GetComponentPublicIndString(_self->ob_itself,
+ theString,
+ strListID,
+ index);
+ if (_err != noErr) return PyMac_Error(_err);
+ Py_INCREF(Py_None);
+ _res = Py_None;
+ return _res;
+ }
+
static PyObject *CmpObj_GetComponentRefcon(ComponentObject *_self, PyObject *_args)
{
***************
*** 484,499 ****
}
- static PyObject *CmpObj_ResolveComponentAlias(ComponentObject *_self, PyObject *_args)
- {
- PyObject *_res = NULL;
- Component _rv;
- if (!PyArg_ParseTuple(_args, ""))
- return NULL;
- _rv = ResolveComponentAlias(_self->ob_itself);
- _res = Py_BuildValue("O&",
- CmpObj_New, _rv);
- return _res;
- }
-
static PyObject *CmpObj_CountComponentInstances(ComponentObject *_self, PyObject *_args)
{
--- 522,525 ----
***************
*** 574,577 ****
--- 600,607 ----
{"OpenComponent", (PyCFunction)CmpObj_OpenComponent, 1,
"() -> (ComponentInstance _rv)"},
+ {"ResolveComponentAlias", (PyCFunction)CmpObj_ResolveComponentAlias, 1,
+ "() -> (Component _rv)"},
+ {"GetComponentPublicIndString", (PyCFunction)CmpObj_GetComponentPublicIndString, 1,
+ "(Str255 theString, short strListID, short index) -> None"},
{"GetComponentRefcon", (PyCFunction)CmpObj_GetComponentRefcon, 1,
"() -> (long _rv)"},
***************
*** 584,589 ****
{"GetComponentIndString", (PyCFunction)CmpObj_GetComponentIndString, 1,
"(Str255 theString, short strListID, short index) -> None"},
- {"ResolveComponentAlias", (PyCFunction)CmpObj_ResolveComponentAlias, 1,
- "() -> (Component _rv)"},
{"CountComponentInstances", (PyCFunction)CmpObj_CountComponentInstances, 1,
"() -> (long _rv)"},
--- 614,617 ----
- Previous message: [Python-checkins] CVS: python/dist/src/Mac/Modules/cf _CFmodule.c,1.7,1.7.2.1 cfsupport.py,1.12,1.12.4.1
- Next message: [Python-checkins] CVS: python/dist/src/Mac/Modules/dlg _Dlgmodule.c,1.6,1.6.2.1 dlgscan.py,1.14,1.14.4.1 dlgsupport.py,1.27,1.27.2.1
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]