Initial revision
[ssr] / StraySrc / Libraries / Sapphire / sh / _tms / tmsMain
1 ;
2 ; tmsMain.sh
3 ;
4 ; The Straylight Tearoff Menu Segment
5 ;
6 ; © 1994-1998 Straylight
7 ;
8
9 ;----- Licensing note -------------------------------------------------------
10 ;
11 ; This file is part of Straylight's Sapphire library.
12 ;
13 ; Sapphire is free software; you can redistribute it and/or modify
14 ; it under the terms of the GNU General Public License as published by
15 ; the Free Software Foundation; either version 2, or (at your option)
16 ; any later version.
17 ;
18 ; Sapphire is distributed in the hope that it will be useful,
19 ; but WITHOUT ANY WARRANTY; without even the implied warranty of
20 ; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21 ; GNU General Public License for more details.
22 ;
23 ; You should have received a copy of the GNU General Public License
24 ; along with Sapphire. If not, write to the Free Software Foundation,
25 ; 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26
27 ;----- Overview -------------------------------------------------------------
28 ;
29 ; Functions provided:
30 ;
31 ; tms__closeMenu
32 ; tms__updateItem
33 ; tmsh__subWaiting
34 ; tmsh__openSub
35 ; tms__cleanUp
36 ; tms__wSpace
37 ; tms__update
38 ; tms__eventHandler
39 ; tms_help
40
41 ; --- tms__closeMenu ---
42 ;
43 ; On entry: R2 == pointer to menu to close
44 ; R10 == pointer to the menu we are currently over
45 ;
46 ; On exit: --
47 ;
48 ; Use: Closes the menu structure pointed to, and destroys it
49
50 IMPORT tms__closeMenu
51
52 ; --- tms__updateItem ---
53 ;
54 ; On entry: R7 == pointer to the item to highlight
55 ; R10 == pointer to the menu
56 ;
57 ; On exit: --
58 ;
59 ; Use: Forces an update of the textual part of an item.
60
61 IMPORT tms__updateItem
62
63 ; --- tmsh__subWaiting ---
64 ;
65 ; On entry: --
66 ;
67 ; On exit: CS if we're waiting for a submenu, CC otherwise
68 ;
69 ; Use: Informs transWin if a submenu is expected.
70
71 IMPORT tmsh__subWaiting
72
73 ; --- tmsh__openSub ---
74 ;
75 ; On entry: R0 == window handle to open
76 ;
77 ; On exit: --
78 ;
79 ; Use: Opens the given window as a submenu from a tms menu.
80
81 IMPORT tmsh__openSub
82
83 ; --- tms__cleanUp ---
84 ;
85 ; On entry: R0 == handle idle handler is called with (the menu)
86 ;
87 ; On exit: --
88 ;
89 ; Use: Called to clean up the system when the pointer has left
90 ; a menu.
91
92 IMPORT tms__cleanUp
93
94 ; --- tms__update ---
95 ;
96 ; On entry: R0 == flags (as for doRedraw)
97 ; R10 == pointer to the menu
98 ;
99 ; On exit: --
100 ;
101 ; Use: Updates the entire menu.
102
103 IMPORT tms__update
104
105 ; --- tms__eventHandler ---
106 ;
107 ; On entry: R0 == event, as returned from Wimp_Poll
108 ; R1 == pointer to the event block
109 ; R10 == pointer to the menu
110 ;
111 ; On exit: --
112 ;
113 ; Use: Deals with the event that has been sent to my window
114
115 IMPORT tms__eventHandler
116
117 ; --- tms_help ---
118 ;
119 ; On entry: R0 == pointer to base message tag
120 ; R1 == index of menu item
121 ;
122 ; On exit: --
123 ;
124 ; Use: Adds a string to the help message found by adding the menu
125 ; item number to the base message tag.
126
127 IMPORT tms_help
128
129 IMPORT tms__wSpace
130
131 ;----- That's all, folks ----------------------------------------------------
132
133 END