summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1995-11-15 15:17:23 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>1995-11-15 15:17:23 (GMT)
commit7830ab8f499d7e42d5acdeaf5ff048c7e49a889e (patch)
tree38e560d84937a0c348118b54a87d9a6feaafef3c
parente7bea57d0c0fd3a153cb6d7b230b5da3ad0c4cbd (diff)
downloadcpython-7830ab8f499d7e42d5acdeaf5ff048c7e49a889e.zip
cpython-7830ab8f499d7e42d5acdeaf5ff048c7e49a889e.tar.gz
cpython-7830ab8f499d7e42d5acdeaf5ff048c7e49a889e.tar.bz2
Added definitions for GrafPort object and Fixed type.
-rw-r--r--Tools/bgen/bgen/macsupport.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/Tools/bgen/bgen/macsupport.py b/Tools/bgen/bgen/macsupport.py
index 8d13afa..225c13f 100644
--- a/Tools/bgen/bgen/macsupport.py
+++ b/Tools/bgen/bgen/macsupport.py
@@ -52,6 +52,9 @@ ExistingDialogPtr = OpaqueByValueType("DialogPtr", "WinObj_WhichWindow", "BUG")
# NULL pointer passed in as optional storage -- not present in Python version
NullStorage = FakeType("(void *)0")
+# More standard datatypes
+Fixed = OpaqueByValueType("Fixed", "PyMac_BuildFixed", "PyMac_GetFixed")
+
# Quickdraw data types
Rect = Rect_ptr = OpaqueType("Rect", "PyMac_BuildRect", "PyMac_GetRect")
Point = OpaqueByValueType("Point", "PyMac_BuildPoint", "PyMac_GetPoint")
@@ -99,6 +102,8 @@ extern int ResObj_Convert(PyObject *, Handle *);
extern PyObject *WinObj_New(WindowPtr);
extern int WinObj_Convert(PyObject *, WindowPtr *);
+extern PyTypeObject Window_Type;
+#define WinObj_Check(x) ((x)->ob_type == &Window_Type)
extern PyObject *DlgObj_New(DialogPtr);
extern int DlgObj_Convert(PyObject *, DialogPtr *);
@@ -111,6 +116,9 @@ extern int MenuObj_Convert(PyObject *, MenuHandle *);
extern PyObject *CtlObj_New(ControlHandle);
extern int CtlObj_Convert(PyObject *, ControlHandle *);
+extern PyObject *GrafObj_New(GrafPtr);
+extern int GrafObj_Convert(PyObject *, GrafPtr *);
+
extern PyObject *WinObj_WhichWindow(WindowPtr);
"""