7 inclusion of the above copyright notice. This software may not |
7 inclusion of the above copyright notice. This software may not |
8 be provided or otherwise made available to, or used by, any |
8 be provided or otherwise made available to, or used by, any |
9 other person. No title to or ownership of the software is |
9 other person. No title to or ownership of the software is |
10 hereby transferred. |
10 hereby transferred. |
11 " |
11 " |
12 |
|
13 |
|
14 |
|
15 |
|
16 "{ Package: 'stx:libtool2' }" |
12 "{ Package: 'stx:libtool2' }" |
17 |
13 |
18 ApplicationModel subclass:#UISpecificationTool |
14 ApplicationModel subclass:#UISpecificationTool |
19 instanceVariableNames:'modifiedHolder aspects specification selection specChannel |
15 instanceVariableNames:'modifiedHolder aspects specification selection specChannel |
20 buildInView listOfSpecViews' |
16 buildInView listOfSpecViews' |
347 ]. |
343 ]. |
348 ! ! |
344 ! ! |
349 |
345 |
350 !UISpecificationTool::BuildInView methodsFor:'accessing'! |
346 !UISpecificationTool::BuildInView methodsFor:'accessing'! |
351 |
347 |
|
348 mapped |
|
349 super mapped. |
|
350 |
|
351 scrolledView notNil ifTrue:[ |
|
352 scrolledView beVisible. |
|
353 scrolledView raise. |
|
354 ]. |
|
355 ! |
|
356 |
352 scrolledView:aView |
357 scrolledView:aView |
353 "set the view to be scrolled" |
358 "set the view to be scrolled" |
354 |wrapper y| |
359 |wrapper y| |
355 |
360 |
356 scrolledView == aView ifTrue:[^ self]. |
361 scrolledView == aView ifTrue:[^ self]. |
357 |
362 |
358 scrolledView notNil ifTrue:[scrolledView beInvisible]. |
363 scrolledView notNil ifTrue:[ |
359 |
364 scrolledView unmap. |
360 scrolledView := aView. |
365 ]. |
361 |
366 (scrolledView := aView) notNil ifTrue:[ |
362 (scrolledView notNil and:[scrolledView superView ~~ frame]) ifTrue:[ |
367 scrolledView superView ~~ frame ifTrue:[ |
363 scrolledView borderWidth:0; level:0. |
368 scrolledView borderWidth:0; level:0. |
364 |
369 |
365 frame addSubView:scrolledView. |
370 frame addSubView:scrolledView. |
366 |
371 |
367 scrolledView subViews size == 1 ifTrue:[ |
372 scrolledView subViews size == 1 ifTrue:[ |
368 wrapper := scrolledView subViews first. |
373 wrapper := scrolledView subViews first. |
369 wrapper isScrollWrapper ifTrue:[ |
374 wrapper isScrollWrapper ifTrue:[ |
370 "/ give it a full-relative size, and let it do |
375 "/ give it a full-relative size, and let it do |
371 "/ the scrolling itself. |
376 "/ the scrolling itself. |
372 y := 1.0 |
377 y := 1.0 |
373 ] |
378 ] |
|
379 ]. |
|
380 y isNil ifTrue:[ |
|
381 y := scrolledView preferredExtent y |
|
382 ]. |
|
383 scrolledView origin:0@0 corner:1.0 @ y. |
|
384 scrolledView allViewBackground:(self viewBackground). |
374 ]. |
385 ]. |
375 y isNil ifTrue:[ |
386 ]. |
376 y := scrolledView preferredExtent y |
387 shown ifTrue:[ |
377 ]. |
388 scrolledView beVisible. |
378 scrolledView origin:0@0 corner:1.0 @ y. |
389 scrolledView raise. |
379 scrolledView allViewBackground:(self viewBackground). |
|
380 ]. |
|
381 |
|
382 realized ifTrue:[ |
|
383 scrolledView ifNotNil:[scrolledView beVisible]. |
|
384 self sizeChanged:nil. |
390 self sizeChanged:nil. |
385 ]. |
391 ]. |
386 model value:scrolledView. |
392 model value:scrolledView. |
387 ! ! |
393 ! ! |
388 |
394 |