summaryrefslogtreecommitdiffstats
path: root/Mac/Modules/ctl/ctlsupport.py
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>1999-02-07 14:02:03 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>1999-02-07 14:02:03 (GMT)
commite058189040dcaf951c34d66f99eeb7e4ee91af6a (patch)
tree673cb8b9538f0573222f3577597709bd442a84e5 /Mac/Modules/ctl/ctlsupport.py
parentb0687899d7a84c09f00bcf492e76eee3a44143b3 (diff)
downloadcpython-e058189040dcaf951c34d66f99eeb7e4ee91af6a.zip
cpython-e058189040dcaf951c34d66f99eeb7e4ee91af6a.tar.gz
cpython-e058189040dcaf951c34d66f99eeb7e4ee91af6a.tar.bz2
Added Ctl.as_Control and Menu.as_Menu methods, which take a resource as
argument and return a Control or Menu object.
Diffstat (limited to 'Mac/Modules/ctl/ctlsupport.py')
-rw-r--r--Mac/Modules/ctl/ctlsupport.py2
1 files changed, 2 insertions, 0 deletions
diff --git a/Mac/Modules/ctl/ctlsupport.py b/Mac/Modules/ctl/ctlsupport.py
index 84dd6ce..3ba6778 100644
--- a/Mac/Modules/ctl/ctlsupport.py
+++ b/Mac/Modules/ctl/ctlsupport.py
@@ -44,6 +44,8 @@ ControlFontStyleRec_ptr = ControlFontStyleRec
includestuff = includestuff + """
#include <%s>""" % MACHEADERFILE + """
+#define as_Control(h) ((ControlHandle)h)
+
#define resNotFound -192 /* Can't include <Errors.h> because of Python's "errors.h" */
extern PyObject *CtlObj_WhichControl(ControlHandle); /* Forward */