summaryrefslogtreecommitdiffstats
path: root/Mac
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1995-08-17 14:35:56 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>1995-08-17 14:35:56 (GMT)
commitd4c26469d6d734efaa8bf2c5d997bd20b2d0de80 (patch)
treedf9a0b394a641f5455d493dd1e14b0aeb56b8503 /Mac
parentb95ea18a4c16e48e00f5c8fd0740ff8c3553373d (diff)
downloadcpython-d4c26469d6d734efaa8bf2c5d997bd20b2d0de80.zip
cpython-d4c26469d6d734efaa8bf2c5d997bd20b2d0de80.tar.gz
cpython-d4c26469d6d734efaa8bf2c5d997bd20b2d0de80.tar.bz2
Generated anew
Diffstat (limited to 'Mac')
-rw-r--r--Mac/Lib/toolbox/Controls.py2
-rw-r--r--Mac/Lib/toolbox/Dialogs.py2
-rw-r--r--Mac/Lib/toolbox/Events.py2
-rw-r--r--Mac/Lib/toolbox/Menus.py2
-rw-r--r--Mac/Lib/toolbox/QuickDraw.py4
-rw-r--r--Mac/Lib/toolbox/Resources.py2
-rw-r--r--Mac/Lib/toolbox/Sound.py2
-rw-r--r--Mac/Lib/toolbox/Windows.py2
-rw-r--r--Mac/Modules/ctl/Ctlmodule.c1
-rw-r--r--Mac/Modules/ctl/ctlgen.py2
-rw-r--r--Mac/Modules/dlg/Dlgmodule.c3
-rw-r--r--Mac/Modules/dlg/dlggen.py4
-rw-r--r--Mac/Modules/evt/Evtmodule.c1
-rw-r--r--Mac/Modules/evt/evtgen.py2
-rw-r--r--Mac/Modules/list/Listmodule.c1
-rw-r--r--Mac/Modules/menu/Menumodule.c1
-rw-r--r--Mac/Modules/menu/menugen.py2
-rw-r--r--Mac/Modules/qd/Qdmodule.c1
-rw-r--r--Mac/Modules/qd/qdgen.py4
-rw-r--r--Mac/Modules/res/Resmodule.c14
-rw-r--r--Mac/Modules/res/resgen.py2
-rw-r--r--Mac/Modules/snd/Sndmodule.c1
-rw-r--r--Mac/Modules/snd/sndgen.py2
-rw-r--r--Mac/Modules/win/Winmodule.c17
-rw-r--r--Mac/Modules/win/wingen.py2
25 files changed, 58 insertions, 20 deletions
diff --git a/Mac/Lib/toolbox/Controls.py b/Mac/Lib/toolbox/Controls.py
index 5ebe9c4..f874df8 100644
--- a/Mac/Lib/toolbox/Controls.py
+++ b/Mac/Lib/toolbox/Controls.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Controls.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Controls.h'
pushButProc = 0
checkBoxProc = 1
diff --git a/Mac/Lib/toolbox/Dialogs.py b/Mac/Lib/toolbox/Dialogs.py
index 572c609..c08dac4 100644
--- a/Mac/Lib/toolbox/Dialogs.py
+++ b/Mac/Lib/toolbox/Dialogs.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Dialogs.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Dialogs.h'
ctrlItem = 4
btnCtrl = 0
diff --git a/Mac/Lib/toolbox/Events.py b/Mac/Lib/toolbox/Events.py
index 0ff095a..4102262 100644
--- a/Mac/Lib/toolbox/Events.py
+++ b/Mac/Lib/toolbox/Events.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Events.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Events.h'
nullEvent = 0
mouseDown = 1
diff --git a/Mac/Lib/toolbox/Menus.py b/Mac/Lib/toolbox/Menus.py
index c063ab5..be1e810 100644
--- a/Mac/Lib/toolbox/Menus.py
+++ b/Mac/Lib/toolbox/Menus.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Menus.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Menus.h'
noMark = 0
mDrawMsg = 0
diff --git a/Mac/Lib/toolbox/QuickDraw.py b/Mac/Lib/toolbox/QuickDraw.py
index f9a6b8c..48c89fc 100644
--- a/Mac/Lib/toolbox/QuickDraw.py
+++ b/Mac/Lib/toolbox/QuickDraw.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDraw.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDraw.h'
invalColReq = -1
srcCopy = 0
@@ -82,7 +82,7 @@ allDevices = 1 << allDevicesBit
kNoConstraint = 0
kVerticalConstraint = 1
kHorizontalConstraint = 2
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDrawText.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDrawText.h'
leftCaret = 0
rightCaret = -1
diff --git a/Mac/Lib/toolbox/Resources.py b/Mac/Lib/toolbox/Resources.py
index 1c4d890..60a466f 100644
--- a/Mac/Lib/toolbox/Resources.py
+++ b/Mac/Lib/toolbox/Resources.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Resources.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Resources.h'
resSysHeap = 64
resPurgeable = 32
diff --git a/Mac/Lib/toolbox/Sound.py b/Mac/Lib/toolbox/Sound.py
index f7216c5..dedd91d 100644
--- a/Mac/Lib/toolbox/Sound.py
+++ b/Mac/Lib/toolbox/Sound.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Sound.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Sound.h'
soundListRsrc = 'snd '
rate44khz = 0xAC440000L
diff --git a/Mac/Lib/toolbox/Windows.py b/Mac/Lib/toolbox/Windows.py
index ca6f602..523cf21 100644
--- a/Mac/Lib/toolbox/Windows.py
+++ b/Mac/Lib/toolbox/Windows.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Windows.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Windows.h'
kStandardWindowDefinition = 0
kRoundWindowDefinition = 1
diff --git a/Mac/Modules/ctl/Ctlmodule.c b/Mac/Modules/ctl/Ctlmodule.c
index 7267cd7..c89d461 100644
--- a/Mac/Modules/ctl/Ctlmodule.c
+++ b/Mac/Modules/ctl/Ctlmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
diff --git a/Mac/Modules/ctl/ctlgen.py b/Mac/Modules/ctl/ctlgen.py
index 683e26b..9873ca4 100644
--- a/Mac/Modules/ctl/ctlgen.py
+++ b/Mac/Modules/ctl/ctlgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Controls.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Controls.h'
f = Function(ControlRef, 'NewControl',
(WindowRef, 'theWindow', InMode),
diff --git a/Mac/Modules/dlg/Dlgmodule.c b/Mac/Modules/dlg/Dlgmodule.c
index f1010a2..49f6553 100644
--- a/Mac/Modules/dlg/Dlgmodule.c
+++ b/Mac/Modules/dlg/Dlgmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
@@ -191,7 +192,7 @@ static PyObject *DlgObj_GetDialogItem(_self, _args)
&box);
_res = Py_BuildValue("hO&O&",
itemType,
- ResObj_New, item,
+ ResObj_OptNew, item,
PyMac_BuildRect, &box);
return _res;
}
diff --git a/Mac/Modules/dlg/dlggen.py b/Mac/Modules/dlg/dlggen.py
index 80650fd..4319520 100644
--- a/Mac/Modules/dlg/dlggen.py
+++ b/Mac/Modules/dlg/dlggen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Dialogs.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Dialogs.h'
f = Function(DialogRef, 'NewDialog',
(NullStorage, 'wStorage', InMode),
@@ -85,7 +85,7 @@ f = Method(void, 'GetDialogItem',
(DialogRef, 'theDialog', InMode),
(short, 'itemNo', InMode),
(short, 'itemType', OutMode),
- (Handle, 'item', OutMode),
+ (OptHandle, 'item', OutMode),
(Rect, 'box', OutMode),
)
methods.append(f)
diff --git a/Mac/Modules/evt/Evtmodule.c b/Mac/Modules/evt/Evtmodule.c
index 7732d09..139e5d8 100644
--- a/Mac/Modules/evt/Evtmodule.c
+++ b/Mac/Modules/evt/Evtmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
diff --git a/Mac/Modules/evt/evtgen.py b/Mac/Modules/evt/evtgen.py
index 1ca2962..47ac307 100644
--- a/Mac/Modules/evt/evtgen.py
+++ b/Mac/Modules/evt/evtgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Events.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Events.h'
f = Function(UInt32, 'GetCaretTime',
)
diff --git a/Mac/Modules/list/Listmodule.c b/Mac/Modules/list/Listmodule.c
index 928a9a5..747b477 100644
--- a/Mac/Modules/list/Listmodule.c
+++ b/Mac/Modules/list/Listmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
diff --git a/Mac/Modules/menu/Menumodule.c b/Mac/Modules/menu/Menumodule.c
index c016460..6c855cd 100644
--- a/Mac/Modules/menu/Menumodule.c
+++ b/Mac/Modules/menu/Menumodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
diff --git a/Mac/Modules/menu/menugen.py b/Mac/Modules/menu/menugen.py
index 2445d1e..30e43e2 100644
--- a/Mac/Modules/menu/menugen.py
+++ b/Mac/Modules/menu/menugen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Menus.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Menus.h'
f = Function(short, 'GetMBarHeight',
)
diff --git a/Mac/Modules/qd/Qdmodule.c b/Mac/Modules/qd/Qdmodule.c
index c1e5c8e..442a628 100644
--- a/Mac/Modules/qd/Qdmodule.c
+++ b/Mac/Modules/qd/Qdmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
diff --git a/Mac/Modules/qd/qdgen.py b/Mac/Modules/qd/qdgen.py
index cc12de4..d7976f1 100644
--- a/Mac/Modules/qd/qdgen.py
+++ b/Mac/Modules/qd/qdgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDraw.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDraw.h'
f = Function(void, 'OpenPort',
(GrafPtr, 'port', InMode),
@@ -713,7 +713,7 @@ f = Function(short, 'QDError',
)
functions.append(f)
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDrawText.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:QuickDrawText.h'
f = Function(void, 'TextFont',
(short, 'font', InMode),
diff --git a/Mac/Modules/res/Resmodule.c b/Mac/Modules/res/Resmodule.c
index d3ec0ea..4e8ed8f 100644
--- a/Mac/Modules/res/Resmodule.c
+++ b/Mac/Modules/res/Resmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
@@ -1331,6 +1332,19 @@ static PyMethodDef Res_methods[] = {
+/* Alternative version of ResObj_New, which returns None for null argument */
+PyObject *ResObj_OptNew(itself)
+ Handle itself;
+{
+ ResourceObject *it;
+ if (itself == NULL) {
+ Py_INCREF(Py_None);
+ return Py_None;
+ }
+ return ResObj_New(itself);
+}
+
+
void initRes()
{
diff --git a/Mac/Modules/res/resgen.py b/Mac/Modules/res/resgen.py
index 28b9015..6300d5c 100644
--- a/Mac/Modules/res/resgen.py
+++ b/Mac/Modules/res/resgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Resources.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Resources.h'
f = ResFunction(short, 'InitResources',
)
diff --git a/Mac/Modules/snd/Sndmodule.c b/Mac/Modules/snd/Sndmodule.c
index fbc8ff2..447f75d 100644
--- a/Mac/Modules/snd/Sndmodule.c
+++ b/Mac/Modules/snd/Sndmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
diff --git a/Mac/Modules/snd/sndgen.py b/Mac/Modules/snd/sndgen.py
index 827b263..c3a71c1 100644
--- a/Mac/Modules/snd/sndgen.py
+++ b/Mac/Modules/snd/sndgen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Sound.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Sound.h'
f = SndFunction(void, 'SetSoundVol',
(short, 'level', InMode),
diff --git a/Mac/Modules/win/Winmodule.c b/Mac/Modules/win/Winmodule.c
index 7d6de73..8691501 100644
--- a/Mac/Modules/win/Winmodule.c
+++ b/Mac/Modules/win/Winmodule.c
@@ -14,6 +14,7 @@
#include <Controls.h>
extern PyObject *ResObj_New(Handle);
+extern PyObject *ResObj_OptNew(Handle);
extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
@@ -804,6 +805,20 @@ static PyObject *Win_GetNewCWindow(_self, _args)
return _res;
}
+static PyObject *Win_WhichWindow(_self, _args)
+ PyObject *_self;
+ PyObject *_args;
+{
+ PyObject *_res = NULL;
+
+ long ptr;
+
+ if ( !PyArg_ParseTuple(_args, "i", &ptr) )
+ return NULL;
+ return WinObj_WhichWindow((WindowPtr)ptr);
+
+}
+
static PyMethodDef Win_methods[] = {
{"InitWindows", (PyCFunction)Win_InitWindows, 1,
"() -> None"},
@@ -827,6 +842,8 @@ static PyMethodDef Win_methods[] = {
"(Rect boundsRect, Str255 title, Boolean visible, short procID, WindowPtr behind, Boolean goAwayFlag, long refCon) -> (WindowPtr _rv)"},
{"GetNewCWindow", (PyCFunction)Win_GetNewCWindow, 1,
"(short windowID, WindowPtr behind) -> (WindowPtr _rv)"},
+ {"WhichWindow", (PyCFunction)Win_WhichWindow, 1,
+ "Resolve an integer WindowPtr address to a Window object"},
{NULL, NULL, 0}
};
diff --git a/Mac/Modules/win/wingen.py b/Mac/Modules/win/wingen.py
index 25931e8..4735952 100644
--- a/Mac/Modules/win/wingen.py
+++ b/Mac/Modules/win/wingen.py
@@ -1,4 +1,4 @@
-# Generated from 'Moes:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Windows.h'
+# Generated from 'Sap:CodeWarrior6:Metrowerks C/C++:Headers:Universal Headers 2.0.1f:Windows.h'
f = Function(void, 'InitWindows',
)