equal
deleted
inserted
replaced
22 COPYRIGHT (c) 1990 by Claus Gittinger |
22 COPYRIGHT (c) 1990 by Claus Gittinger |
23 All Rights Reserved |
23 All Rights Reserved |
24 |
24 |
25 this class implements boxes for selection from a list |
25 this class implements boxes for selection from a list |
26 |
26 |
27 $Header: /cvs/stx/stx/libwidg/Attic/LSelBox.st,v 1.3 1993-10-13 02:48:17 claus Exp $ |
27 $Header: /cvs/stx/stx/libwidg/Attic/LSelBox.st,v 1.4 1993-12-16 11:03:01 claus Exp $ |
28 |
28 |
29 written Jan 90 by claus |
29 written Jan 90 by claus |
30 '! |
30 '! |
31 |
31 |
32 !ListSelectionBox class methodsFor:'defaults'! |
32 !ListSelectionBox class methodsFor:'defaults'! |
33 |
33 |
34 defaultExtent |
34 defaultExtent |
35 ^ (Display pixelPerMillimeter * (80 @ 100)) rounded |
35 ^ (Display pixelPerMillimeter * (80 @ 100)) rounded |
|
36 ! |
|
37 |
|
38 listViewType |
|
39 "return the type of listView |
|
40 - for easier redefinition in subclasses" |
|
41 |
|
42 ^ SelectionInListView |
36 ! ! |
43 ! ! |
37 |
44 |
38 !ListSelectionBox class methodsFor:'instance creation'! |
45 !ListSelectionBox class methodsFor:'instance creation'! |
39 |
46 |
40 title:titleString okText:okText abortText:abortText list:aList action:aBlock |
47 title:titleString okText:okText abortText:abortText list:aList action:aBlock |
58 |
65 |
59 "self height:(height + (font height * 5)). " |
66 "self height:(height + (font height * 5)). " |
60 |
67 |
61 space2 := 2 * ViewSpacing. |
68 space2 := 2 * ViewSpacing. |
62 |
69 |
63 v := ScrollableView for:SelectionInListView in:self. |
70 v := ScrollableView for:(self class listViewType) in:self. |
64 |
71 |
65 "kludge: see note in EnterBox" |
72 "kludge: see note in EnterBox" |
66 v origin:(ViewSpacing |
73 v origin:(ViewSpacing |
67 @ |
74 @ |
68 (enterField origin y + enterField height + ViewSpacing)). |
75 (enterField origin y + enterField height + ViewSpacing)). |