home *** CD-ROM | disk | FTP | other *** search
Text File | 1994-04-18 | 1.4 KB | 57 lines | [TEXT/PJMM] |
- unit Globals;
-
- interface
-
- {Defines}
-
- { The following constant is not defined in any .h file. It}
- { is described in "Inside Macintosh" - Event Manager, pp. 14-15.}
-
- const
- charcodemask = 255;
-
- lastmenu = 2; (* number of menus *)
- applemenu = 1; (* menu ID for desk accessory menu *)
- filemenu = 2; (* menu ID for File menu *)
- lastmenuPlus1 = lastmenu + 1;
-
- irattle = 1; (* items in the File menu *)
- ifrighten = 2;
- (*-------*)
- iquit = 4;
-
- aboutskelid = 1; (* Resource ID of the string *)
- rattleid = 2;
- frightenid = 5;
-
- windowid = 260; (* Resource ID for my window *)
-
- patID = 128; {Resource id for ppat}
-
-
- (* Globals *)
- {Note: some variables, like whichwindow and windowcode, should really not}
- {be globals, IMHO! /LIR}
-
- var
- screenport: GrafPtr; (* a port for the whole screen *)
- mywindow: WindowPtr; (* our one window *)
- wrecord: WindowRecord; (* storage for window record *)
- dragrect: Rect; (* Rect to drag within *)
- growrect: Rect; (* bounds for the growth of the windows *)
-
- mymenus: array[1..lastmenu] of MenuHandle;(* our menus *)
-
- myevent: EventRecord;
- whichwindow: WindowPtr; (* points to window of mouseDown *)
- windowcode: Integer; (* what mouse was in when event posted *)
- userdone: Boolean; (* true when user wants to exit program *)
-
- {New globals:}
- gWNEImplemented: Boolean;
- gSleep: integer;
- gColorQDFlag: Boolean;
- gAppleEventsInitialized: Boolean;
-
- implementation
- end.