summaryrefslogtreecommitdiffstats
path: root/Mac/Modules/menu/menusupport.py
diff options
context:
space:
mode:
authorJack Jansen <jack.jansen@cwi.nl>2000-12-10 23:43:49 (GMT)
committerJack Jansen <jack.jansen@cwi.nl>2000-12-10 23:43:49 (GMT)
commitf7d5aa61d34cb7816ead2757860e5a66f7da0dcb (patch)
treefaba3f23c2f0fdfa74a156d441f6fa8945c337f8 /Mac/Modules/menu/menusupport.py
parentc6c283840316dec54244b311657511e95e742eb0 (diff)
downloadcpython-f7d5aa61d34cb7816ead2757860e5a66f7da0dcb.zip
cpython-f7d5aa61d34cb7816ead2757860e5a66f7da0dcb.tar.gz
cpython-f7d5aa61d34cb7816ead2757860e5a66f7da0dcb.tar.bz2
Adapted to Universal Headers 3.3.2. More to follow.
Diffstat (limited to 'Mac/Modules/menu/menusupport.py')
-rw-r--r--Mac/Modules/menu/menusupport.py19
1 files changed, 18 insertions, 1 deletions
diff --git a/Mac/Modules/menu/menusupport.py b/Mac/Modules/menu/menusupport.py
index 1325e10..20b4f36 100644
--- a/Mac/Modules/menu/menusupport.py
+++ b/Mac/Modules/menu/menusupport.py
@@ -25,13 +25,30 @@ from macsupport import *
MenuHandle = OpaqueByValueType(OBJECTTYPE, OBJECTPREFIX)
MenuRef = MenuHandle
Handle = OpaqueByValueType("Handle", "ResObj")
-
+MenuBarHandle = OpaqueByValueType("MenuBarHandle", "ResObj")
+MenuID = Type("MenuID", "h")
+MenuItemIndex = Type("MenuItemIndex", "h")
+MenuCommand = Type("MenuCommand", "l")
+MenuAttributes = Type("MenuAttributes", "l")
+MenuItemAttributes = Type("MenuItemAttributes", "l")
unsigned_char = Type('unsigned char', 'b')
+FMFontFamily = Type("FMFontFamily", "h")
+FMFontStyle = Type("FMFontStyle", "h")
includestuff = includestuff + """
#include <Devices.h> /* Defines OpenDeskAcc in universal headers */
#include <%s>""" % MACHEADERFILE + """
+#if !ACCESSOR_CALLS_ARE_FUNCTIONS
+#define GetMenuID(menu) ((*(menu))->menuID)
+#define GetMenuWidth(menu) ((*(menu))->menuWidth)
+#define GetMenuHeight(menu) ((*(menu))->menuHeight)
+
+#define SetMenuID(menu, id) ((*(menu))->menuID = (id))
+#define SetMenuWidth(menu, width) ((*(menu))->menuWidth = (width))
+#define SetMenuHeight(menu, height) ((*(menu))->menuHeight = (height))
+#endif
+
#define as_Menu(h) ((MenuHandle)h)
#define as_Resource(h) ((Handle)h)
"""