author | Claus Gittinger <cg@exept.de> |
Mon, 28 Jul 1997 12:43:53 +0200 | |
changeset 673 | 5e342b1ebe45 |
parent 664 | 3115cc4e4678 |
child 674 | a48904783fba |
permissions | -rw-r--r-- |
89 | 1 |
" |
2 |
COPYRIGHT (c) 1995 by Claus Gittinger |
|
434 | 3 |
All Rights Reserved |
89 | 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 |
||
100 | 13 |
Object subclass:#WindowBuilder |
480 | 14 |
instanceVariableNames:'window windowView application bindings visuals focusSequence |
600 | 15 |
namedComponents helpKeys componentCreationHook applicationClass |
502 | 16 |
keyboardProcessor subCanvasSpecs' |
436 | 17 |
classVariableNames:'' |
18 |
poolDictionaries:'' |
|
19 |
category:'Interface-Support-UI' |
|
66 | 20 |
! |
21 |
||
22 |
!WindowBuilder class methodsFor:'documentation'! |
|
23 |
||
89 | 24 |
copyright |
25 |
" |
|
26 |
COPYRIGHT (c) 1995 by Claus Gittinger |
|
434 | 27 |
All Rights Reserved |
89 | 28 |
|
29 |
This software is furnished under a license and may be used |
|
30 |
only in accordance with the terms of that license and with the |
|
31 |
inclusion of the above copyright notice. This software may not |
|
32 |
be provided or otherwise made available to, or used by, any |
|
33 |
other person. No title to or ownership of the software is |
|
34 |
hereby transferred. |
|
35 |
" |
|
36 |
! |
|
37 |
||
66 | 38 |
documentation |
39 |
" |
|
69 | 40 |
a no-op class, for systems which do not use the UIBuilder. |
66 | 41 |
Concrete subclasses know how to create a view (with components) from |
42 |
some interface spec. Currently, an experimantal version of UIBuilder exists, |
|
43 |
and more may be added in the future (for example, to parse different UI |
|
44 |
specs - thinking of motifs UIL specs etc). |
|
223 | 45 |
|
46 |
[author:] |
|
47 |
Claus Gittinger |
|
66 | 48 |
" |
49 |
! ! |
|
50 |
||
51 |
!WindowBuilder methodsFor:'accessing'! |
|
52 |
||
463 | 53 |
addBindings:moreBindings |
54 |
"used with subDialogs, which provide local bindings. |
|
55 |
All bindings from moreBindings overwrite any local bindings." |
|
56 |
||
57 |
moreBindings notNil ifTrue:[ |
|
58 |
moreBindings keysAndValuesDo:[:aKey :aValue | |
|
59 |
bindings at:aKey put:aValue |
|
60 |
] |
|
61 |
] |
|
62 |
||
63 |
"Created: 28.2.1997 / 14:14:33 / cg" |
|
64 |
! |
|
65 |
||
100 | 66 |
application |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
67 |
"return the application (an ApplicationModel), |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
68 |
for which the view is built. |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
69 |
This one is supposed to provide the aspects, menus etc." |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
70 |
|
100 | 71 |
^ application |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
72 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
73 |
"Modified: 17.1.1997 / 19:04:40 / cg" |
66 | 74 |
! |
75 |
||
125 | 76 |
application:anApplicationModel |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
77 |
"set the application (an ApplicationModel), |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
78 |
for which the view is built. |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
79 |
This one is supposed to provide the aspects, menus etc." |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
80 |
|
125 | 81 |
application := anApplicationModel |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
82 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
83 |
"Modified: 17.1.1997 / 19:04:47 / cg" |
66 | 84 |
! |
85 |
||
422 | 86 |
applicationClass:something |
87 |
"set the value of the instance variable 'applicationClass' (automatically generated)" |
|
88 |
||
89 |
applicationClass := something.! |
|
90 |
||
66 | 91 |
aspectAt:aSymbol |
433 | 92 |
|b| |
93 |
||
473 | 94 |
aSymbol notNil ifTrue:[ |
95 |
bindings notNil ifTrue:[ |
|
96 |
b := bindings at:aSymbol ifAbsent:nil. |
|
97 |
b notNil ifTrue:[^ b]. |
|
98 |
]. |
|
434 | 99 |
|
473 | 100 |
application notNil ifTrue:[ |
577 | 101 |
Object messageNotUnderstoodSignal handle:[:ex | |
102 |
Transcript showCR:'not understood: ' , aSymbol. |
|
103 |
] do:[ |
|
473 | 104 |
^ application aspectFor:aSymbol |
105 |
] |
|
450 | 106 |
] |
433 | 107 |
]. |
108 |
^ nil |
|
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
109 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
110 |
"Modified: 17.1.1997 / 19:28:32 / cg" |
66 | 111 |
! |
112 |
||
125 | 113 |
aspectAt:aSymbol put:aModel |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
114 |
bindings isNil ifTrue:[ |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
115 |
bindings := IdentityDictionary new |
125 | 116 |
]. |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
117 |
^ bindings at:aSymbol put:aModel |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
118 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
119 |
"Modified: 17.1.1997 / 19:28:37 / cg" |
100 | 120 |
! |
121 |
||
450 | 122 |
bindingAt:aSymbol |
123 |
bindings notNil ifTrue:[ |
|
124 |
^ bindings at:aSymbol ifAbsent:nil. |
|
125 |
]. |
|
126 |
^ nil |
|
127 |
! |
|
128 |
||
100 | 129 |
bindings |
130 |
^ bindings |
|
131 |
! |
|
132 |
||
133 |
bindings:aDictionary |
|
134 |
bindings := aDictionary |
|
135 |
! |
|
136 |
||
125 | 137 |
componentAt:name |
450 | 138 |
namedComponents isNil ifTrue:[^ nil]. |
139 |
^ namedComponents at:name asSymbol ifAbsent:nil |
|
125 | 140 |
! |
141 |
||
100 | 142 |
componentAt:name put:aComponent |
450 | 143 |
namedComponents isNil ifTrue:[ |
144 |
namedComponents := IdentityDictionary new. |
|
100 | 145 |
]. |
450 | 146 |
namedComponents at:name asSymbol put:aComponent |
100 | 147 |
! |
148 |
||
410 | 149 |
componentCreationHook:something |
150 |
"set the value of the instance variable 'componentCreationHook' (automatically generated)" |
|
151 |
||
152 |
componentCreationHook := something.! |
|
153 |
||
125 | 154 |
focusSequence |
155 |
^ focusSequence |
|
66 | 156 |
! |
157 |
||
600 | 158 |
helpKeyFor:aComponent |
159 |
|v key| |
|
160 |
||
161 |
helpKeys isNil ifTrue:[^ nil]. |
|
162 |
v := aComponent. |
|
163 |
[v notNil] whileTrue:[ |
|
164 |
(key := helpKeys at:v ifAbsent:nil) notNil ifTrue:[ |
|
165 |
^ key |
|
166 |
]. |
|
167 |
v := v superView |
|
168 |
]. |
|
595 | 169 |
^ nil |
600 | 170 |
! |
595 | 171 |
|
600 | 172 |
helpKeyFor:aComponent put:aKey |
595 | 173 |
|
600 | 174 |
aKey isNil ifTrue:[ |
175 |
helpKeys isNil ifFalse:[ |
|
176 |
helpKeys removeKey:aComponent ifAbsent:nil |
|
177 |
] |
|
178 |
] ifFalse:[ |
|
179 |
helpKeys isNil ifTrue:[ |
|
180 |
helpKeys := IdentityDictionary new |
|
181 |
]. |
|
182 |
helpKeys at:aComponent put:aKey |
|
183 |
] |
|
595 | 184 |
|
185 |
! |
|
186 |
||
477 | 187 |
keyboardProcessor |
188 |
keyboardProcessor isNil ifTrue:[ |
|
189 |
keyboardProcessor := KeyboardProcessor new |
|
190 |
]. |
|
191 |
^ keyboardProcessor |
|
192 |
||
193 |
"Created: 3.3.1997 / 18:31:37 / cg" |
|
194 |
"Modified: 3.3.1997 / 18:32:27 / cg" |
|
195 |
! |
|
196 |
||
86 | 197 |
namedComponents |
450 | 198 |
^ namedComponents |
86 | 199 |
! |
200 |
||
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
201 |
source |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
202 |
"same as #application, for ST-80 compatibility" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
203 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
204 |
^ application |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
205 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
206 |
"Created: 17.1.1997 / 19:03:51 / cg" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
207 |
! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
208 |
|
125 | 209 |
source:anApplicationModel |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
210 |
"same as #application:, for ST-80 compatibility" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
211 |
|
125 | 212 |
application := anApplicationModel |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
213 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
214 |
"Modified: 17.1.1997 / 19:03:57 / cg" |
125 | 215 |
! |
216 |
||
502 | 217 |
subCanvasAt:majorKey at:minorKey |
586 | 218 |
"get the subCanvas specification from major and minor key |
219 |
" |
|
220 |
|spec cls dict dkey| |
|
502 | 221 |
|
222 |
subCanvasSpecs notNil ifTrue:[ |
|
586 | 223 |
dkey := majorKey ? #NoMajorKey. |
224 |
dict := subCanvasSpecs at:dkey ifAbsent:nil. |
|
225 |
||
226 |
dict notNil ifTrue:[ |
|
227 |
spec := dict at:minorKey ifAbsent:nil. |
|
502 | 228 |
spec notNil ifTrue:[^ spec]. |
229 |
]. |
|
230 |
]. |
|
586 | 231 |
|
502 | 232 |
majorKey isNil ifTrue:[ |
586 | 233 |
spec := self safelyPerform:#specificationFor: with:minorKey. |
234 |
||
235 |
spec isNil ifTrue:[ |
|
236 |
spec := self safelyPerform:minorKey |
|
237 |
] |
|
502 | 238 |
] ifFalse:[ |
239 |
cls := Smalltalk at:majorKey ifAbsent:nil. |
|
586 | 240 |
(cls notNil and:[cls respondsTo:minorKey]) ifTrue:[ |
502 | 241 |
spec := cls perform:minorKey |
242 |
] |
|
243 |
]. |
|
586 | 244 |
^ spec |
245 |
||
502 | 246 |
! |
247 |
||
248 |
subCanvasAt:majorKey at:minorKey put:aSpec |
|
249 |
|dict key| |
|
250 |
||
251 |
key := majorKey ? #NoMajorKey. |
|
252 |
dict := subCanvasSpecs at:key ifAbsent:nil. |
|
253 |
dict isNil ifTrue:[ |
|
254 |
dict := IdentityDictionary new. |
|
255 |
subCanvasSpecs at:key put:dict |
|
256 |
]. |
|
257 |
dict at:minorKey put:aSpec |
|
258 |
||
259 |
! |
|
260 |
||
475
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
261 |
visualAt:name |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
262 |
visuals isNil ifTrue:[^ nil]. |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
263 |
^ visuals at:name asSymbol ifAbsent:nil |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
264 |
|
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
265 |
"Created: 3.3.1997 / 16:24:17 / cg" |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
266 |
! |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
267 |
|
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
268 |
visualAt:name put:aVisual |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
269 |
visuals isNil ifTrue:[ |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
270 |
visuals := IdentityDictionary new. |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
271 |
]. |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
272 |
visuals at:name asSymbol put:aVisual |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
273 |
|
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
274 |
"Created: 3.3.1997 / 16:24:41 / cg" |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
275 |
! |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
276 |
|
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
277 |
visuals |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
278 |
^ visuals |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
279 |
|
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
280 |
"Created: 3.3.1997 / 16:24:00 / cg" |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
281 |
! |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
282 |
|
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
283 |
visuals:aDictionary |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
284 |
visuals := aDictionary |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
285 |
|
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
286 |
"Created: 3.3.1997 / 16:24:06 / cg" |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
287 |
! |
fd94f2bc8b9e
added #visuals, #visualAt: and #visualAt:put:
Claus Gittinger <cg@exept.de>
parents:
473
diff
changeset
|
288 |
|
125 | 289 |
window |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
290 |
"return the top window (view), for which an interface |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
291 |
is (being) built" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
292 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
293 |
^ window |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
294 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
295 |
"Modified: 17.1.1997 / 19:30:00 / cg" |
125 | 296 |
! |
297 |
||
298 |
window:aView |
|
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
299 |
"set the top window (view), for which an interface |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
300 |
is (being) built" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
301 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
302 |
window := aView |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
303 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
304 |
"Modified: 17.1.1997 / 19:30:22 / cg" |
66 | 305 |
! |
306 |
||
307 |
windowGroup |
|
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
308 |
^ window windowGroup |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
309 |
|
608 | 310 |
"Modified: 17.6.1997 / 18:04:01 / cg" |
66 | 311 |
! ! |
312 |
||
673
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
313 |
!WindowBuilder methodsFor:'aspect access support'! |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
314 |
|
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
315 |
booleanAspectFor:aKey |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
316 |
"helper (common code) to generate a boolean aspect if required" |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
317 |
|
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
318 |
|holder| |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
319 |
|
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
320 |
(holder := self bindingAt:aKey) isNil ifTrue:[ |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
321 |
self aspectAt:aKey put:(holder := false asValue). |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
322 |
]. |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
323 |
^ holder |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
324 |
|
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
325 |
"Created: 28.7.1997 / 12:40:02 / cg" |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
326 |
! ! |
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
327 |
|
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
328 |
!WindowBuilder methodsFor:'building'! |
66 | 329 |
|
125 | 330 |
buildFromSpec:aSpec |
176 | 331 |
^ self subclassResponsibility |
408 | 332 |
! |
333 |
||
334 |
makeTabable:aComponent |
|
335 |
focusSequence isNil ifTrue:[ |
|
336 |
focusSequence := OrderedCollection new. |
|
337 |
]. |
|
338 |
focusSequence add:aComponent |
|
66 | 339 |
! ! |
100 | 340 |
|
586 | 341 |
!WindowBuilder methodsFor:'message sending'! |
342 |
||
343 |
safelyPerform:aSelector |
|
344 |
"send the message aSelector to the receiver self or application; |
|
345 |
the result returned from the send or nil is returned |
|
346 |
" |
|
347 |
|res| |
|
348 |
||
595 | 349 |
aSelector isSymbol ifTrue:[ |
350 |
Object messageNotUnderstoodSignal handle:[:ex | |
|
351 |
] do:[ |
|
352 |
(res := self perform:aSelector) notNil ifTrue:[^ res] |
|
353 |
]. |
|
354 |
||
355 |
application notNil ifTrue:[ |
|
356 |
Object messageNotUnderstoodSignal handle:[:ex | |
|
357 |
] do:[ |
|
358 |
(res := application perform:aSelector) notNil ifTrue:[^ res] |
|
359 |
] |
|
586 | 360 |
] |
361 |
]. |
|
595 | 362 |
^ nil |
586 | 363 |
! |
364 |
||
365 |
safelyPerform:aSelector with:anArgument |
|
366 |
"send the one-arg-message aSelector to the receiver self or application; |
|
367 |
the result returned from the send or nil is returned |
|
368 |
" |
|
369 |
|res| |
|
370 |
||
595 | 371 |
aSelector isSymbol ifTrue:[ |
372 |
Object messageNotUnderstoodSignal handle:[:ex | |
|
373 |
] do:[ |
|
374 |
(res := self perform:aSelector with:anArgument) notNil ifTrue:[^ res] |
|
375 |
]. |
|
376 |
||
377 |
application notNil ifTrue:[ |
|
378 |
Object messageNotUnderstoodSignal handle:[:ex | |
|
379 |
] do:[ |
|
380 |
(res := application perform:aSelector with:anArgument) notNil ifTrue:[^ res] |
|
381 |
] |
|
586 | 382 |
] |
383 |
]. |
|
595 | 384 |
^ nil |
586 | 385 |
! ! |
386 |
||
422 | 387 |
!WindowBuilder methodsFor:'spec creation aspect fetch'! |
100 | 388 |
|
374 | 389 |
actionFor:aKey |
450 | 390 |
"return an action for aKey. This is invoked during window building |
391 |
(by the builder) to ask for an ActionButtons actionBlock. |
|
392 |
Here, first the local bindings are searched, then the application and |
|
393 |
finally the applications class is asked for a corresponding action. |
|
394 |
The returned object is typically a block." |
|
395 |
||
434 | 396 |
|b| |
397 |
||
398 |
bindings notNil ifTrue:[ |
|
399 |
b := bindings at:aKey ifAbsent:nil. |
|
400 |
b notNil ifTrue:[^ b]. |
|
401 |
]. |
|
402 |
||
374 | 403 |
application notNil ifTrue:[ |
577 | 404 |
Object messageNotUnderstoodSignal handle:[:ex | |
405 |
Transcript showCR:'not understood: ' , aKey. |
|
406 |
] do:[ |
|
450 | 407 |
^ application actionFor:aKey |
408 |
] |
|
374 | 409 |
]. |
422 | 410 |
applicationClass notNil ifTrue:[ |
424 | 411 |
(applicationClass respondsTo:#actionFor:) ifTrue:[ |
412 |
^ applicationClass actionFor:aKey |
|
413 |
] |
|
422 | 414 |
]. |
415 |
^ [] |
|
374 | 416 |
|
417 |
"Created: 17.1.1997 / 21:08:22 / cg" |
|
418 |
! |
|
419 |
||
420 |
aspectFor:aKey |
|
450 | 421 |
"return a model for aKey. This is invoked during window building |
422 |
(by the builder) to ask for an Editfields, a Toggles etc. model. |
|
423 |
Here, first the local bindings are searched, then the application and |
|
424 |
finally the applications class is asked for a corresponding action. |
|
425 |
The returned object is typically a valueHolder." |
|
426 |
||
434 | 427 |
|b| |
428 |
||
429 |
bindings notNil ifTrue:[ |
|
430 |
b := bindings at:aKey ifAbsent:nil. |
|
431 |
b notNil ifTrue:[^ b]. |
|
432 |
]. |
|
433 |
||
374 | 434 |
application notNil ifTrue:[ |
577 | 435 |
Object messageNotUnderstoodSignal handle:[:ex | |
436 |
Transcript showCR:'not understood: ' , aKey. |
|
437 |
] do:[ |
|
450 | 438 |
^ application aspectFor:aKey |
439 |
] |
|
374 | 440 |
]. |
422 | 441 |
applicationClass notNil ifTrue:[ |
424 | 442 |
(applicationClass respondsTo:#aspectFor:) ifTrue:[ |
443 |
^ applicationClass aspectFor:aKey |
|
444 |
] |
|
422 | 445 |
]. |
374 | 446 |
^ self aspectAt:aKey |
447 |
||
448 |
"Created: 17.1.1997 / 21:06:16 / cg" |
|
449 |
! |
|
450 |
||
423 | 451 |
componentFor:aKey |
450 | 452 |
"return a component for aKey. This is invoked during window building |
453 |
(by the builder) to ask for an ArbitraryComponents view. |
|
454 |
Here, first the local bindings are searched, then the application and |
|
455 |
finally the applications class is asked for a corresponding action. |
|
456 |
The returned object is typically a view." |
|
457 |
||
611
10d6eccf083c
dont catch errors in componentFor (makes debugging easier)
Claus Gittinger <cg@exept.de>
parents:
608
diff
changeset
|
458 |
|cls component| |
423 | 459 |
|
460 |
application notNil ifTrue:[ |
|
611
10d6eccf083c
dont catch errors in componentFor (makes debugging easier)
Claus Gittinger <cg@exept.de>
parents:
608
diff
changeset
|
461 |
component := application componentFor:aKey. |
10d6eccf083c
dont catch errors in componentFor (makes debugging easier)
Claus Gittinger <cg@exept.de>
parents:
608
diff
changeset
|
462 |
component notNil ifTrue:[^ component]. |
423 | 463 |
]. |
464 |
applicationClass notNil ifTrue:[ |
|
424 | 465 |
(applicationClass respondsTo:#componentFor:) ifTrue:[ |
466 |
^ applicationClass componentFor:aKey |
|
467 |
] |
|
423 | 468 |
]. |
469 |
^ self aspectAt:aKey |
|
470 |
||
611
10d6eccf083c
dont catch errors in componentFor (makes debugging easier)
Claus Gittinger <cg@exept.de>
parents:
608
diff
changeset
|
471 |
"Modified: 20.6.1997 / 11:40:22 / cg" |
423 | 472 |
! |
473 |
||
422 | 474 |
labelFor:aKey |
450 | 475 |
"return a label for aKey. This is invoked during window building |
476 |
(by the builder) to ask for a ???'s label. |
|
477 |
Here, first the local bindings are searched, then the application and |
|
478 |
finally the applications class is asked for a corresponding action. |
|
479 |
The returned object is typically a string." |
|
480 |
||
422 | 481 |
|cls| |
482 |
||
483 |
application notNil ifTrue:[ |
|
577 | 484 |
Object messageNotUnderstoodSignal handle:[:ex | |
485 |
Transcript showCR:'not understood: ' , aKey. |
|
486 |
] do:[ |
|
450 | 487 |
^ application labelFor:aKey |
488 |
] |
|
422 | 489 |
]. |
490 |
applicationClass notNil ifTrue:[ |
|
424 | 491 |
(applicationClass respondsTo:#labelFor:) ifTrue:[ |
492 |
^ applicationClass labelFor:aKey |
|
493 |
] |
|
422 | 494 |
]. |
495 |
^ self aspectAt:aKey |
|
496 |
||
497 |
! |
|
498 |
||
499 |
listFor:aKey |
|
450 | 500 |
"return a list for aKey. This is invoked during window building |
501 |
(by the builder) to ask for a ???'s label. |
|
502 |
Here, first the local bindings are searched, then the application and |
|
503 |
finally the applications class is asked for a corresponding action. |
|
504 |
The returned object is typically a list." |
|
505 |
||
422 | 506 |
application notNil ifTrue:[ |
577 | 507 |
Object messageNotUnderstoodSignal handle:[:ex | |
508 |
Transcript showCR:'not understood: ' , aKey. |
|
509 |
] do:[ |
|
450 | 510 |
^ application listFor:aKey |
511 |
] |
|
422 | 512 |
]. |
513 |
applicationClass notNil ifTrue:[ |
|
424 | 514 |
(applicationClass respondsTo:#listFor:) ifTrue:[ |
515 |
^ applicationClass listFor:aKey |
|
516 |
] |
|
422 | 517 |
]. |
518 |
^ self aspectAt:aKey |
|
519 |
||
520 |
"Created: 17.1.1997 / 21:08:45 / cg" |
|
521 |
! ! |
|
522 |
||
523 |
!WindowBuilder methodsFor:'spec creation callbacks'! |
|
524 |
||
100 | 525 |
createdComponent:aView forSpec:spec |
410 | 526 |
componentCreationHook notNil ifTrue:[ |
527 |
componentCreationHook value:aView value:spec value:self |
|
528 |
] |
|
100 | 529 |
|
530 |
"Modified: 5.9.1995 / 21:42:54 / claus" |
|
531 |
! ! |
|
532 |
||
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
533 |
!WindowBuilder methodsFor:'startup'! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
534 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
535 |
closeRequest |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
536 |
window destroy |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
537 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
538 |
"Modified: 17.1.1997 / 19:30:32 / cg" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
539 |
! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
540 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
541 |
open |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
542 |
"open my topView, as previously created" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
543 |
|
477 | 544 |
|type| |
545 |
||
546 |
application isNil ifTrue:[ |
|
547 |
type := #normal |
|
548 |
] ifFalse:[ |
|
549 |
type := application defaultWindowType |
|
550 |
]. |
|
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
551 |
self |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
552 |
openWithExtent:nil |
477 | 553 |
andType:type |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
554 |
|
477 | 555 |
"Modified: 3.3.1997 / 19:43:57 / cg" |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
556 |
! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
557 |
|
428 | 558 |
openAt:aPoint |
559 |
"open my topView at some location" |
|
560 |
||
561 |
self |
|
467 | 562 |
openAt:aPoint |
563 |
withExtent:nil |
|
428 | 564 |
andType:(application defaultWindowType) |
565 |
||
566 |
"Created: 14.2.1997 / 20:21:57 / cg" |
|
467 | 567 |
"Modified: 28.2.1997 / 22:50:29 / cg" |
428 | 568 |
! |
569 |
||
436 | 570 |
openAt:origin withExtent:ext andType:type |
428 | 571 |
"open my window, as previously created, optionally defining the |
572 |
windows origin and/or extent. |
|
573 |
The type argument may be #dialog or #normal, and specifies if the view |
|
574 |
should be opened as a modal view, blocking interaction to the currently |
|
575 |
active view, or as a normal view." |
|
576 |
||
480 | 577 |
|mainSubView| |
578 |
||
428 | 579 |
origin notNil ifTrue:[ |
580 |
window origin:origin |
|
581 |
]. |
|
582 |
ext notNil ifTrue:[ |
|
480 | 583 |
window extent:ext. |
584 |
] ifFalse:[ |
|
585 |
type == #dialog ifTrue:[ |
|
586 |
window fixSize |
|
587 |
] |
|
588 |
]. |
|
589 |
||
590 |
(windowView notNil and:[windowView ~~ window]) ifTrue:[ |
|
591 |
windowView extent:(window extent). |
|
428 | 592 |
]. |
593 |
||
594 |
type == #dialog ifTrue:[ |
|
467 | 595 |
window fixPosition:(window device pointerPosition - window positionOffset). |
428 | 596 |
window openModal. |
597 |
^ self |
|
598 |
]. |
|
599 |
||
600 |
type == #normal ifTrue:[ |
|
480 | 601 |
window isNil ifTrue:[ |
602 |
self setupWindowFor:(StandardSystemView new). |
|
603 |
]. |
|
604 |
||
428 | 605 |
window open. |
606 |
^ self |
|
607 |
]. |
|
608 |
||
609 |
type == #popUp ifTrue:[ |
|
467 | 610 |
window fixPosition:(window device pointerPosition). |
611 |
window openAsPopUp. |
|
428 | 612 |
^ self |
613 |
]. |
|
614 |
||
615 |
" |
|
616 |
if ST-80 supports more types - these may be added later |
|
617 |
" |
|
618 |
self halt:'unimplemented' |
|
619 |
||
620 |
"Created: 14.2.1997 / 20:22:24 / cg" |
|
480 | 621 |
"Modified: 3.3.1997 / 22:27:52 / cg" |
428 | 622 |
! |
623 |
||
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
624 |
openDialog |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
625 |
"open my topView, as previously created as a modal view, |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
626 |
blocking interaction to the currently active view." |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
627 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
628 |
self |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
629 |
openWithExtent:nil |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
630 |
andType:#dialog |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
631 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
632 |
"Modified: 17.1.1997 / 19:59:29 / cg" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
633 |
! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
634 |
|
428 | 635 |
openDialogAt:aPoint withExtent:ext |
636 |
"open my topView, as previously created as a modal view, |
|
637 |
blocking interaction to the currently active view." |
|
638 |
||
639 |
self |
|
640 |
openAt:aPoint withExtent:ext |
|
641 |
andType:#dialog |
|
642 |
||
643 |
"Modified: 17.1.1997 / 19:59:36 / cg" |
|
644 |
"Created: 14.2.1997 / 20:24:19 / cg" |
|
645 |
! |
|
646 |
||
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
647 |
openDialogWithExtent:ext |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
648 |
"open my topView, as previously created as a modal view, |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
649 |
blocking interaction to the currently active view." |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
650 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
651 |
self |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
652 |
openWithExtent:ext |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
653 |
andType:#dialog |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
654 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
655 |
"Modified: 17.1.1997 / 19:59:36 / cg" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
656 |
! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
657 |
|
664 | 658 |
openModal |
659 |
"open my topView, as previously created" |
|
660 |
||
661 |
self |
|
662 |
openWithExtent:nil |
|
663 |
andType:#dialog |
|
664 |
||
665 |
"Modified: 3.3.1997 / 19:43:57 / cg" |
|
666 |
! |
|
667 |
||
428 | 668 |
openPopUpAt:aPoint |
669 |
"open my topView, as previously created as a popUp view, |
|
670 |
blocking interaction to the currently active view." |
|
671 |
||
672 |
self |
|
673 |
openAt:aPoint withExtent:nil |
|
674 |
andType:#popUp |
|
675 |
||
676 |
"Modified: 17.1.1997 / 19:59:29 / cg" |
|
677 |
"Created: 14.2.1997 / 20:24:38 / cg" |
|
678 |
! |
|
679 |
||
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
680 |
openPopUpIn:aRectangle |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
681 |
"open my topView, as previously created as a popUp view, |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
682 |
blocking interaction to the currently active view." |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
683 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
684 |
self |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
685 |
openWithExtent:nil |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
686 |
andType:#popUp |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
687 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
688 |
"Modified: 17.1.1997 / 19:59:29 / cg" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
689 |
"Created: 17.1.1997 / 20:01:24 / cg" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
690 |
! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
691 |
|
587 | 692 |
openWindowAt:aPoint |
693 |
"open my topView at some location" |
|
694 |
||
695 |
self openAt:aPoint |
|
696 |
! |
|
697 |
||
698 |
openWindowAt:origin withExtent:ext andType:type |
|
699 |
"open my window, as previously created, optionally defining the |
|
700 |
windows origin and/or extent. |
|
701 |
The type argument may be #dialog or #normal, and specifies if the view |
|
702 |
should be opened as a modal view, blocking interaction to the currently |
|
703 |
active view, or as a normal view." |
|
704 |
||
705 |
^ self openAt:origin withExtent:ext andType:type |
|
706 |
! |
|
707 |
||
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
708 |
openWithExtent:aPoint |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
709 |
"open my topView, as previously created, but override |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
710 |
the extent." |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
711 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
712 |
self |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
713 |
openWithExtent:aPoint |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
714 |
andType:(application defaultWindowType) |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
715 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
716 |
"Modified: 17.1.1997 / 19:58:48 / cg" |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
717 |
! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
718 |
|
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
719 |
openWithExtent:ext andType:type |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
720 |
"open my window, as previously created. The type argument |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
721 |
may be #dialog or #normal, and specifies if the view should |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
722 |
be opened as a modal view, blocking interaction to the currently |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
723 |
active view, or as a normal view." |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
724 |
|
428 | 725 |
^ self openAt:nil withExtent:ext andType:type |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
726 |
|
428 | 727 |
"Modified: 14.2.1997 / 20:22:47 / cg" |
372
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
728 |
! ! |
6d7718f3d298
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
223
diff
changeset
|
729 |
|
132 | 730 |
!WindowBuilder class methodsFor:'documentation'! |
731 |
||
732 |
version |
|
673
5e342b1ebe45
added #booleanAspectFor: as a code-saver
Claus Gittinger <cg@exept.de>
parents:
664
diff
changeset
|
733 |
^ '$Header: /cvs/stx/stx/libview2/WindowBuilder.st,v 1.44 1997-07-28 10:43:53 cg Exp $' |
132 | 734 |
! ! |