home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / S12780.ZIP / MENU.BI < prev    next >
Text File  |  1990-06-24  |  3KB  |  84 lines

  1. ' ===========================================================================
  2. '
  3. ' MENU.BI
  4. '
  5. '  Copyright (C) 1989 Microsoft Corporation, All Rights Reserved
  6. '
  7. ' ===========================================================================
  8.  
  9. ' ===========================================================================
  10. ' MenuTitleType stores information about each menu's title, and the left and
  11. ' right margins of the actual pull down menus.
  12. ' ===========================================================================
  13.  
  14. TYPE MenuTitleType
  15.     text        AS STRING * 15      'Menu title's text
  16.     state       AS INTEGER          'Menu's state  -1 empty, 0 disabled, 1 enabled
  17.     lowestRow   AS INTEGER          'lowest row of the menu
  18.     rColItem    AS INTEGER          'Right hand side of the menu
  19.     lColItem    AS INTEGER
  20.     rColTitle   AS INTEGER
  21.     lColTitle   AS INTEGER
  22.     itemLength  AS INTEGER
  23.     accessKey   AS INTEGER
  24. END TYPE
  25.  
  26. ' ===========================================================================
  27. ' MenuItemType stores information about menu items
  28. ' ===========================================================================
  29.  
  30. TYPE MenuItemType               '(GloItem)
  31.     text        AS STRING * 30
  32.     state       AS INTEGER
  33.     index       AS INTEGER
  34.     row         AS INTEGER
  35.     accessKey   AS INTEGER
  36. END TYPE
  37.  
  38. ' ===========================================================================
  39. ' MenuMiscType stores information about menu color attributes, current menu,
  40. ' previous menu, and an assortment of other miscellaneous information
  41. ' ===========================================================================
  42.  
  43. TYPE MenuMiscType               '(GloStorage)
  44.     lastMenu        AS INTEGER
  45.     lastItem        AS INTEGER
  46.     currMenu        AS INTEGER
  47.     currItem        AS INTEGER
  48.  
  49.     MenuOn          AS INTEGER
  50.     altKeyReset     AS INTEGER
  51.     menuIndex       AS STRING * 160
  52.     shortcutKeyIndex AS STRING * 100
  53.  
  54.     fore            AS INTEGER
  55.     back            AS INTEGER
  56.     highlight       AS INTEGER
  57.     disabled        AS INTEGER
  58.     cursorFore      AS INTEGER
  59.     cursorBack      AS INTEGER
  60.     cursorHi        AS INTEGER
  61. END TYPE
  62.  
  63. ' ===========================================================================
  64. ' DECLARATIONS
  65. ' ===========================================================================
  66.  
  67. DECLARE SUB MenuItemToggle (menu%, item%)
  68. DECLARE SUB MenuInit ()
  69. DECLARE SUB MenuColor (fore%, back%, highlight%, disabled%, cursorFore%, cursorBack%, cursorHi%)
  70. DECLARE SUB MenuSet (menu%, item%, state%, text$, accessKey%)
  71. DECLARE SUB MenuShow ()
  72. DECLARE SUB MenuPreProcess ()
  73. DECLARE SUB MenuEvent ()
  74. DECLARE FUNCTION MenuInkey$ ()
  75. DECLARE SUB MenuDo ()
  76. DECLARE FUNCTION MenuCheck% (action%)
  77. DECLARE SUB MenuOn ()
  78. DECLARE SUB MenuOff ()
  79. DECLARE SUB ShortCutKeySet (menu%, item%, shortcutKey$)
  80. DECLARE SUB ShortCutKeyDelete (menu%, item%)
  81. DECLARE SUB ShortCutKeyEvent (theKey$)
  82. DECLARE SUB MenuSetState (menu%, item%, state%)
  83.  
  84.