Added duplicate call to fileConfig() to ensure that it cleans up after itself correctly.
[python.git] / Mac / Modules / menu / menuedit.py
blobb74301d3a61dd918b763cb71e2dd21b2a8415f77
1 f = Function(MenuHandle, 'as_Menu', (Handle, 'h', InMode))
2 functions.append(f)
4 f = Method(Handle, 'as_Resource', (MenuHandle, 'h', InMode))
5 methods.append(f)
7 # The following have "Mac" prepended to their names in the include file
8 # since UH 3.1, sigh...
9 f = Function(MenuHandle, 'GetMenu',
10 (short, 'resourceID', InMode),
12 functions.append(f)
14 f = Method(void, 'AppendMenu',
15 (MenuHandle, 'menu', InMode),
16 (ConstStr255Param, 'data', InMode),
18 methods.append(f)
20 f = Method(void, 'InsertMenu',
21 (MenuHandle, 'theMenu', InMode),
22 (short, 'beforeID', InMode),
24 methods.append(f)
26 f = Function(void, 'DeleteMenu',
27 (short, 'menuID', InMode),
29 functions.append(f)
31 f = Method(void, 'InsertMenuItem',
32 (MenuHandle, 'theMenu', InMode),
33 (ConstStr255Param, 'itemString', InMode),
34 (short, 'afterItem', InMode),
36 methods.append(f)
38 f = Method(void, 'EnableMenuItem',
39 (MenuHandle, 'theMenu', InMode),
40 (UInt16, 'item', InMode),
42 methods.append(f)
44 f = Method(void, 'CheckMenuItem',
45 (MenuRef, 'theMenu', InMode),
46 (short, 'item', InMode),
47 (Boolean, 'checked', InMode),
49 methods.append(f)
52 f = Function(void, 'DrawMenuBar',
54 functions.append(f)
58 # The following functions take an *optional* MenuRef as their first argument
61 f = Function(ItemCount, 'CountMenuItemsWithCommandID',
62 (OptMenuRef, 'inMenu', InMode),
63 (MenuCommand, 'inCommandID', InMode),
65 functions.append(f)
67 f = Function(OSStatus, 'GetIndMenuItemWithCommandID',
68 (OptMenuRef, 'inMenu', InMode),
69 (MenuCommand, 'inCommandID', InMode),
70 (UInt32, 'inItemIndex', InMode),
71 (MenuRef, 'outMenu', OutMode),
72 (MenuItemIndex, 'outIndex', OutMode),
74 functions.append(f)
76 f = Function(void, 'EnableMenuCommand',
77 (OptMenuRef, 'inMenu', InMode),
78 (MenuCommand, 'inCommandID', InMode),
80 functions.append(f)
82 f = Function(void, 'DisableMenuCommand',
83 (OptMenuRef, 'inMenu', InMode),
84 (MenuCommand, 'inCommandID', InMode),
86 functions.append(f)
88 f = Function(Boolean, 'IsMenuCommandEnabled',
89 (OptMenuRef, 'inMenu', InMode),
90 (MenuCommand, 'inCommandID', InMode),
92 functions.append(f)
94 f = Function(OSStatus, 'SetMenuCommandMark',
95 (OptMenuRef, 'inMenu', InMode),
96 (MenuCommand, 'inCommandID', InMode),
97 (UniChar, 'inMark', InMode),
99 functions.append(f)
101 f = Function(OSStatus, 'GetMenuCommandMark',
102 (OptMenuRef, 'inMenu', InMode),
103 (MenuCommand, 'inCommandID', InMode),
104 (UniChar, 'outMark', OutMode),
106 functions.append(f)
108 f = Function(OSStatus, 'GetMenuCommandPropertySize',
109 (OptMenuRef, 'inMenu', InMode),
110 (MenuCommand, 'inCommandID', InMode),
111 (OSType, 'inPropertyCreator', InMode),
112 (OSType, 'inPropertyTag', InMode),
113 (ByteCount, 'outSize', OutMode),
115 functions.append(f)
117 f = Function(OSStatus, 'RemoveMenuCommandProperty',
118 (OptMenuRef, 'inMenu', InMode),
119 (MenuCommand, 'inCommandID', InMode),
120 (OSType, 'inPropertyCreator', InMode),
121 (OSType, 'inPropertyTag', InMode),
123 functions.append(f)