author | Claus Gittinger <cg@exept.de> |
Thu, 02 Aug 2001 11:58:56 +0200 | |
changeset 1488 | 9fa3505d2d85 |
parent 1458 | 43c22152a2f5 |
child 1492 | 8a92a2d071ab |
permissions | -rw-r--r-- |
1124 | 1 |
" |
2 |
COPYRIGHT (c) 1997 by eXept Software AG |
|
3 |
All Rights Reserved |
|
4 |
||
5 |
This software is furnished under a license and may be used |
|
6 |
only in accordance with the terms of that license and with the |
|
7 |
inclusion of the above copyright notice. This software may not |
|
8 |
be provided or otherwise made available to, or used by, any |
|
9 |
other person. No title to or ownership of the software is |
|
10 |
hereby transferred. |
|
11 |
" |
|
12 |
||
13 |
||
14 |
||
15 |
||
16 |
||
1388 | 17 |
"{ Package: 'stx:libview2' }" |
18 |
||
1124 | 19 |
Object subclass:#KeyboardProcessor |
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
20 |
instanceVariableNames:'returnIsOKInDialog escapeIsCancelInDialog menuBar |
1251 | 21 |
autoAcceptListeners globalAccelerators' |
1124 | 22 |
classVariableNames:'' |
23 |
poolDictionaries:'' |
|
24 |
category:'Interface-Support-UI' |
|
25 |
! |
|
26 |
||
27 |
!KeyboardProcessor class methodsFor:'documentation'! |
|
28 |
||
29 |
copyright |
|
30 |
" |
|
31 |
COPYRIGHT (c) 1997 by eXept Software AG |
|
32 |
All Rights Reserved |
|
33 |
||
34 |
This software is furnished under a license and may be used |
|
35 |
only in accordance with the terms of that license and with the |
|
36 |
inclusion of the above copyright notice. This software may not |
|
37 |
be provided or otherwise made available to, or used by, any |
|
38 |
other person. No title to or ownership of the software is |
|
39 |
hereby transferred. |
|
40 |
" |
|
41 |
||
42 |
||
43 |
||
44 |
||
45 |
! |
|
46 |
||
47 |
documentation |
|
48 |
" |
|
49 |
ST80 compatibility (mimicry) class. |
|
50 |
||
51 |
The class is not completed yet and certainly not bug free. |
|
52 |
||
53 |
Notice: |
|
54 |
this class was implemented using protocol information |
|
55 |
from alpha testers, literature and by reading public domain code |
|
56 |
- it may not be complete or compatible to |
|
57 |
the corresponding ST-80 class. |
|
58 |
If you encounter any incompatibilities, please forward a note |
|
59 |
describing the incompatibility verbal (i.e. no code) to the ST/X team. |
|
60 |
||
1160 | 61 |
KeyboardProcessor is going to take over the focus control |
62 |
mechanism (which are currently located in the windowGroup). |
|
63 |
Currently, it keeps track of inputFields, and allows for |
|
64 |
a global accept to be forced. |
|
65 |
This is especially useful with dialogs, where a global accept |
|
66 |
should be performed on all inputFields, when the OK button |
|
67 |
is pressed. |
|
68 |
||
1124 | 69 |
[author:] |
1160 | 70 |
Claus Gittinger |
1124 | 71 |
" |
72 |
||
73 |
||
74 |
||
75 |
||
76 |
! ! |
|
77 |
||
1422 | 78 |
!KeyboardProcessor class methodsFor:'defaults'! |
79 |
||
1455
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
80 |
isKeyEventIgnoredAsShortcut:aKeyEvent |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
81 |
"returns true if the key event ignored is a shortCut key |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
82 |
" |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
83 |
|rawKey| |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
84 |
|
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
85 |
rawKey := aKeyEvent rawKey. |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
86 |
rawKey isSymbol ifFalse:[^ true]. |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
87 |
"/ ignore cursor keys |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
88 |
(#( |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
89 |
Up Down Left Right |
1457 | 90 |
CursorUp CursorDown CursorLeft CursorRight |
91 |
Shift |
|
1455
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
92 |
) includes:rawKey) ifTrue:[^ true]. |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
93 |
|
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
94 |
"/ ignore some meta keys |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
95 |
(#( |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
96 |
#'Control_L' #'Control_R' #'Control' #'Ctrl' #'CmdMenu' #'BackSpace' |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
97 |
) includes:aKeyEvent key) ifTrue:[^ true]. |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
98 |
|
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
99 |
^ false |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
100 |
|
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
101 |
"Created: / 17.1.2001 / 11:57:07 / cg" |
1457 | 102 |
"Modified: / 17.1.2001 / 13:05:46 / cg" |
1455
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
103 |
! |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
104 |
|
1422 | 105 |
isMnemonicKeyEvent:aKeyEvent |
106 |
"returns true if the key event is a mnemonic key |
|
107 |
" |
|
108 |
|rawKey| |
|
109 |
||
110 |
rawKey := aKeyEvent rawKey. |
|
1443 | 111 |
^ rawKey size == 4 and:[rawKey startsWith:'Cmd'] |
112 |
! ! |
|
1422 | 113 |
|
1388 | 114 |
!KeyboardProcessor methodsFor:'Compatibility - ST80'! |
1124 | 115 |
|
116 |
keyboardConsumers |
|
117 |
^ #() |
|
118 |
||
119 |
"Created: 6.3.1997 / 15:16:32 / cg" |
|
120 |
! |
|
121 |
||
122 |
removeKeyboardReceiver:aController |
|
123 |
||
124 |
"Created: / 31.10.1997 / 01:56:54 / cg" |
|
125 |
! |
|
126 |
||
127 |
sendKeyboardTo:aController |
|
128 |
||
129 |
"Created: / 31.10.1997 / 01:57:15 / cg" |
|
130 |
! |
|
131 |
||
132 |
setActive:aWidget |
|
133 |
||
134 |
"Created: 3.3.1997 / 18:31:09 / cg" |
|
135 |
! ! |
|
136 |
||
137 |
!KeyboardProcessor methodsFor:'accessing'! |
|
138 |
||
1251 | 139 |
addAccelerator:aKey action:aSelectorOrBlock |
140 |
"add a global accelerator - these are handled even if no corresponding |
|
141 |
menu shortcut is defined" |
|
142 |
||
143 |
globalAccelerators isNil ifTrue:[ |
|
144 |
globalAccelerators := Dictionary new |
|
145 |
]. |
|
146 |
globalAccelerators at:aKey put:aSelectorOrBlock |
|
147 |
! |
|
148 |
||
1124 | 149 |
escapeIsCancelInDialog:aBoolean |
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
150 |
"set the escapeIsCancel flag. |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
151 |
If off, Escape is NOT handled as cancel (however, the default is true)" |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
152 |
|
1124 | 153 |
escapeIsCancelInDialog := aBoolean |
154 |
! |
|
155 |
||
156 |
menuBar |
|
157 |
"return the value of the instance variable 'menuBar' (automatically generated)" |
|
158 |
||
1443 | 159 |
^ menuBar |
160 |
! |
|
1124 | 161 |
|
162 |
menuBar:something |
|
163 |
"set the value of the instance variable 'menuBar' (automatically generated)" |
|
164 |
||
1443 | 165 |
menuBar := something. |
166 |
! |
|
1124 | 167 |
|
168 |
returnIsOKInDialog:aBoolean |
|
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
169 |
"set the returnIsOK flag. |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
170 |
If off, Return is NOT handled as accept (however, the default is true)" |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
171 |
|
1124 | 172 |
returnIsOKInDialog := aBoolean |
173 |
||
174 |
! ! |
|
175 |
||
176 |
!KeyboardProcessor methodsFor:'event handling'! |
|
177 |
||
1135 | 178 |
processEvent:event forModalView:modalTopOrNil |
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
179 |
"process a key-event; return true, if handled & eaten; false if not. |
1251 | 180 |
Here, first, we look for a globalAccelerator, |
181 |
then for Return and Escape in modal applications, |
|
182 |
(which lead to Accept & Cancel resp.) |
|
183 |
Finally, menu-shortcuts are handled." |
|
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
184 |
|
1448
0c7834bd6c0f
early bailOut for cursorKeys (do not check for shortCuts)
Claus Gittinger <cg@exept.de>
parents:
1445
diff
changeset
|
185 |
|key rawKey topView wg app view action| |
1124 | 186 |
|
187 |
view := event view. |
|
188 |
||
189 |
event isKeyPressEvent ifTrue:[ |
|
190 |
key := event key. |
|
1448
0c7834bd6c0f
early bailOut for cursorKeys (do not check for shortCuts)
Claus Gittinger <cg@exept.de>
parents:
1445
diff
changeset
|
191 |
rawKey := event rawKey. |
1135 | 192 |
topView := modalTopOrNil ? view topView. |
1445
50bf6580e064
care for topViews without windowGroup (which should not happen - but...)
tm
parents:
1443
diff
changeset
|
193 |
wg := topView windowGroup. |
1124 | 194 |
app := topView application. |
195 |
||
1251 | 196 |
"/ how about global accelerators ? |
197 |
(globalAccelerators notNil |
|
198 |
and:[(action := globalAccelerators at:key ifAbsent:nil) notNil]) |
|
199 |
ifTrue:[ |
|
200 |
action isSymbol ifTrue:[ |
|
1422 | 201 |
app notNil ifTrue:[ |
202 |
action numArgs == 1 ifTrue:[ |
|
203 |
app perform:action with:event |
|
204 |
] ifFalse:[ |
|
205 |
app perform:action |
|
206 |
]. |
|
207 |
] |
|
1251 | 208 |
] ifFalse:[ |
209 |
action numArgs == 1 ifTrue:[ |
|
210 |
action value:event |
|
211 |
] ifFalse:[ |
|
212 |
action value |
|
213 |
] |
|
214 |
]. |
|
215 |
^ true |
|
216 |
]. |
|
1488
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
217 |
|
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
218 |
topView isModal ifTrue:[ |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
219 |
(wg notNil and:[wg explicitFocusView isNil]) ifTrue:[ |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
220 |
(returnIsOKInDialog and:[key == #Return]) ifTrue:[ |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
221 |
self requestGlobalAutoAccept ifFalse:[^ true]. |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
222 |
app notNil ifTrue:[ |
1422 | 223 |
app doAccept. |
1488
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
224 |
] ifFalse:[ |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
225 |
"/ oldStyle modalBox - for now, let Box handle it itself |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
226 |
^ false |
1422 | 227 |
]. |
1134
758151d73aac
only do autoAccept, if there is no focus view.
Claus Gittinger <cg@exept.de>
parents:
1133
diff
changeset
|
228 |
^ true |
758151d73aac
only do autoAccept, if there is no focus view.
Claus Gittinger <cg@exept.de>
parents:
1133
diff
changeset
|
229 |
]. |
1124 | 230 |
]. |
1488
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
231 |
|
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
232 |
(escapeIsCancelInDialog and:[key == #Escape]) ifTrue:[ |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
233 |
app notNil ifTrue:[ |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
234 |
app doCancel. |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
235 |
] ifFalse:[ |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
236 |
"/ oldStyle modalBox - for now, let Box handle it itself |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
237 |
^ false |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
238 |
]. |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
239 |
^ true |
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
240 |
]. |
1422 | 241 |
]. |
1488
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
242 |
|
1455
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
243 |
wg notNil ifTrue:[ |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
244 |
(self class isMnemonicKeyEvent:event) ifTrue:[ |
1456 | 245 |
"/Transcript showCR:event rawKey. |
246 |
"/Transcript showCR:event key. |
|
1455
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
247 |
(wg processMnemonic:event) ifTrue:[ |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
248 |
^ true |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
249 |
] |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
250 |
]. |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
251 |
(self class isKeyEventIgnoredAsShortcut:event) ifFalse:[ |
1456 | 252 |
"/Transcript showCR:event rawKey. |
253 |
"/Transcript showCR:event key. |
|
1455
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
254 |
(wg processShortcut:event) ifTrue:[ |
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
255 |
^ true |
1445
50bf6580e064
care for topViews without windowGroup (which should not happen - but...)
tm
parents:
1443
diff
changeset
|
256 |
]. |
1124 | 257 |
]. |
1422 | 258 |
]. |
1124 | 259 |
]. |
260 |
||
1423 | 261 |
"/ let view dispatch it. |
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
262 |
^ false |
1455
6d385add9b96
shortcut key processing (too slow)
Claus Gittinger <cg@exept.de>
parents:
1453
diff
changeset
|
263 |
|
1456 | 264 |
"Modified: / 17.1.2001 / 12:07:45 / cg" |
1423 | 265 |
! |
1124 | 266 |
|
267 |
requestForWindowClose |
|
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
268 |
"about to close the window." |
1124 | 269 |
|
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
270 |
^ true |
1124 | 271 |
! |
272 |
||
273 |
requestGlobalAutoAccept |
|
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
274 |
"about to close the window via return ok accept. |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
275 |
Ask all acceptListeners to accept their value and return true, if all of those fields |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
276 |
did." |
1124 | 277 |
|
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
278 |
autoAcceptListeners notNil ifTrue:[ |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
279 |
autoAcceptListeners do:[:aListener | |
1133 | 280 |
(aListener requestAutoAccept) ifFalse:[^ false]. |
281 |
]. |
|
282 |
^ true |
|
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
283 |
]. |
1458
43c22152a2f5
accept autoAccept (RETURN) if no input field widget is present
Claus Gittinger <cg@exept.de>
parents:
1457
diff
changeset
|
284 |
"/ if no input field (or comparable widget) is present ... |
43c22152a2f5
accept autoAccept (RETURN) if no input field widget is present
Claus Gittinger <cg@exept.de>
parents:
1457
diff
changeset
|
285 |
"/ ^ false <- wrong. |
43c22152a2f5
accept autoAccept (RETURN) if no input field widget is present
Claus Gittinger <cg@exept.de>
parents:
1457
diff
changeset
|
286 |
^ true. |
1124 | 287 |
! ! |
288 |
||
1128
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
289 |
!KeyboardProcessor methodsFor:'setup'! |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
290 |
|
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
291 |
addAutoAcceptListener:aListener |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
292 |
"add a aListener to my autoAcceptListeners. |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
293 |
Typically, inputFields add themself, to be notified (via requestForAutoAccept) |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
294 |
when the dialog is about to be closed with returnIsOK or accept. |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
295 |
(of course, other listeners are also invited ;-)" |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
296 |
|
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
297 |
autoAcceptListeners isNil ifTrue:[ |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
298 |
autoAcceptListeners := IdentitySet new. |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
299 |
]. |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
300 |
autoAcceptListeners add:aListener |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
301 |
! ! |
7810bca304e3
added autoAccept (editFields in dialogs)
Claus Gittinger <cg@exept.de>
parents:
1124
diff
changeset
|
302 |
|
1124 | 303 |
!KeyboardProcessor class methodsFor:'documentation'! |
304 |
||
305 |
version |
|
1488
9fa3505d2d85
optionBox: cancel-value corrected
Claus Gittinger <cg@exept.de>
parents:
1458
diff
changeset
|
306 |
^ '$Header: /cvs/stx/stx/libview2/KeyboardProcessor.st,v 1.22 2001-08-02 09:58:56 cg Exp $' |
1124 | 307 |
! ! |