author | Claus Gittinger <cg@exept.de> |
Fri, 14 Feb 1997 20:35:37 +0100 | |
changeset 428 | 25f3b4964f14 |
parent 427 | e8dffb2f3e1e |
child 429 | 3311c88f2a0e |
permissions | -rw-r--r-- |
50 | 1 |
" |
2 |
COPYRIGHT (c) 1995 by Claus Gittinger |
|
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 |
Model subclass:#ApplicationModel |
|
310 | 14 |
instanceVariableNames:'builder resources device' |
389 | 15 |
classVariableNames:'DefaultLabels DefaultVisuals' |
142
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
16 |
poolDictionaries:'' |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
17 |
category:'Interface-Framework' |
50 | 18 |
! |
19 |
||
138 | 20 |
ApplicationModel class instanceVariableNames:'ClassResources' |
21 |
||
22 |
" |
|
23 |
The following class instance variables are inherited by this class: |
|
24 |
||
25 |
Model - |
|
26 |
Object - |
|
27 |
" |
|
28 |
! |
|
52 | 29 |
|
361 | 30 |
!ApplicationModel class methodsFor:'documentation'! |
50 | 31 |
|
32 |
copyright |
|
33 |
" |
|
34 |
COPYRIGHT (c) 1995 by Claus Gittinger |
|
35 |
All Rights Reserved |
|
36 |
||
37 |
This software is furnished under a license and may be used |
|
38 |
only in accordance with the terms of that license and with the |
|
39 |
inclusion of the above copyright notice. This software may not |
|
40 |
be provided or otherwise made available to, or used by, any |
|
41 |
other person. No title to or ownership of the software is |
|
42 |
hereby transferred. |
|
43 |
" |
|
44 |
! |
|
45 |
||
46 |
documentation |
|
47 |
" |
|
48 |
Since many ST-80 classes are subclasses of ApplicationModel, this class |
|
49 |
is provided here to allow easier porting of ST-80 code. |
|
57 | 50 |
|
63 | 51 |
It does not (currently) provide much functionality and is NOT |
52 |
compatible to the corresponding ST80 class; therefore, manual |
|
50 | 53 |
changes have to be made to get those applications to run under ST/X. |
57 | 54 |
(but at least, this enables you to fileIn that code and have a superclass |
78 | 55 |
for them) |
56 |
||
57 |
As time goes by, ST/X applications are going to be converted to |
|
330
d7ce98930ad3
Rename Launcher-->OldLauncher, NewLauncher-->Launcher.
Stefan Vogel <sv@exept.de>
parents:
313
diff
changeset
|
58 |
become subclasses of this abstract class - see Launcher for a |
78 | 59 |
first concrete example. |
60 |
||
215 | 61 |
|
78 | 62 |
ApplicationModel is prepared to build a view from a windowSpec, as |
215 | 63 |
created by the windowBuilder. If your subclass does not provide such |
78 | 64 |
a spec, you should at least redefine: |
65 |
||
215 | 66 |
#openInterface - to create a topview and open it |
78 | 67 |
|
68 |
you may want to redefine: |
|
69 |
||
215 | 70 |
#closeRequest - to catch window closing |
71 |
#focusSequence - to define a sequence for focus-stepping |
|
78 | 72 |
|
50 | 73 |
|
215 | 74 |
Once the interfaceBuilder is finished & released, subclasses can |
75 |
alternatively provide the spec via a #windowSpec method. |
|
76 |
||
52 | 77 |
The classResources have been put into this class to allow ST/X |
57 | 78 |
applications (which used to be subclasses of StandardSystemView) |
79 |
to migrate smoothly into ApplicationModels (which is better design ...). |
|
52 | 80 |
|
81 |
||
215 | 82 |
[Instance variables:] |
83 |
resources ResourcePack language string translation |
|
84 |
||
85 |
builder WindowBuilder a builder who knows how to create |
|
86 |
a window hierarchy from a specification |
|
78 | 87 |
|
88 |
||
89 |
Notice: this class was implemented using protocol information |
|
90 |
from alpha testers and PD code - it may not be complete or compatible to |
|
91 |
the corresponding ST-80 class. If you encounter any incompatibilities, |
|
92 |
please forward a note to the ST/X team. |
|
215 | 93 |
|
94 |
||
221 | 95 |
[author:] |
96 |
Claus Gittinger |
|
97 |
||
215 | 98 |
[see also:] |
99 |
StandardSystemView |
|
100 |
WindowGroup DeviceWorkstation |
|
50 | 101 |
" |
102 |
! ! |
|
103 |
||
361 | 104 |
!ApplicationModel class methodsFor:'initialization'! |
52 | 105 |
|
106 |
initialize |
|
107 |
self == ApplicationModel ifTrue:[ |
|
389 | 108 |
Smalltalk addDependent:self |
109 |
]. |
|
110 |
DefaultLabels isNil ifTrue:[ |
|
111 |
DefaultLabels := IdentityDictionary new |
|
112 |
]. |
|
113 |
DefaultVisuals isNil ifTrue:[ |
|
114 |
DefaultVisuals := IdentityDictionary new |
|
115 |
]. |
|
52 | 116 |
|
117 |
" |
|
118 |
ApplicationModel initialize |
|
119 |
" |
|
389 | 120 |
|
121 |
"Modified: 28.1.1997 / 12:31:38 / cg" |
|
52 | 122 |
! ! |
123 |
||
361 | 124 |
!ApplicationModel class methodsFor:'instance creation'! |
52 | 125 |
|
126 |
new |
|
215 | 127 |
"return a new initialized instance" |
128 |
||
63 | 129 |
^ super new basicInitialize initialize |
215 | 130 |
|
131 |
"Modified: 24.4.1996 / 09:42:14 / cg" |
|
311
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
132 |
! |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
133 |
|
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
134 |
onDevice:aDevice |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
135 |
"return a new initialized instance, which shall open its interface |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
136 |
on aDevice." |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
137 |
|
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
138 |
^ (super new basicInitialize |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
139 |
setDevice:aDevice) initialize |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
140 |
|
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
141 |
"Modified: 24.4.1996 / 09:42:14 / cg" |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
142 |
"Created: 5.7.1996 / 12:19:15 / cg" |
52 | 143 |
! ! |
144 |
||
421 | 145 |
!ApplicationModel class methodsFor:'accessing'! |
146 |
||
147 |
application |
|
148 |
^ self |
|
149 |
||
150 |
! ! |
|
151 |
||
152 |
!ApplicationModel class methodsFor:'bindings'! |
|
153 |
||
154 |
actionFor:aKey |
|
155 |
"sent by the builder to ask for an actionBlock for |
|
156 |
a Button. The argument, aKey comes from an UI-spec |
|
157 |
for a buttons #action property. |
|
158 |
Here, a corresponding message is sent to myself, |
|
159 |
which ought to be defined in the application subclass. |
|
160 |
Alternatively, a subclass may redefine this method, to provide |
|
161 |
actionBlocks from a Dictionary or whatever. |
|
162 |
Typically, a block is returned there." |
|
163 |
||
164 |
^ nil |
|
165 |
||
166 |
||
167 |
! |
|
168 |
||
169 |
aspectFor:aKey |
|
170 |
"sent by the builder to ask for an aspect (a data model). |
|
171 |
The argument, aKey comes from an UI-spec |
|
172 |
for a components #aspect property. |
|
173 |
Here, a corresponding message is sent to myself, |
|
174 |
which ought to be defined in the application subclass. |
|
175 |
Alternatively, a subclass may redefine this method, to provide |
|
176 |
holders from a Dictionary or whatever. |
|
177 |
Typically, a valueHolder is returned there." |
|
178 |
||
179 |
^ nil |
|
180 |
||
181 |
! |
|
182 |
||
183 |
clientFor:aKey |
|
184 |
"sent by the builder to ask for an application provided |
|
185 |
subcanvas's application. |
|
186 |
The argument, aKey comes from an UI-spec |
|
187 |
for a subcanvas's #client property. |
|
188 |
Here, a corresponding message is sent to myself, |
|
189 |
which ought to be defined in the application subclass. |
|
190 |
Alternatively, a subclass may redefine this method, to provide |
|
191 |
appModels from a Dictionary or whatever. |
|
192 |
Typically, an applicationModel is returned there." |
|
193 |
||
194 |
^ nil |
|
195 |
||
196 |
! |
|
197 |
||
198 |
componentFor:aKey |
|
199 |
"sent by the builder to ask for an application provided |
|
200 |
component. |
|
201 |
The argument, aKey comes from an UI-spec |
|
202 |
for a viewHolders #view property. |
|
203 |
Here, a corresponding message is sent to myself, |
|
204 |
which ought to be defined in the application subclass. |
|
205 |
Alternatively, a subclass may redefine this method, to provide |
|
206 |
holders from a Dictionary or whatever. |
|
207 |
Typically, a view is returned there." |
|
208 |
||
427 | 209 |
(self respondsTo:aKey) ifTrue:[ |
210 |
^ self perform:aKey |
|
211 |
]. |
|
212 |
^ nil |
|
421 | 213 |
! |
214 |
||
215 |
labelFor:aKey |
|
216 |
"sent by the builder to ask for an application provided |
|
217 |
label for a component. |
|
218 |
The argument, aKey comes from an UI-spec |
|
219 |
for a components #label property. |
|
220 |
Here, a corresponding message is sent to myself, |
|
221 |
which ought to be defined in the application subclass. |
|
222 |
Alternatively, a subclass may redefine this method, to provide |
|
223 |
labels from a Dictionary or whatever. |
|
224 |
Typically, a string is returned there." |
|
225 |
||
226 |
(self application respondsTo:aKey) ifTrue:[ |
|
227 |
^ self application perform:aKey |
|
228 |
]. |
|
229 |
^ self application labelAt:aKey ifAbsent:nil |
|
230 |
||
231 |
! |
|
232 |
||
233 |
listFor:aKey |
|
234 |
"sent by the builder to ask for an application provided |
|
235 |
holder for a list. |
|
236 |
The argument, aKey comes from an UI-spec |
|
237 |
for a listWidgets #list property. |
|
238 |
Here, a corresponding message is sent to myself, |
|
239 |
which ought to be defined in the application subclass. |
|
240 |
Alternatively, a subclass may redefine this method, to provide |
|
241 |
holders from a Dictionary or whatever. |
|
242 |
Typically, a list-holding model (SelectionInList) is returned there." |
|
243 |
||
244 |
^ self application perform:aKey |
|
245 |
||
246 |
! |
|
247 |
||
248 |
menuFor:aKey |
|
249 |
"sent by the builder to ask for an application provided |
|
250 |
holder for a menu. |
|
251 |
The argument, aKey comes from an UI-spec |
|
252 |
for a widgets #menu property. |
|
253 |
Here, a corresponding message is sent to myself, |
|
254 |
which ought to be defined in the application subclass. |
|
255 |
Alternatively, a subclass may redefine this method, to provide |
|
256 |
holders from a Dictionary or whatever. |
|
257 |
Typically, a menu or a menu-holding valueHolder is returned there." |
|
258 |
||
259 |
^ self application perform:aKey |
|
260 |
||
261 |
! |
|
262 |
||
263 |
specificationFor:aKey |
|
264 |
"sent by the builder to ask for an application provided |
|
265 |
component. |
|
266 |
The argument, aKey comes from an UI-spec |
|
267 |
for a viewHolders #specification property. |
|
268 |
Here, a corresponding message is sent to myself, |
|
269 |
which ought to be defined in the application subclass. |
|
270 |
Alternatively, a subclass may redefine this method, to provide |
|
271 |
holders from a Dictionary or whatever. |
|
272 |
Typically, a view is returned there." |
|
273 |
||
274 |
^ self application perform:aKey |
|
275 |
||
276 |
! |
|
277 |
||
278 |
visualFor:aKey |
|
279 |
"sent by the builder to ask for an application provided |
|
280 |
image or element for a label. |
|
281 |
The argument, aKey comes from an UI-spec |
|
282 |
for a widgets #label property, if LabelIsImage is turned on. |
|
283 |
Here, a corresponding message is sent to myself, |
|
284 |
which ought to be defined in the application subclass. |
|
285 |
Alternatively, a subclass may redefine this method, to provide |
|
286 |
images from a Dictionary or whatever. |
|
287 |
Typically, an image is returned there." |
|
288 |
||
289 |
(self application respondsTo:aKey) ifTrue:[ |
|
290 |
^ self application perform:aKey |
|
291 |
]. |
|
292 |
^ self application visualAt:aKey ifAbsent:nil |
|
293 |
||
294 |
||
295 |
! ! |
|
296 |
||
361 | 297 |
!ApplicationModel class methodsFor:'change & update'! |
52 | 298 |
|
302 | 299 |
update:something with:aParameter from:changedObject |
69 | 300 |
"flush resources on language changes" |
301 |
||
52 | 302 |
something == #Language ifTrue:[ |
302 | 303 |
"flush resources on language changes" |
304 |
self flushAllClassResources |
|
52 | 305 |
] |
302 | 306 |
|
307 |
"Created: 15.6.1996 / 15:13:29 / cg" |
|
52 | 308 |
! ! |
309 |
||
421 | 310 |
!ApplicationModel class methodsFor:'defaults'! |
311 |
||
312 |
labelAt:aKey |
|
313 |
^ nil |
|
314 |
! |
|
315 |
||
316 |
labelAt:aKey ifAbsent:aBlock |
|
317 |
^ aBlock value |
|
318 |
! |
|
319 |
||
320 |
labelAt:aKey put:aValue |
|
321 |
"/ not yet implemented |
|
322 |
! |
|
323 |
||
324 |
labels |
|
325 |
"/ not yet implemented |
|
326 |
^ nil |
|
327 |
! |
|
328 |
||
329 |
visualAt:aKey |
|
330 |
^ nil |
|
331 |
! |
|
332 |
||
333 |
visualAt:aKey ifAbsent:aBlock |
|
334 |
^ aBlock value |
|
335 |
! |
|
336 |
||
337 |
visualAt:aKey put:aValue |
|
338 |
"/ not yet implemented |
|
339 |
! |
|
340 |
||
341 |
visuals |
|
342 |
"/ not yet implemented |
|
343 |
^ nil |
|
344 |
! ! |
|
345 |
||
361 | 346 |
!ApplicationModel class methodsFor:'queries'! |
63 | 347 |
|
348 |
interfaceSpecFor:aSelector |
|
69 | 349 |
"return an interface spec" |
350 |
||
421 | 351 |
^ UISpecification from:(self application specificationFor:aSelector) |
63 | 352 |
! ! |
353 |
||
361 | 354 |
!ApplicationModel class methodsFor:'resources'! |
52 | 355 |
|
356 |
classResources |
|
357 |
"if not already loaded, get the classes resourcePack |
|
358 |
and return it" |
|
359 |
||
360 |
ClassResources isNil ifTrue:[ |
|
361 |
ClassResources := ResourcePack for:self. |
|
362 |
]. |
|
363 |
^ ClassResources |
|
364 |
! |
|
365 |
||
366 |
classResources:aResourcePack |
|
367 |
"allow setting of the classResources" |
|
368 |
||
369 |
ClassResources := aResourcePack |
|
370 |
! |
|
371 |
||
372 |
flushAllClassResources |
|
373 |
"flush all classes resource translations. |
|
374 |
Needed after a resource file / language setting has changed." |
|
375 |
||
376 |
ResourcePack flushCachedResourcePacks. |
|
377 |
self flushClassResources. |
|
378 |
self allSubclassesDo:[:aClass | |
|
379 |
aClass flushClassResources. |
|
380 |
] |
|
381 |
! |
|
382 |
||
383 |
flushClassResources |
|
384 |
"flush classes resource string translations. |
|
385 |
Needed whenever a resource file / language setting has changed" |
|
386 |
||
387 |
ClassResources := nil. |
|
63 | 388 |
! |
389 |
||
390 |
updateClassResources |
|
391 |
"update my classResources" |
|
392 |
||
393 |
ClassResources := nil. |
|
394 |
self classResources |
|
52 | 395 |
! ! |
396 |
||
361 | 397 |
!ApplicationModel class methodsFor:'startup'! |
138 | 398 |
|
399 |
open |
|
400 |
"create an instance of the application and open its view" |
|
401 |
||
240 | 402 |
^ self new open |
138 | 403 |
|
404 |
" |
|
361 | 405 |
Launcher open |
138 | 406 |
" |
240 | 407 |
|
361 | 408 |
"Modified: 13.1.1997 / 20:54:50 / cg" |
138 | 409 |
! |
410 |
||
428 | 411 |
openAt:aLocation |
412 |
"create an instance of the application and open its view |
|
413 |
at some position." |
|
414 |
||
415 |
^ self new openAt:aLocation |
|
416 |
||
417 |
"Modified: 14.2.1997 / 20:28:41 / cg" |
|
418 |
! |
|
419 |
||
420 |
openDialogInterface:anInterfaceSymbol |
|
421 |
"create an instance of the application and open a view as |
|
422 |
specified by anInterfaceSymbol." |
|
423 |
||
424 |
^ self new openDialogInterface:anInterfaceSymbol |
|
425 |
||
426 |
"Modified: 5.9.1995 / 17:54:50 / claus" |
|
427 |
"Modified: 13.1.1997 / 20:55:02 / cg" |
|
428 |
"Created: 14.2.1997 / 20:33:10 / cg" |
|
429 |
! |
|
430 |
||
138 | 431 |
openInterface:anInterfaceSymbol |
432 |
"create an instance of the application and open a view as |
|
433 |
specified by anInterfaceSymbol." |
|
434 |
||
361 | 435 |
^ self new openInterface:anInterfaceSymbol |
138 | 436 |
|
437 |
"Modified: 5.9.1995 / 17:54:50 / claus" |
|
361 | 438 |
"Modified: 13.1.1997 / 20:55:02 / cg" |
138 | 439 |
! |
440 |
||
428 | 441 |
openInterface:anInterfaceSymbol at:aPoint |
442 |
"create an instance of the application and open a view as |
|
443 |
specified by anInterfaceSymbol." |
|
444 |
||
445 |
^ self new openInterface:anInterfaceSymbol at:aPoint |
|
446 |
||
447 |
"Modified: 14.2.1997 / 20:28:47 / cg" |
|
448 |
! |
|
449 |
||
138 | 450 |
openOn:anApplicationModel |
215 | 451 |
"send an open message to the argument, anApplicationModel. |
452 |
I dont really understand what this method is useful for ..." |
|
138 | 453 |
|
361 | 454 |
^ anApplicationModel open |
215 | 455 |
|
361 | 456 |
"Modified: 13.1.1997 / 20:55:05 / cg" |
138 | 457 |
! |
458 |
||
459 |
openOnDevice:aDevice |
|
460 |
"create an instance of the application and open its view |
|
215 | 461 |
on ANOTHER device. |
462 |
For more info, read the document on multiple display |
|
463 |
support and the documentation of the DeviceWorkstation class." |
|
138 | 464 |
|
361 | 465 |
^ (self onDevice:aDevice) open |
215 | 466 |
|
361 | 467 |
" |
468 |
Launcher openOnDevice:Display |
|
469 |
" |
|
470 |
||
471 |
"Modified: 13.1.1997 / 20:55:27 / cg" |
|
138 | 472 |
! ! |
473 |
||
474 |
!ApplicationModel methodsFor:'accessing'! |
|
475 |
||
421 | 476 |
application |
477 |
^ self class |
|
478 |
! |
|
479 |
||
138 | 480 |
builder |
481 |
"return the applications builder; this one has more information |
|
482 |
about views, components etc." |
|
483 |
||
484 |
^ builder |
|
485 |
! |
|
486 |
||
487 |
builder:aBuilder |
|
488 |
"set the applications builder. Normally, you should not set it |
|
489 |
directly, but depend on the default builder, as created when the application |
|
490 |
was created." |
|
491 |
||
492 |
builder := aBuilder |
|
493 |
! |
|
494 |
||
495 |
focusSequence |
|
496 |
"return a focusSequence for stepping through the applications views. |
|
497 |
The builder usually keeps track of so-called 'tabable' views. |
|
498 |
Stepping is done with the FocusNext/FocusPrevius keys, which are |
|
499 |
typically bound to Meta-CursorUp/Meta-CursorDown. |
|
500 |
Subclasses which do not use the builder (but instead build their view |
|
501 |
programmatically) should redefine this method to return a collection of |
|
502 |
views which defines the sequence." |
|
503 |
||
504 |
builder notNil ifTrue:[ |
|
505 |
^ builder focusSequence |
|
506 |
]. |
|
507 |
^ nil |
|
508 |
! |
|
509 |
||
510 |
resources |
|
511 |
"return the applications resources - thats a ResourcePack containing |
|
512 |
language strings" |
|
513 |
||
514 |
^ resources |
|
515 |
! |
|
516 |
||
517 |
window |
|
518 |
"return my topWindow" |
|
519 |
||
520 |
^ builder window |
|
521 |
! |
|
522 |
||
187 | 523 |
window:aTopView |
524 |
"set my topWindow" |
|
525 |
||
526 |
builder window:aTopView |
|
527 |
||
528 |
"Created: 18.4.1996 / 14:55:26 / cg" |
|
529 |
! |
|
530 |
||
138 | 531 |
windowGroup |
532 |
"return the applications windowGroup" |
|
533 |
||
534 |
^ builder window windowGroup |
|
535 |
! ! |
|
536 |
||
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
537 |
!ApplicationModel methodsFor:'binding access'! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
538 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
539 |
actionFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
540 |
"sent by the builder to ask for an actionBlock for |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
541 |
a Button. The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
542 |
for a buttons #action property. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
543 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
544 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
545 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
546 |
actionBlocks from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
547 |
Typically, a block is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
548 |
|
421 | 549 |
^ [self perform:aKey] |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
550 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
551 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
552 |
aspectFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
553 |
"sent by the builder to ask for an aspect (a data model). |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
554 |
The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
555 |
for a components #aspect property. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
556 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
557 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
558 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
559 |
holders from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
560 |
Typically, a valueHolder is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
561 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
562 |
^ self perform:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
563 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
564 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
565 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
566 |
clientFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
567 |
"sent by the builder to ask for an application provided |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
568 |
subcanvas's application. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
569 |
The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
570 |
for a subcanvas's #client property. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
571 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
572 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
573 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
574 |
appModels from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
575 |
Typically, an applicationModel is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
576 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
577 |
^ self perform:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
578 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
579 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
580 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
581 |
componentFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
582 |
"sent by the builder to ask for an application provided |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
583 |
component. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
584 |
The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
585 |
for a viewHolders #view property. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
586 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
587 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
588 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
589 |
holders from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
590 |
Typically, a view is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
591 |
|
421 | 592 |
(self respondsTo:aKey) ifTrue:[ |
593 |
^ self perform:aKey |
|
594 |
]. |
|
595 |
^ self application componentFor:aKey |
|
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
596 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
597 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
598 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
599 |
labelFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
600 |
"sent by the builder to ask for an application provided |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
601 |
label for a component. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
602 |
The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
603 |
for a components #label property. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
604 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
605 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
606 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
607 |
labels from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
608 |
Typically, a string is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
609 |
|
421 | 610 |
^ self application labelFor:aKey |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
611 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
612 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
613 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
614 |
listFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
615 |
"sent by the builder to ask for an application provided |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
616 |
holder for a list. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
617 |
The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
618 |
for a listWidgets #list property. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
619 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
620 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
621 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
622 |
holders from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
623 |
Typically, a list-holding model (SelectionInList) is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
624 |
|
421 | 625 |
(self respondsTo:aKey) ifTrue:[ |
626 |
^ self perform:aKey |
|
627 |
]. |
|
628 |
^ self application listFor:aKey |
|
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
629 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
630 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
631 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
632 |
menuFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
633 |
"sent by the builder to ask for an application provided |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
634 |
holder for a menu. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
635 |
The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
636 |
for a widgets #menu property. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
637 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
638 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
639 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
640 |
holders from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
641 |
Typically, a menu or a menu-holding valueHolder is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
642 |
|
421 | 643 |
(self respondsTo:aKey) ifTrue:[ |
644 |
^ self perform:aKey |
|
645 |
]. |
|
646 |
^ self application menuFor:aKey |
|
647 |
||
648 |
! |
|
649 |
||
650 |
specificationFor:aKey |
|
651 |
"sent by the builder to ask for an application provided |
|
652 |
subcanvas's application. |
|
653 |
The argument, aKey comes from an UI-spec |
|
654 |
for a subcanvas's #specification property. |
|
655 |
Here, a corresponding message is sent to myself, |
|
656 |
which ought to be defined in the application subclass. |
|
657 |
Alternatively, a subclass may redefine this method, to provide |
|
658 |
appModels from a Dictionary or whatever. |
|
659 |
Typically, an applicationModel is returned there." |
|
660 |
||
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
661 |
^ self perform:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
662 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
663 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
664 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
665 |
visualFor:aKey |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
666 |
"sent by the builder to ask for an application provided |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
667 |
image or element for a label. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
668 |
The argument, aKey comes from an UI-spec |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
669 |
for a widgets #label property, if LabelIsImage is turned on. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
670 |
Here, a corresponding message is sent to myself, |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
671 |
which ought to be defined in the application subclass. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
672 |
Alternatively, a subclass may redefine this method, to provide |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
673 |
images from a Dictionary or whatever. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
674 |
Typically, an image is returned there." |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
675 |
|
421 | 676 |
^ self application visualFor:aKey |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
677 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
678 |
! ! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
679 |
|
428 | 680 |
!ApplicationModel methodsFor:'component manipulations'! |
681 |
||
682 |
components:aSymbolOrArray do:aBlock |
|
683 |
"evaluate aBlock for all components listed aSymbolOrArray." |
|
684 |
||
685 |
|coll| |
|
686 |
||
687 |
aSymbolOrArray isSymbol ifTrue:[ |
|
688 |
"/ a single components name |
|
689 |
coll := Array with:aSymbolOrArray |
|
690 |
] ifFalse:[ |
|
691 |
coll := aSymbolOrArray |
|
692 |
]. |
|
693 |
coll do:[:aSymbol | |
|
694 |
|component| |
|
695 |
||
696 |
(component := self component:aSymbol) isNil ifFalse:[ |
|
697 |
aBlock value:component |
|
698 |
] |
|
699 |
] |
|
700 |
||
701 |
"Modified: 14.2.1997 / 17:36:42 / cg" |
|
702 |
! |
|
703 |
||
704 |
disable:aSymbolOrArray |
|
705 |
"disable the components whose id's are aSymbolOrArray." |
|
706 |
||
707 |
self components:aSymbolOrArray do:[:comp | comp disable] |
|
708 |
||
709 |
"Modified: 14.2.1997 / 17:32:09 / cg" |
|
710 |
! |
|
711 |
||
712 |
enable:aSymbolOrArray |
|
713 |
"enables the component(s) identified by aSymbolOrArray." |
|
714 |
||
715 |
self components:aSymbolOrArray do:[:comp | comp enable] |
|
716 |
||
717 |
"Modified: 14.2.1997 / 17:32:19 / cg" |
|
718 |
! |
|
719 |
||
720 |
invalidate:aSymbolOrArray |
|
721 |
"invalidates the component(s) identified by aSymbolOrArray." |
|
722 |
||
723 |
self components:aSymbolOrArray do:[:comp | comp invalidate] |
|
724 |
||
725 |
"Modified: 14.2.1997 / 17:32:28 / cg" |
|
726 |
! |
|
727 |
||
728 |
makeInvisible:aSymbolOrArray |
|
729 |
"makes the components whose id's are aSymbolOrArray invisible" |
|
730 |
||
731 |
self components:aSymbolOrArray do:[:comp | comp beInvisible] |
|
732 |
||
733 |
"Modified: 14.2.1997 / 17:32:42 / cg" |
|
734 |
! |
|
735 |
||
736 |
makeReadOnly:aSymbolOrArray |
|
737 |
"make all components identified by aSymbolOrArray read only |
|
738 |
(for editText components)." |
|
739 |
||
740 |
self components:aSymbolOrArray do:[:comp | comp readOnly:true] |
|
741 |
||
742 |
"Modified: 14.2.1997 / 17:36:22 / cg" |
|
743 |
! |
|
744 |
||
745 |
makeVisible:aSymbolOrArray |
|
746 |
"makes the components whose id's are aSymbolOrArray visible" |
|
747 |
||
748 |
self components:aSymbolOrArray do:[:comp | comp beVisible] |
|
749 |
||
750 |
"Modified: 14.2.1997 / 17:32:52 / cg" |
|
751 |
! |
|
752 |
||
753 |
makeWritable:aSymbolOrArray |
|
754 |
"make all components identified by aSymbolOrArray writable |
|
755 |
(for editText components)." |
|
756 |
||
757 |
self components:aSymbolOrArray do:[:comp | comp readOnly:false] |
|
758 |
||
759 |
"Created: 14.2.1997 / 17:36:17 / cg" |
|
760 |
! ! |
|
761 |
||
762 |
!ApplicationModel methodsFor:'drag & drop'! |
|
763 |
||
764 |
canDrop:anObjectOrCollection in:aComponent |
|
765 |
"drop manager asked if a drop is possible |
|
766 |
- should be redefined by apps which can do it, to return true" |
|
767 |
||
768 |
^ false |
|
769 |
||
770 |
||
771 |
! |
|
772 |
||
773 |
drop:anObjectOrCollection in:aComponent at:aPoint |
|
774 |
"drop manager wants to drop. |
|
775 |
This is ony sent, if #canDrop:in: returned true. |
|
776 |
Must be redefined in apps which return true to #canDrop." |
|
777 |
||
778 |
self subclassResponsibility |
|
779 |
||
780 |
||
781 |
! ! |
|
782 |
||
52 | 783 |
!ApplicationModel methodsFor:'initialization'! |
784 |
||
138 | 785 |
addTopViewsToCurrentProject |
786 |
"add all of my topViews to the current projects list of views. |
|
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
787 |
This allows hiding views on a per-project basis. |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
788 |
Applications which do not want to be switched with projects |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
789 |
(such as the Launcher), may redefine this to a noop." |
85 | 790 |
|
138 | 791 |
self windowGroup topViews do:[:aView | |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
792 |
aView addToCurrentProject |
138 | 793 |
] |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
794 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
795 |
"Modified: 17.1.1997 / 19:43:39 / cg" |
85 | 796 |
! |
797 |
||
63 | 798 |
basicInitialize |
69 | 799 |
"initialize the application. |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
800 |
Since ST-80 applications seem commonly to redefine #initialize |
69 | 801 |
without doing a super initialize, the real initialization is |
802 |
done here ..." |
|
803 |
||
52 | 804 |
super initialize. |
72 | 805 |
|
311
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
806 |
device := Screen current. |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
807 |
|
72 | 808 |
"claus: I wanted to delay the creation & assignment of the |
809 |
builder till later, to allow setting to another builder. |
|
810 |
however, some ST-80 code accesses the builder right after instance |
|
811 |
creation ..." |
|
812 |
||
813 |
"/ " |
|
814 |
"/ Create a windowBuilder to have someone around which |
|
815 |
"/ understands the builder protocol. Since UIBuilder is not present |
|
816 |
"/ in all systems, this allows operation without one (unless a spec |
|
817 |
"/ is read later ...) |
|
818 |
"/ " |
|
85 | 819 |
builder := self createBuilder. |
78 | 820 |
builder notNil ifTrue:[builder application:self]. |
52 | 821 |
resources := self class classResources. |
311
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
822 |
|
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
823 |
"Modified: 17.1.1997 / 19:41:59 / cg" |
63 | 824 |
! |
825 |
||
138 | 826 |
createBuilder |
827 |
"create a UI Builder for me. |
|
828 |
This method can be redefined if (eventually) there are |
|
829 |
spec readers for other UI languages (motif UIL ?)" |
|
830 |
||
831 |
|cls| |
|
832 |
||
833 |
(cls := UIBuilder) isNil ifTrue:[ |
|
834 |
(cls := WindowBuilder) isNil ifTrue:[ |
|
835 |
^ nil |
|
836 |
] |
|
837 |
]. |
|
838 |
^ cls new |
|
839 |
! |
|
840 |
||
63 | 841 |
initialize |
83 | 842 |
"nothing done here; |
843 |
but can be redefined in concrete applications" |
|
311
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
844 |
! |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
845 |
|
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
846 |
setDevice:aDevice |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
847 |
"set the device (i.e. some Screen), where the application |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
848 |
shall open its view(s). |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
849 |
The default device (if not set here) will be the current screen." |
311
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
850 |
|
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
851 |
device := aDevice |
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
852 |
|
fa222d8a208c
allow opening an app on another device
Claus Gittinger <cg@exept.de>
parents:
310
diff
changeset
|
853 |
"Created: 5.7.1996 / 12:01:40 / cg" |
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
854 |
"Modified: 17.1.1997 / 19:44:09 / cg" |
138 | 855 |
! ! |
856 |
||
857 |
!ApplicationModel methodsFor:'misc'! |
|
858 |
||
287 | 859 |
restoreCursors |
860 |
"restore the original cursors in all of my views" |
|
861 |
||
862 |
^ self window windowGroup restoreCursors |
|
863 |
||
864 |
"Created: 1.6.1996 / 17:01:24 / cg" |
|
865 |
! |
|
866 |
||
867 |
showCursor:aCursor |
|
868 |
"set all of my views cursor to aCursor. |
|
869 |
It can be restored with #restoreCursor." |
|
870 |
||
871 |
^ self window windowGroup showCursor:aCursor |
|
872 |
||
873 |
"Created: 1.6.1996 / 17:01:09 / cg" |
|
874 |
! |
|
875 |
||
138 | 876 |
withCursor:aCursor do:aBlock |
877 |
"evaluate aBlock, showing aCursor in my topView and all of its subviews. |
|
878 |
Return the value of aBlock." |
|
879 |
||
880 |
^ self window withCursor:aCursor do:aBlock |
|
63 | 881 |
! |
882 |
||
142
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
883 |
withExecuteCursorDo:aBlock |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
884 |
"evaluate aBlock, showing an executeCursor in my topView and all of its subviews. |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
885 |
Return the value of aBlock." |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
886 |
|
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
887 |
^ self withCursor:(Cursor execute) do:aBlock |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
888 |
|
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
889 |
"Created: 14.12.1995 / 20:57:03 / cg" |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
890 |
! |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
891 |
|
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
892 |
withReadCursorDo:aBlock |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
893 |
"evaluate aBlock, showing a readCursor in my topView and all of its subviews. |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
894 |
Return the value of aBlock." |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
895 |
|
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
896 |
^ self withCursor:(Cursor read) do:aBlock |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
897 |
|
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
898 |
"Created: 14.12.1995 / 20:56:47 / cg" |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
899 |
"Modified: 14.12.1995 / 20:57:36 / cg" |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
900 |
! |
6c6259d788a4
added withReadCursorDo: / withExecuteCursorDo:
Claus Gittinger <cg@exept.de>
parents:
138
diff
changeset
|
901 |
|
138 | 902 |
withWaitCursorDo:aBlock |
903 |
"evaluate aBlock, showing a waitCursor in my topView and all of its subviews. |
|
904 |
Return the value of aBlock." |
|
63 | 905 |
|
138 | 906 |
^ self withCursor:Cursor wait do:aBlock |
52 | 907 |
! ! |
57 | 908 |
|
428 | 909 |
!ApplicationModel methodsFor:'opening'! |
910 |
||
911 |
openDialog |
|
912 |
"open the window - assumes that the builder has already setup |
|
913 |
the interface." |
|
914 |
||
915 |
builder openDialog. |
|
916 |
||
917 |
"Modified: 14.2.1997 / 20:32:52 / cg" |
|
918 |
! |
|
919 |
||
920 |
openWindow |
|
921 |
"open the window - assumes that the builder has already setup |
|
922 |
the interface." |
|
923 |
||
924 |
builder openWindow. |
|
925 |
||
926 |
"Created: 14.2.1997 / 20:20:39 / cg" |
|
927 |
! |
|
928 |
||
929 |
openWindowAt:aLocation |
|
930 |
"open the window - assumes that the builder has already setup |
|
931 |
the interface." |
|
932 |
||
933 |
builder openWindowAt:aLocation. |
|
934 |
||
935 |
"Created: 14.2.1997 / 20:20:55 / cg" |
|
936 |
! ! |
|
937 |
||
938 |
!ApplicationModel methodsFor:'private'! |
|
939 |
||
940 |
opened |
|
941 |
"the topView has been opened. |
|
942 |
This is sent by my topView when its really open |
|
943 |
(i.e. finally visible)" |
|
944 |
||
945 |
self addTopViewsToCurrentProject. |
|
946 |
self postOpenWith:builder |
|
947 |
||
948 |
"Modified: 14.2.1997 / 20:26:16 / cg" |
|
949 |
! ! |
|
950 |
||
71 | 951 |
!ApplicationModel methodsFor:'queries'! |
952 |
||
371
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
953 |
defaultWindowType |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
954 |
"Applications come up non-modal, by default" |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
955 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
956 |
^ #normal |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
957 |
|
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
958 |
"Created: 17.1.1997 / 19:57:34 / cg" |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
959 |
! |
ce94ec6a38ee
more ST-80 compatibility stuff
Claus Gittinger <cg@exept.de>
parents:
362
diff
changeset
|
960 |
|
313
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
961 |
graphicsDevice |
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
962 |
"return the device I want to open my views on. |
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
963 |
The default (if not created with #onDevice:) is the currently |
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
964 |
active screen." |
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
965 |
|
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
966 |
^ device |
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
967 |
|
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
968 |
"Created: 5.7.1996 / 17:51:31 / cg" |
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
969 |
! |
09c2e83252f4
added access to graphicsDevice
Claus Gittinger <cg@exept.de>
parents:
311
diff
changeset
|
970 |
|
71 | 971 |
processName |
972 |
"return a name to be shown for me in the process monitor" |
|
973 |
||
974 |
^ 'Application' |
|
975 |
! ! |
|
976 |
||
428 | 977 |
!ApplicationModel methodsFor:'startup / release'! |
57 | 978 |
|
63 | 979 |
allButOpenFrom:aSpec |
69 | 980 |
"create my views but do not open the main window" |
981 |
||
71 | 982 |
|realBuilder| |
983 |
||
72 | 984 |
"/ DISABLED; see comment in basicInitialize |
985 |
"/ |
|
986 |
"/ " |
|
987 |
"/ here, we kludge a bit: up to now, the builder was an |
|
988 |
"/ instance of the no-op WindowBuilder. Now, it becomes |
|
989 |
"/ a UIBuilder .... |
|
990 |
"/ This allows for ApplicationModels without a UIBuilder |
|
991 |
"/ if not needed. |
|
992 |
"/ " |
|
993 |
"/ realBuilder := UIBuilder new. |
|
994 |
"/ builder := realBuilder. |
|
995 |
"/ builder application:self. |
|
996 |
"/ builder bindings:builder bindings. |
|
71 | 997 |
|
63 | 998 |
self preBuildWith:builder. |
999 |
builder buildFromSpec:aSpec. |
|
85 | 1000 |
builder window model:self. |
1001 |
builder window application:self. |
|
63 | 1002 |
self postBuildWith:builder. |
1003 |
! |
|
57 | 1004 |
|
138 | 1005 |
allButOpenInterface:aSymbol |
1006 |
"create my views but do not open the main window" |
|
1007 |
||
1008 |
|spec| |
|
1009 |
||
1010 |
spec := self class interfaceSpecFor:aSymbol. |
|
1011 |
self allButOpenFrom:spec. |
|
1012 |
^ builder |
|
1013 |
! |
|
1014 |
||
1015 |
close |
|
1016 |
"this is sent by my topView when about to be closed |
|
1017 |
by the program (not by the windowManager). |
|
1018 |
Could be redefined in subclasses." |
|
1019 |
||
1020 |
self closeDownViews |
|
1021 |
! |
|
1022 |
||
1023 |
closeDownViews |
|
1024 |
"close down the applications view" |
|
1025 |
||
1026 |
|wg views| |
|
1027 |
||
1028 |
(wg := self windowGroup) notNil ifTrue:[ |
|
1029 |
views := wg topViews. |
|
1030 |
views notNil ifTrue:[ |
|
1031 |
views copy do:[:aView | |
|
1032 |
aView notNil ifTrue:[aView destroy] |
|
1033 |
] |
|
1034 |
] |
|
1035 |
] |
|
1036 |
! |
|
1037 |
||
1038 |
closeRequest |
|
1039 |
"this is sent by my topView when about to be closed by the |
|
1040 |
windowmanager. Can be redefined to inform & query about unsafed |
|
1041 |
view contents, to send #close on ok, or ignore the closeRequest." |
|
1042 |
||
1043 |
self closeDownViews |
|
1044 |
! |
|
1045 |
||
69 | 1046 |
open |
1047 |
"open a standard interface" |
|
1048 |
||
240 | 1049 |
^ self openInterface |
1050 |
||
1051 |
"Modified: 3.5.1996 / 13:39:15 / cg" |
|
69 | 1052 |
! |
1053 |
||
428 | 1054 |
openAsDialogInterface:aSymbol |
1055 |
"open a specific interface as a modal dialog. |
|
1056 |
The argument, aSymbol specifies which interface. The concrete |
|
1057 |
application subclass must provide a method with that name, |
|
1058 |
which must return an interfaceSpec. This is forwarded to |
|
1059 |
the builder to create the views. |
|
1060 |
Typically, applications only use one interface, |
|
1061 |
returned by the #windowSpec method." |
|
1062 |
||
1063 |
self allButOpenInterface:aSymbol. |
|
1064 |
self openDialog. |
|
1065 |
^ builder |
|
1066 |
||
1067 |
"Modified: 14.2.1997 / 20:31:27 / cg" |
|
1068 |
! |
|
1069 |
||
1070 |
openAt:aPoint |
|
1071 |
"open a standard interface at some point" |
|
1072 |
||
1073 |
^ self openInterfaceAt:aPoint |
|
1074 |
||
1075 |
"Modified: 3.5.1996 / 13:39:15 / cg" |
|
1076 |
"Created: 14.2.1997 / 20:17:41 / cg" |
|
1077 |
! |
|
1078 |
||
63 | 1079 |
openInterface |
428 | 1080 |
"open a standard interface. |
215 | 1081 |
|
78 | 1082 |
Subclasses which do not have an interfaceSpec |
215 | 1083 |
should redefine this method and create & open their view(s) there. |
330
d7ce98930ad3
Rename Launcher-->OldLauncher, NewLauncher-->Launcher.
Stefan Vogel <sv@exept.de>
parents:
313
diff
changeset
|
1084 |
(see Launcher as an example)." |
69 | 1085 |
|
63 | 1086 |
self openInterface:#windowSpec |
215 | 1087 |
|
330
d7ce98930ad3
Rename Launcher-->OldLauncher, NewLauncher-->Launcher.
Stefan Vogel <sv@exept.de>
parents:
313
diff
changeset
|
1088 |
"Modified: 9.9.1996 / 22:39:23 / stefan" |
428 | 1089 |
"Modified: 14.2.1997 / 20:18:26 / cg" |
57 | 1090 |
! |
1091 |
||
63 | 1092 |
openInterface:aSymbol |
215 | 1093 |
"open a specific interface. |
1094 |
The argument, aSymbol specifies which interface. The concrete |
|
1095 |
application subclass must provide a method with that name, |
|
1096 |
which must return an interfaceSpec. This is forwarded to |
|
1097 |
the builder to create the views. |
|
69 | 1098 |
Typically, applications only use one interface, |
78 | 1099 |
returned by the #windowSpec method." |
69 | 1100 |
|
85 | 1101 |
self allButOpenInterface:aSymbol. |
428 | 1102 |
self openWindow. |
63 | 1103 |
^ builder |
215 | 1104 |
|
428 | 1105 |
"Modified: 14.2.1997 / 20:25:33 / cg" |
1106 |
! |
|
1107 |
||
1108 |
openInterface:aSymbol at:aLocation |
|
1109 |
"open a specific interface. |
|
1110 |
||
1111 |
The argument, aSymbol specifies which interface. The concrete |
|
1112 |
application subclass must provide a method with that name, |
|
1113 |
which must return an interfaceSpec. This is forwarded to |
|
1114 |
the builder to create the views. |
|
1115 |
Typically, applications only use one interface, |
|
1116 |
returned by the #windowSpec method." |
|
1117 |
||
1118 |
self allButOpenInterface:aSymbol. |
|
1119 |
self openWindowAt:aLocation. |
|
1120 |
^ builder |
|
1121 |
||
1122 |
"Created: 14.2.1997 / 20:19:44 / cg" |
|
1123 |
! |
|
1124 |
||
1125 |
openInterfaceAt:aLocation |
|
1126 |
"open a standard interface." |
|
1127 |
||
1128 |
self openInterface:#windowSpec at:aLocation |
|
1129 |
||
1130 |
"Created: 14.2.1997 / 20:18:20 / cg" |
|
63 | 1131 |
! |
1132 |
||
362 | 1133 |
openOnDevice:aDevice |
1134 |
"open a standard interface on some other device" |
|
1135 |
||
1136 |
self setDevice:aDevice. |
|
1137 |
^ self open |
|
1138 |
||
1139 |
"Created: 13.1.1997 / 21:24:11 / cg" |
|
1140 |
"Modified: 13.1.1997 / 21:24:30 / cg" |
|
1141 |
! |
|
1142 |
||
138 | 1143 |
postBuildWith:aBuilder |
1144 |
"this is sent after an interface is built from a spec. |
|
1145 |
Can be redefined in subclasses. |
|
1146 |
mhmh - what should this do here ?" |
|
1147 |
! |
|
1148 |
||
1149 |
postOpenWith:aBuilder |
|
1150 |
"this is sent after the applications main window is opened. |
|
1151 |
Can be redefined in subclasses. |
|
1152 |
mhmh - what should this do here ?" |
|
1153 |
! |
|
1154 |
||
1155 |
preBuildWith:aBuilder |
|
1156 |
"this is sent before an interface is built from a spec. |
|
1157 |
Can be redefined in subclasses. |
|
1158 |
mhmh - what should this do here ?" |
|
1159 |
! |
|
1160 |
||
69 | 1161 |
restarted |
287 | 1162 |
"sent by my topWindow, when restarted from an image. |
69 | 1163 |
Nothing done here, but can be redefined to perform any actions |
1164 |
required to reset the application after an image-restart. |
|
1165 |
(for example: check if application files are still around, restart |
|
287 | 1166 |
subprocesses etc.)." |
1167 |
||
1168 |
"Modified: 1.6.1996 / 16:55:50 / cg" |
|
63 | 1169 |
! |
57 | 1170 |
|
63 | 1171 |
saveAndTerminateRequest |
1172 |
"some windowManagers send this to shut down an application |
|
1173 |
and have it save its state for restart. |
|
1174 |
Can be redefined in subclasses" |
|
1175 |
||
1176 |
self closeRequest |
|
57 | 1177 |
! ! |
72 | 1178 |
|
85 | 1179 |
!ApplicationModel methodsFor:'window events'! |
1180 |
||
144 | 1181 |
showActivity:someMessage |
215 | 1182 |
"some activityNotification shalt be communicated to |
1183 |
the user. Forwarded from the topView and ignored here. |
|
1184 |
Can be redefined in concrete applications to show the |
|
1185 |
message either in some infoView (infoLabel as in Windows) |
|
1186 |
or in the title area (as done in the browsers)" |
|
1187 |
||
144 | 1188 |
^ self |
1189 |
||
1190 |
"Created: 16.12.1995 / 18:41:04 / cg" |
|
215 | 1191 |
"Modified: 24.4.1996 / 09:34:22 / cg" |
144 | 1192 |
! |
1193 |
||
85 | 1194 |
windowEvent:anEvent from:anApplicationWindow |
215 | 1195 |
"dummy: windowEvent forwarding is not yet implemented" |
1196 |
||
85 | 1197 |
^ self |
215 | 1198 |
|
1199 |
"Modified: 24.4.1996 / 09:32:50 / cg" |
|
85 | 1200 |
! ! |
1201 |
||
361 | 1202 |
!ApplicationModel class methodsFor:'documentation'! |
72 | 1203 |
|
138 | 1204 |
version |
428 | 1205 |
^ '$Header: /cvs/stx/stx/libview2/ApplicationModel.st,v 1.38 1997-02-14 19:35:21 cg Exp $' |
81 | 1206 |
! ! |
138 | 1207 |
ApplicationModel initialize! |