author | Claus Gittinger <cg@exept.de> |
Tue, 28 Nov 2017 17:10:23 +0100 | |
changeset 3508 | a526b342d12c |
parent 3306 | a2d6e8a1bcaf |
permissions | -rw-r--r-- |
300 | 1 |
" |
736 | 2 |
COPYRIGHT (c) 1997 by eXept Software AG |
300 | 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 |
|
736 | 7 |
inclusion of the above copyright notice. This software may not |
300 | 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 |
" |
|
3306 | 12 |
"{ Package: 'stx:libtool2' }" |
300 | 13 |
|
3306 | 14 |
"{ NameSpace: Smalltalk }" |
1499
0c57ab09156b
about menu items moved into the Help-menu
Claus Gittinger <cg@exept.de>
parents:
1065
diff
changeset
|
15 |
|
736 | 16 |
ResourceSpecEditor subclass:#HierarchicalListEditor |
731 | 17 |
instanceVariableNames:'treeView' |
18 |
classVariableNames:'' |
|
300 | 19 |
poolDictionaries:'' |
20 |
category:'Interface-UIPainter' |
|
21 |
! |
|
22 |
||
23 |
!HierarchicalListEditor class methodsFor:'documentation'! |
|
24 |
||
25 |
copyright |
|
26 |
" |
|
736 | 27 |
COPYRIGHT (c) 1997 by eXept Software AG |
300 | 28 |
All Rights Reserved |
29 |
||
30 |
This software is furnished under a license and may be used |
|
31 |
only in accordance with the terms of that license and with the |
|
736 | 32 |
inclusion of the above copyright notice. This software may not |
300 | 33 |
be provided or otherwise made available to, or used by, any |
34 |
other person. No title to or ownership of the software is |
|
35 |
hereby transferred. |
|
36 |
" |
|
37 |
||
38 |
||
39 |
||
40 |
! |
|
41 |
||
42 |
documentation |
|
43 |
" |
|
731 | 44 |
The HierarchicalListEditor allows you to create, modify or just inspect |
45 |
(statical) hierarchical lists for the SelectionInListView. |
|
300 | 46 |
|
47 |
[start with:] |
|
48 |
HierarchicalListEditor open |
|
49 |
||
50 |
[see also:] |
|
51 |
UIPainter |
|
52 |
||
53 |
[author:] |
|
546 | 54 |
Claus Atzkern, eXept Software AG |
731 | 55 |
Thomas Zwick, eXept Software AG |
300 | 56 |
" |
57 |
||
58 |
||
59 |
||
60 |
! ! |
|
61 |
||
731 | 62 |
!HierarchicalListEditor class methodsFor:'instance creation'! |
63 |
||
64 |
openModalOnTreeItem: aTreeItem |
|
65 |
"Open a HierarchicalListEditor modal on aTreeItem" |
|
66 |
"self openModalOnTreeItem: (TreeItem name: 'Label' contents: #Contents)" |
|
67 |
||
68 |
^self new openModalOnTreeItem: aTreeItem |
|
69 |
||
70 |
! ! |
|
71 |
||
72 |
!HierarchicalListEditor class methodsFor:'accessing'! |
|
73 |
||
74 |
resourceType |
|
75 |
"get the type of resource of the method generated by the HierarchicalListEditor" |
|
76 |
||
77 |
^#hierarchicalList |
|
78 |
||
79 |
! ! |
|
80 |
||
551 | 81 |
!HierarchicalListEditor class methodsFor:'help specs'! |
82 |
||
83 |
helpSpec |
|
736 | 84 |
"This resource specification was automatically generated |
85 |
by the UIHelpTool of ST/X." |
|
86 |
||
87 |
"Do not manually edit this!! If it is corrupted, |
|
88 |
the UIHelpTool may not be able to read the specification." |
|
551 | 89 |
|
90 |
" |
|
736 | 91 |
UIHelpTool openOnClass:HierarchicalListEditor |
551 | 92 |
" |
93 |
||
736 | 94 |
<resource: #help> |
95 |
||
96 |
^super helpSpec addPairsFrom:#( |
|
551 | 97 |
|
98 |
#addChild |
|
99 |
'Adds a new child item.' |
|
100 |
||
101 |
#addSister |
|
102 |
'Adds a new sister item.' |
|
103 |
||
581 | 104 |
#contents |
105 |
'Contents of the tree item.' |
|
106 |
||
731 | 107 |
#fileLoad |
108 |
'Opens a dialog for selecting and loading a hierarchical list spec from a class.' |
|
109 |
||
551 | 110 |
#fileNew |
736 | 111 |
'Creates a new hierarchical list. ' |
551 | 112 |
|
731 | 113 |
#fileSave |
114 |
'Saves current hierarchical list spec.' |
|
552 | 115 |
|
731 | 116 |
#fileSaveAs |
117 |
'Opens a dialog to save current hierarchical list spec.' |
|
552 | 118 |
|
581 | 119 |
#label |
120 |
'Label of the tree item.' |
|
121 |
||
551 | 122 |
) |
123 |
! ! |
|
124 |
||
731 | 125 |
!HierarchicalListEditor class methodsFor:'image specs'! |
300 | 126 |
|
731 | 127 |
createChildIcon |
736 | 128 |
"This resource specification was automatically generated |
129 |
by the ImageEditor of ST/X." |
|
130 |
||
131 |
"Do not manually edit this!! If it is corrupted, |
|
132 |
the ImageEditor may not be able to read the specification." |
|
133 |
||
300 | 134 |
" |
736 | 135 |
ImageEditor openOnClass:self andSelector:#createChildIcon |
300 | 136 |
" |
137 |
||
731 | 138 |
<resource: #image> |
139 |
||
140 |
^Icon |
|
141 |
constantNamed:#'HierarchicalListEditor createChildIcon' |
|
1499
0c57ab09156b
about menu items moved into the Help-menu
Claus Gittinger <cg@exept.de>
parents:
1065
diff
changeset
|
142 |
ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@AUUUUP@@A????2@@A????2 @A????0@@A?????8@A?????8@A?????8@A?????8@A?????8@A?????8@A?????8@A?????8@A?????8@A<3L308@A33L33H@A30L33H@A33L33H@A<3L008@A?????8@C*****(@@@@@@@@@') ; colorMapFromArray:#[0 0 0 255 255 255 127 127 127 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'_?>@_??@_?? _??0_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8') ; yourself); yourself] |
0c57ab09156b
about menu items moved into the Help-menu
Claus Gittinger <cg@exept.de>
parents:
1065
diff
changeset
|
143 |
! |
300 | 144 |
|
731 | 145 |
createSisterIcon |
736 | 146 |
"This resource specification was automatically generated |
147 |
by the ImageEditor of ST/X." |
|
148 |
||
149 |
"Do not manually edit this!! If it is corrupted, |
|
150 |
the ImageEditor may not be able to read the specification." |
|
151 |
||
731 | 152 |
" |
736 | 153 |
ImageEditor openOnClass:self andSelector:#createSisterIcon |
731 | 154 |
" |
155 |
||
156 |
<resource: #image> |
|
157 |
||
158 |
^Icon |
|
159 |
constantNamed:#'HierarchicalListEditor createSisterIcon' |
|
1499
0c57ab09156b
about menu items moved into the Help-menu
Claus Gittinger <cg@exept.de>
parents:
1065
diff
changeset
|
160 |
ifAbsentPut:[(Depth2Image new) width: 22; height: 22; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@AUUUUP@@A????2@@A????2 @A????0@@A?????8@A?????8@A?????8@A<L<O?8@A3<3??8@A<<<<C8@A?L?O?8@A0<0??8@A?????8@A0LCC?8@A<<?L?8@A<<CC?8@A<<?L?8@A<<CL?8@A?????8@C*****(@@@@@@@@@') ; colorMapFromArray:#[0 0 0 255 255 255 127 127 127 170 170 170]; mask:((Depth1Image new) width: 22; height: 22; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'_?>@_??@_?? _??0_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8_??8') ; yourself); yourself] |
0c57ab09156b
about menu items moved into the Help-menu
Claus Gittinger <cg@exept.de>
parents:
1065
diff
changeset
|
161 |
! ! |
731 | 162 |
|
163 |
!HierarchicalListEditor class methodsFor:'interface specs'! |
|
300 | 164 |
|
165 |
windowSpec |
|
736 | 166 |
"This resource specification was automatically generated |
167 |
by the UIPainter of ST/X." |
|
300 | 168 |
|
736 | 169 |
"Do not manually edit this!! If it is corrupted, |
170 |
the UIPainter may not be able to read the specification." |
|
300 | 171 |
|
172 |
" |
|
173 |
UIPainter new openOnClass:HierarchicalListEditor andSelector:#windowSpec |
|
174 |
HierarchicalListEditor new openInterface:#windowSpec |
|
736 | 175 |
HierarchicalListEditor open |
300 | 176 |
" |
177 |
||
178 |
<resource: #canvas> |
|
179 |
||
1686
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
180 |
^ |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
181 |
#(#FullSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
182 |
#name: #windowSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
183 |
#window: |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
184 |
#(#WindowSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
185 |
#label: 'Hierarchical List Editor' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
186 |
#name: 'Hierarchical List Editor' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
187 |
#min: #(#Point 450 280) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
188 |
#max: #(#Point 1152 900) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
189 |
#bounds: #(#Rectangle 16 46 486 376) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
190 |
#menu: #menu |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
191 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
192 |
#component: |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
193 |
#(#SpecCollection |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
194 |
#collection: #( |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
195 |
#(#MenuPanelSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
196 |
#name: 'menuToolbarView' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
197 |
#layout: #(#LayoutFrame 0 0.0 0 0.0 0 1.0 32 0) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
198 |
#menu: #menuToolbar |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
199 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
200 |
#(#VariableHorizontalPanelSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
201 |
#name: 'VariableHorizontalPanel' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
202 |
#layout: #(#LayoutFrame 0 0.0 34 0.0 0 1.0 -26 1.0) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
203 |
#component: |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
204 |
#(#SpecCollection |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
205 |
#collection: #( |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
206 |
#(#ArbitraryComponentSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
207 |
#name: 'TreeView' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
208 |
#menu: #menuEdit |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
209 |
#hasHorizontalScrollBar: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
210 |
#hasVerticalScrollBar: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
211 |
#miniScrollerHorizontal: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
212 |
#miniScrollerVertical: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
213 |
#hasBorder: false |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
214 |
#component: #treeView |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
215 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
216 |
#(#ViewSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
217 |
#name: 'SpecView' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
218 |
#level: -1 |
731 | 219 |
#component: |
1686
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
220 |
#(#SpecCollection |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
221 |
#collection: #( |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
222 |
#(#LabelSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
223 |
#label: 'Label:' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
224 |
#name: 'nameLabel' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
225 |
#layout: #(#AlignmentOrigin 98 0 26 0 1 0.5) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
226 |
#resizeForLabel: true |
1875 | 227 |
translateLabel: true |
1686
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
228 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
229 |
#(#InputFieldSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
230 |
#name: 'labelInputField' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
231 |
#layout: #(#LayoutFrame 100 0 15 0 -5 1.0 37 0) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
232 |
#activeHelpKey: #label |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
233 |
#tabable: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
234 |
#model: #itemName |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
235 |
#acceptOnLeave: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
236 |
#acceptOnLostFocus: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
237 |
#acceptChannel: #acceptChannel |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
238 |
#modifiedChannel: #modifiedChannel |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
239 |
#acceptOnPointerLeave: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
240 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
241 |
#(#LabelSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
242 |
#label: 'Contents:' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
243 |
#name: 'valueLabel' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
244 |
#layout: #(#AlignmentOrigin 98 0 52 0 1 0.5) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
245 |
#activeHelpKey: #contents |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
246 |
#resizeForLabel: true |
1875 | 247 |
translateLabel: true |
300 | 248 |
) |
1686
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
249 |
#(#InputFieldSpec |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
250 |
#name: 'valueInputField' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
251 |
#layout: #(#LayoutFrame 100 0 41 0 -5 1.0 63 0) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
252 |
#activeHelpKey: #contents |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
253 |
#tabable: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
254 |
#model: #itemValue |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
255 |
#type: #smalltalkObject |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
256 |
#acceptOnLeave: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
257 |
#acceptOnLostFocus: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
258 |
#acceptChannel: #acceptChannel |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
259 |
#modifiedChannel: #modifiedChannel |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
260 |
#acceptOnPointerLeave: true |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
261 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
262 |
#(#UISubSpecification |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
263 |
#name: 'SubSpecification' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
264 |
#layout: #(#LayoutFrame 2 0.0 -26 1.0 -2 1.0 -2 1.0) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
265 |
#majorKey: #ToolApplicationModel |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
266 |
#minorKey: #windowSpecForCommit |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
267 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
268 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
269 |
|
300 | 270 |
) |
1686
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
271 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
272 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
273 |
|
300 | 274 |
) |
1686
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
275 |
#handles: #(#Any 0.368421 1.0) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
276 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
277 |
#(#UISubSpecification |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
278 |
#name: 'InfoBarSubSpec' |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
279 |
#layout: #(#LayoutFrame 0 0.0 -24 1 0 1.0 0 1.0) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
280 |
#majorKey: #ToolApplicationModel |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
281 |
#minorKey: #windowSpecForInfoBar |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
282 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
283 |
) |
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
284 |
|
5d20782f58f9
allow any object as contents;
Claus Gittinger <cg@exept.de>
parents:
1575
diff
changeset
|
285 |
) |
300 | 286 |
) |
287 |
! ! |
|
288 |
||
506 | 289 |
!HierarchicalListEditor class methodsFor:'menu specs'! |
290 |
||
291 |
menu |
|
736 | 292 |
"This resource specification was automatically generated |
293 |
by the MenuEditor of ST/X." |
|
506 | 294 |
|
736 | 295 |
"Do not manually edit this!! If it is corrupted, |
296 |
the MenuEditor may not be able to read the specification." |
|
506 | 297 |
|
298 |
" |
|
299 |
MenuEditor new openOnClass:HierarchicalListEditor andSelector:#menu |
|
300 |
(Menu new fromLiteralArrayEncoding:(HierarchicalListEditor menu)) startUp |
|
301 |
" |
|
302 |
||
303 |
<resource: #menu> |
|
304 |
||
305 |
^ |
|
306 |
||
307 |
#(#Menu |
|
308 |
||
309 |
#( |
|
310 |
#(#MenuItem |
|
731 | 311 |
#label: 'File' |
312 |
#submenu: |
|
506 | 313 |
#(#Menu |
314 |
||
315 |
#( |
|
316 |
#(#MenuItem |
|
731 | 317 |
#label: 'New' |
318 |
#value: #doNew |
|
319 |
#activeHelpKey: #fileNew |
|
506 | 320 |
) |
321 |
#(#MenuItem |
|
731 | 322 |
#label: '-' |
522 | 323 |
) |
324 |
#(#MenuItem |
|
731 | 325 |
#label: 'Load...' |
326 |
#translateLabel: true |
|
327 |
#value: #doLoad |
|
328 |
#activeHelpKey: #fileLoad |
|
506 | 329 |
) |
330 |
#(#MenuItem |
|
731 | 331 |
#label: '-' |
506 | 332 |
) |
333 |
#(#MenuItem |
|
731 | 334 |
#label: 'Save' |
335 |
#value: #doSave |
|
336 |
#activeHelpKey: #fileSave |
|
506 | 337 |
) |
338 |
#(#MenuItem |
|
731 | 339 |
#label: 'Save As...' |
340 |
#value: #doSaveAs |
|
341 |
#activeHelpKey: #fileSaveAs |
|
506 | 342 |
) |
343 |
#(#MenuItem |
|
731 | 344 |
#label: '-' |
506 | 345 |
) |
346 |
#(#MenuItem |
|
731 | 347 |
#label: 'Browse Class' |
348 |
#value: #doBrowseClass |
|
349 |
#activeHelpKey: #fileBrowseClass |
|
350 |
#enabled: #hasValidClass |
|
581 | 351 |
) |
352 |
#(#MenuItem |
|
731 | 353 |
#label: '-' |
581 | 354 |
) |
355 |
#(#MenuItem |
|
731 | 356 |
#label: 'Exit' |
357 |
#value: #closeRequest |
|
358 |
#activeHelpKey: #fileExit |
|
506 | 359 |
) |
360 |
) nil |
|
361 |
nil |
|
362 |
) |
|
363 |
) |
|
364 |
#(#MenuItem |
|
731 | 365 |
#label: 'Edit' |
366 |
#submenuChannel: #menuEdit |
|
506 | 367 |
) |
368 |
#(#MenuItem |
|
731 | 369 |
#label: 'Add' |
370 |
#submenu: |
|
522 | 371 |
#(#Menu |
372 |
||
373 |
#( |
|
374 |
#(#MenuItem |
|
731 | 375 |
#label: 'Child' |
376 |
#value: #doCreateChild |
|
377 |
#activeHelpKey: #addChild |
|
378 |
#enabled: #canCreateChildChannel |
|
379 |
#labelImage: #(#ResourceRetriever #HierarchicalListEditor #createChildIcon 'Child') |
|
522 | 380 |
) |
381 |
#(#MenuItem |
|
731 | 382 |
#label: 'Sister' |
383 |
#value: #doCreateSister |
|
384 |
#activeHelpKey: #addSister |
|
385 |
#enabled: #canCreateSisterChannel |
|
386 |
#labelImage: #(#ResourceRetriever #HierarchicalListEditor #createSisterIcon 'Sister') |
|
522 | 387 |
) |
388 |
) nil |
|
389 |
nil |
|
390 |
) |
|
391 |
) |
|
392 |
#(#MenuItem |
|
747 | 393 |
#label: 'History' |
394 |
#submenuChannel: #menuHistory |
|
395 |
) |
|
396 |
#(#MenuItem |
|
731 | 397 |
#label: 'Help' |
398 |
#startGroup: #right |
|
399 |
#submenuChannel: #menuHelp |
|
546 | 400 |
) |
506 | 401 |
) nil |
402 |
nil |
|
403 |
) |
|
404 |
! |
|
405 |
||
406 |
menuEdit |
|
736 | 407 |
"This resource specification was automatically generated |
408 |
by the MenuEditor of ST/X." |
|
506 | 409 |
|
736 | 410 |
"Do not manually edit this!! If it is corrupted, |
411 |
the MenuEditor may not be able to read the specification." |
|
506 | 412 |
|
413 |
" |
|
414 |
MenuEditor new openOnClass:HierarchicalListEditor andSelector:#menuEdit |
|
415 |
(Menu new fromLiteralArrayEncoding:(HierarchicalListEditor menuEdit)) startUp |
|
416 |
" |
|
417 |
||
418 |
<resource: #menu> |
|
419 |
||
420 |
^ |
|
421 |
||
422 |
#(#Menu |
|
423 |
||
424 |
#( |
|
425 |
#(#MenuItem |
|
731 | 426 |
#label: 'Cut' |
427 |
#value: #doCut |
|
428 |
#activeHelpKey: #editCut |
|
429 |
#enabled: #valueOfCanCut |
|
430 |
) |
|
431 |
#(#MenuItem |
|
432 |
#label: 'Copy' |
|
433 |
#value: #doCopy |
|
434 |
#activeHelpKey: #editCopy |
|
435 |
#enabled: #valueOfCanCopy |
|
506 | 436 |
) |
437 |
#(#MenuItem |
|
731 | 438 |
#label: 'Paste' |
439 |
#value: #doPaste |
|
440 |
#activeHelpKey: #editPaste |
|
441 |
#enabled: #valueOfCanPaste |
|
506 | 442 |
) |
443 |
#(#MenuItem |
|
731 | 444 |
#label: 'Delete' |
445 |
#value: #doDelete |
|
446 |
#activeHelpKey: #editPaste |
|
447 |
#enabled: #valueOfCanCut |
|
506 | 448 |
) |
449 |
#(#MenuItem |
|
731 | 450 |
#label: '-' |
506 | 451 |
) |
452 |
#(#MenuItem |
|
731 | 453 |
#label: 'Move Up' |
454 |
#value: #doStepUp |
|
455 |
#activeHelpKey: #editMoveUp |
|
456 |
#enabled: #canStepOverChannel |
|
882 | 457 |
#labelImage: #(#ResourceRetriever #Icon #upIcon 'Move Up') |
506 | 458 |
) |
459 |
#(#MenuItem |
|
731 | 460 |
#label: 'Move Down' |
461 |
#value: #doStepDown |
|
462 |
#activeHelpKey: #editMoveDown |
|
463 |
#enabled: #canStepOverChannel |
|
882 | 464 |
#labelImage: #(#ResourceRetriever #Icon #downIcon 'Move Down') |
506 | 465 |
) |
466 |
#(#MenuItem |
|
731 | 467 |
#label: 'Move In' |
468 |
#value: #doStepIn |
|
469 |
#activeHelpKey: #editMoveIn |
|
470 |
#enabled: #canStepInChannel |
|
882 | 471 |
#labelImage: #(#ResourceRetriever #Icon #downRightIcon 'Move In') |
506 | 472 |
) |
473 |
#(#MenuItem |
|
731 | 474 |
#label: 'Move Out' |
475 |
#value: #doStepOut |
|
476 |
#activeHelpKey: #editMoveOut |
|
477 |
#enabled: #canStepOutChannel |
|
882 | 478 |
#labelImage: #(#ResourceRetriever #Icon #leftDownIcon 'Move Out') |
506 | 479 |
) |
480 |
) nil |
|
481 |
nil |
|
482 |
) |
|
483 |
! |
|
484 |
||
485 |
menuToolbar |
|
736 | 486 |
"This resource specification was automatically generated |
487 |
by the MenuEditor of ST/X." |
|
506 | 488 |
|
736 | 489 |
"Do not manually edit this!! If it is corrupted, |
490 |
the MenuEditor may not be able to read the specification." |
|
506 | 491 |
|
492 |
" |
|
493 |
MenuEditor new openOnClass:HierarchicalListEditor andSelector:#menuToolbar |
|
494 |
(Menu new fromLiteralArrayEncoding:(HierarchicalListEditor menuToolbar)) startUp |
|
495 |
" |
|
496 |
||
497 |
<resource: #menu> |
|
498 |
||
499 |
^ |
|
500 |
||
501 |
#(#Menu |
|
502 |
||
503 |
#( |
|
504 |
#(#MenuItem |
|
731 | 505 |
#label: 'New' |
506 |
#isButton: true |
|
507 |
#value: #doNew |
|
508 |
#activeHelpKey: #fileNew |
|
882 | 509 |
#labelImage: #(#ResourceRetriever #Icon #newIcon) |
506 | 510 |
) |
511 |
#(#MenuItem |
|
731 | 512 |
#label: 'Load' |
513 |
#isButton: true |
|
514 |
#value: #doLoad |
|
515 |
#activeHelpKey: #fileLoad |
|
882 | 516 |
#labelImage: #(#ResourceRetriever #Icon #loadIcon) |
731 | 517 |
) |
518 |
#(#MenuItem |
|
519 |
#label: 'Save' |
|
520 |
#isButton: true |
|
521 |
#value: #doSave |
|
522 |
#activeHelpKey: #fileSave |
|
882 | 523 |
#labelImage: #(#ResourceRetriever #Icon #saveIcon) |
506 | 524 |
) |
525 |
#(#MenuItem |
|
731 | 526 |
#label: '' |
527 |
) |
|
528 |
#(#MenuItem |
|
529 |
#label: 'Cut' |
|
530 |
#isButton: true |
|
531 |
#value: #doCut |
|
532 |
#activeHelpKey: #editCut |
|
533 |
#enabled: #valueOfCanCut |
|
882 | 534 |
#labelImage: #(#ResourceRetriever #Icon #cutIcon) |
506 | 535 |
) |
536 |
#(#MenuItem |
|
731 | 537 |
#label: 'Copy' |
538 |
#isButton: true |
|
539 |
#value: #doCopy |
|
540 |
#activeHelpKey: #editCopy |
|
541 |
#enabled: #valueOfCanCopy |
|
882 | 542 |
#labelImage: #(#ResourceRetriever #Icon #copyIcon) |
506 | 543 |
) |
544 |
#(#MenuItem |
|
731 | 545 |
#label: 'Paste' |
546 |
#isButton: true |
|
547 |
#value: #doPaste |
|
548 |
#activeHelpKey: #editPaste |
|
549 |
#enabled: #valueOfCanPaste |
|
882 | 550 |
#labelImage: #(#ResourceRetriever #Icon #pasteIcon) |
506 | 551 |
) |
552 |
#(#MenuItem |
|
731 | 553 |
#label: 'Delete' |
554 |
#isButton: true |
|
555 |
#value: #doDelete |
|
556 |
#activeHelpKey: #editDelete |
|
557 |
#enabled: #valueOfCanCut |
|
882 | 558 |
#labelImage: #(#ResourceRetriever #Icon #deleteIcon) |
731 | 559 |
) |
560 |
#(#MenuItem |
|
561 |
#label: '' |
|
506 | 562 |
) |
563 |
#(#MenuItem |
|
731 | 564 |
#label: 'Add Child' |
565 |
#isButton: true |
|
566 |
#value: #doCreateChild |
|
567 |
#activeHelpKey: #addChild |
|
568 |
#enabled: #canCreateChildChannel |
|
569 |
#labelImage: #(#ResourceRetriever nil #createChildIcon) |
|
570 |
) |
|
571 |
#(#MenuItem |
|
572 |
#label: 'Add Sister' |
|
573 |
#isButton: true |
|
574 |
#value: #doCreateSister |
|
575 |
#activeHelpKey: #addSister |
|
576 |
#enabled: #canCreateSisterChannel |
|
577 |
#labelImage: #(#ResourceRetriever nil #createSisterIcon) |
|
578 |
) |
|
579 |
#(#MenuItem |
|
580 |
#label: '' |
|
506 | 581 |
) |
582 |
#(#MenuItem |
|
731 | 583 |
#label: 'Move Up' |
584 |
#isButton: true |
|
585 |
#value: #doStepUp |
|
586 |
#activeHelpKey: #editMoveUp |
|
587 |
#enabled: #canStepOverChannel |
|
882 | 588 |
#labelImage: #(#ResourceRetriever #Icon #upIcon) |
506 | 589 |
) |
590 |
#(#MenuItem |
|
731 | 591 |
#label: 'Move Down' |
592 |
#isButton: true |
|
593 |
#value: #doStepDown |
|
594 |
#activeHelpKey: #editMoveDown |
|
595 |
#enabled: #canStepOverChannel |
|
882 | 596 |
#labelImage: #(#ResourceRetriever #Icon #downIcon) |
506 | 597 |
) |
598 |
#(#MenuItem |
|
731 | 599 |
#label: 'Move In' |
600 |
#isButton: true |
|
601 |
#value: #doStepIn |
|
602 |
#activeHelpKey: #editMoveIn |
|
603 |
#enabled: #canStepInChannel |
|
882 | 604 |
#labelImage: #(#ResourceRetriever #Icon #downRightIcon) |
731 | 605 |
) |
606 |
#(#MenuItem |
|
607 |
#label: 'Move Out' |
|
608 |
#isButton: true |
|
609 |
#value: #doStepOut |
|
610 |
#activeHelpKey: #editMoveOut |
|
611 |
#enabled: #canStepOutChannel |
|
882 | 612 |
#labelImage: #(#ResourceRetriever #Icon #leftDownIcon) |
506 | 613 |
) |
614 |
) nil |
|
615 |
nil |
|
616 |
) |
|
617 |
! ! |
|
618 |
||
300 | 619 |
!HierarchicalListEditor class methodsFor:'printing'! |
620 |
||
621 |
prettyPrintArray:anArray on:aStream indent:anIndent |
|
622 |
"print a literal array in a nice format |
|
623 |
" |
|
624 |
|arg sol| |
|
625 |
||
626 |
sol := aStream position. |
|
627 |
aStream spaces:anIndent. |
|
628 |
aStream nextPutAll:'#('. |
|
629 |
||
630 |
anArray first isSymbol ifTrue:[ |
|
631 |
arg := anArray first. |
|
632 |
aStream nextPut:$#. |
|
633 |
aStream nextPutAll:anArray first. |
|
634 |
aStream cr. |
|
635 |
anArray size == 2 ifTrue:[ |
|
636 |
self prettyPrintArray:(anArray last) |
|
637 |
on:aStream |
|
638 |
indent:(anIndent + 4). |
|
639 |
]. |
|
640 |
aStream spaces:anIndent. |
|
641 |
aStream nextPut:$). |
|
642 |
^ self |
|
643 |
]. |
|
644 |
||
645 |
aStream nextPut:$'. |
|
646 |
aStream nextPutAll:(anArray at:1). |
|
647 |
aStream nextPut:$'. |
|
648 |
arg := anArray at:2 ifAbsent:nil. |
|
649 |
||
650 |
arg isString ifTrue:[ |
|
651 |
aStream spaces:((50 - (aStream position - sol)) max:4). |
|
652 |
||
653 |
arg isSymbol ifTrue:[ |
|
654 |
aStream nextPut:$#. |
|
655 |
]. |
|
656 |
aStream nextPut:$'. |
|
657 |
aStream nextPutAll:arg. |
|
658 |
aStream nextPut:$'. |
|
659 |
arg := anArray at:3 ifAbsent:nil. |
|
660 |
]. |
|
661 |
arg isArray ifTrue:[ |
|
662 |
aStream nextPutAll:' #('. |
|
663 |
aStream cr. |
|
664 |
arg do:[:e|self prettyPrintArray:e on:aStream indent:(anIndent + 4)]. |
|
665 |
aStream spaces:anIndent. |
|
666 |
aStream nextPut:$). |
|
667 |
]. |
|
668 |
aStream nextPut:$). |
|
669 |
aStream cr. |
|
670 |
! ! |
|
671 |
||
672 |
!HierarchicalListEditor methodsFor:'aspects'! |
|
673 |
||
674 |
canCreateChildChannel |
|
675 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
676 |
^builder booleanValueAspectFor:#canCreateChildChannel |
300 | 677 |
|
678 |
! |
|
679 |
||
680 |
canCreateSisterChannel |
|
681 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
682 |
^builder booleanValueAspectFor:#canCreateSisterChannel |
300 | 683 |
|
684 |
! |
|
685 |
||
686 |
canStepInChannel |
|
687 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
688 |
^builder booleanValueAspectFor:#canStepInChannel |
300 | 689 |
|
690 |
! |
|
691 |
||
692 |
canStepOutChannel |
|
693 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
694 |
^builder booleanValueAspectFor:#canStepOutChannel |
300 | 695 |
|
696 |
! |
|
697 |
||
698 |
canStepOverChannel |
|
699 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
700 |
^builder booleanValueAspectFor:#canStepOverChannel |
300 | 701 |
|
702 |
! |
|
703 |
||
704 |
itemName |
|
705 |
||
706 |
|holder| |
|
707 |
||
708 |
(holder := builder bindingAt:#itemName) isNil ifTrue:[ |
|
709 |
builder aspectAt:#itemName put:(holder := ValueHolder new). |
|
710 |
holder addDependent:self. |
|
711 |
]. |
|
712 |
^ holder |
|
713 |
! |
|
714 |
||
715 |
itemValue |
|
716 |
||
717 |
|holder| |
|
718 |
||
719 |
(holder := builder bindingAt:#itemValue) isNil ifTrue:[ |
|
720 |
builder aspectAt:#itemValue put:(holder := ValueHolder new). |
|
721 |
holder addDependent:self. |
|
722 |
]. |
|
723 |
^ holder |
|
724 |
! |
|
725 |
||
726 |
treeView |
|
727 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
728 |
^treeView |
300 | 729 |
! ! |
730 |
||
731 | 731 |
!HierarchicalListEditor methodsFor:'building'! |
732 |
||
733 |
buildFromClass:aClass andSelector:aSelector |
|
734 |
"rebuild window from a class and selector" |
|
735 |
||
736 |
|cls sel anchor| |
|
300 | 737 |
|
731 | 738 |
cls := self resolveName:aClass. |
739 |
specSelector := nil. |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
740 |
|
731 | 741 |
aSelector size ~~ 0 |
742 |
ifTrue: |
|
743 |
[ |
|
744 |
sel := aSelector asString withoutSeparators. |
|
745 |
sel size ~~ 0 ifTrue:[specSelector := sel asSymbol] |
|
746 |
]. |
|
747 |
treeView selection:nil. |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
748 |
|
731 | 749 |
(specSelector notNil and:[cls notNil]) |
750 |
ifTrue: |
|
751 |
[ |
|
752 |
(cls respondsTo:specSelector) |
|
753 |
ifTrue: |
|
754 |
[ |
|
755 |
anchor := cls perform:specSelector. |
|
756 |
anchor isArray ifTrue:[anchor := anchor decodeAsLiteralArray] |
|
757 |
]. |
|
758 |
]. |
|
759 |
anchor notNil |
|
760 |
ifTrue: [anchor expand. treeView root:anchor] |
|
761 |
ifFalse: [treeView root isNil ifTrue: [self buildRoot]]. |
|
581 | 762 |
|
731 | 763 |
treeView selection: 1. |
581 | 764 |
|
731 | 765 |
self updateHistory. |
766 |
self updateInfoLabel. |
|
767 |
||
768 |
||
769 |
||
770 |
! |
|
771 |
||
736 | 772 |
buildFromResourceSpec: aListSpec |
581 | 773 |
|
731 | 774 |
treeView root: aListSpec |
775 |
||
776 |
! |
|
777 |
||
778 |
buildRoot |
|
779 |
"build just a root" |
|
780 |
||
781 |
treeView root:(TreeItem name:'Root' contents:#Anchor). |
|
782 |
treeView selection:1. |
|
581 | 783 |
! ! |
784 |
||
1575 | 785 |
!HierarchicalListEditor methodsFor:'menu accessing'! |
786 |
||
787 |
menu |
|
788 |
^ self class menu |
|
789 |
! |
|
790 |
||
791 |
menuEdit |
|
792 |
^ self class menuEdit |
|
793 |
! |
|
794 |
||
795 |
menuToolbar |
|
796 |
^ self class menuToolbar |
|
797 |
! ! |
|
798 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
799 |
!HierarchicalListEditor methodsFor:'private'! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
800 |
|
731 | 801 |
getDepthAndSistersNumberOfNode: aNode onParentNode: aParentNode |
802 |
"return depth of selected node" |
|
803 |
||
804 |
|parent childNode depthAndSistersNumbers str| |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
805 |
|
731 | 806 |
depthAndSistersNumbers := OrderedCollection new. |
807 |
childNode := aNode. |
|
808 |
parent := aParentNode. |
|
809 |
[parent notNil] |
|
810 |
whileTrue: |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
811 |
[ |
731 | 812 |
depthAndSistersNumbers add: (parent children indexOf: childNode). |
813 |
childNode := parent. |
|
814 |
parent := parent parent. |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
815 |
]. |
731 | 816 |
depthAndSistersNumbers removeFirst; addFirst: aParentNode children size. |
817 |
str := ''. |
|
818 |
depthAndSistersNumbers reverseDo: [:n| str := str, n printString, '.']. |
|
819 |
^str copyFrom: 1 to: str size - 1 |
|
506 | 820 |
! |
821 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
822 |
newItem |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
823 |
"creates and returns a new default item" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
824 |
|
558 | 825 |
^TreeItem name: 'Item' contents: nil |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
826 |
! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
827 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
828 |
updateChannels |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
829 |
"update channels" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
830 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
831 |
|node parent chnStepIn chnStepOut chnStepOvr chnChild chnSister| |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
832 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
833 |
chnStepIn := chnStepOut := chnStepOvr := chnChild := chnSister := false. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
834 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
835 |
(node := treeView selectedNode) notNil |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
836 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
837 |
[ |
731 | 838 |
(builder componentAt: #SpecView) beVisible. |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
839 |
chnChild := true. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
840 |
(parent := node parent) notNil |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
841 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
842 |
[ |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
843 |
chnSister := true. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
844 |
chnStepOvr := parent numberOfChildren > 1. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
845 |
chnStepOut := parent parent notNil. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
846 |
chnStepIn := node ~~ parent lastChild |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
847 |
] |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
848 |
] |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
849 |
ifFalse: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
850 |
[ |
731 | 851 |
(builder componentAt: #SpecView) beInvisible |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
852 |
]. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
853 |
self canCreateChildChannel value:chnChild. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
854 |
self canCreateSisterChannel value:chnSister. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
855 |
self canStepOverChannel value:chnStepOvr. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
856 |
self canStepOutChannel value:chnStepOut. |
506 | 857 |
self canStepInChannel value:chnStepIn. |
858 |
||
731 | 859 |
self valueOfCanCut value: (treeView selection notNil |
860 |
ifTrue:[(treeView isInSelection:1) not] |
|
861 |
ifFalse: [false]). |
|
506 | 862 |
|
731 | 863 |
self valueOfCanCopy value: self valueOfCanCut value. |
864 |
||
736 | 865 |
self valueOfCanPaste value: treeView selectedNode notNil & self valueOfCanPaste value. |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
866 |
! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
867 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
868 |
updateInputFields |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
869 |
"reload item value into input fields" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
870 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
871 |
|node| |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
872 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
873 |
(node := treeView selectedNode) notNil |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
874 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
875 |
[ |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
876 |
self itemName value:node name. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
877 |
self itemValue value:node contents |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
878 |
] |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
879 |
ifFalse: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
880 |
[ |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
881 |
self itemName value:''. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
882 |
self itemValue value:nil |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
883 |
]. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
884 |
self valueOfEnablingCommitButtons value: false |
300 | 885 |
! ! |
886 |
||
3306 | 887 |
!HierarchicalListEditor methodsFor:'startup & release'! |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
888 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
889 |
initialize |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
890 |
"setup default values" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
891 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
892 |
super initialize. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
893 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
894 |
treeView := SelectionInTreeView new. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
895 |
treeView multipleSelectOk: true. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
896 |
treeView showDirectoryIndicator: true. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
897 |
treeView showDirectoryIndicatorForRoot: false. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
898 |
treeView action:[:aNr| self updateChannels. self updateInputFields]. |
731 | 899 |
treeView selectConditionBlock: [:i|self askForItemModification]. |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
900 |
treeView validateDoubleClickBlock: [:node| node ~~ treeView model list first]. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
901 |
! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
902 |
|
731 | 903 |
openModalOnTreeItem: aTreeItem |
904 |
"build a tree from aTreeItem and open it modal" |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
905 |
|
736 | 906 |
super openModalOnResourceSpec: aTreeItem |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
907 |
! ! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
908 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
909 |
!HierarchicalListEditor methodsFor:'user actions'! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
910 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
911 |
accept |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
912 |
"invoked by button 'OK'" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
913 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
914 |
|node index| |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
915 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
916 |
(index := treeView selectedIndex) ~~ 0 |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
917 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
918 |
[ |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
919 |
node := treeView nodeAtIndex:index. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
920 |
node name: self itemName value. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
921 |
node contents: self itemValue value. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
922 |
treeView redrawLine:index. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
923 |
]. |
731 | 924 |
modified := true. |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
925 |
self valueOfEnablingCommitButtons value: false |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
926 |
! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
927 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
928 |
cancel |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
929 |
"invoked by button 'Cancel'" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
930 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
931 |
self updateInputFields. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
932 |
|
731 | 933 |
modified := false. |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
934 |
self valueOfEnablingCommitButtons value: false |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
935 |
! |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
936 |
|
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
937 |
doCopy |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
938 |
"copy current selected nodes into copy buffer" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
939 |
|
731 | 940 |
self class clipboard: OrderedCollection new. |
736 | 941 |
treeView selectedNodesDo:[:aNode| self class clipboard add: aNode copy]. |
747 | 942 |
self updateAllToolInstances |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
943 |
! |
300 | 944 |
|
945 |
doCreateChild |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
946 |
"create a child within selected parent" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
947 |
|
558 | 948 |
|node newItem| |
300 | 949 |
|
731 | 950 |
((node := treeView selectedNode) notNil and: [self askForItemModification]) |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
951 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
952 |
[ |
558 | 953 |
treeView model add: (newItem := self newItem) afterIndex: node children size below:node. |
954 |
newItem name: 'Child ', (self getDepthAndSistersNumberOfNode: newItem onParentNode: node). |
|
300 | 955 |
treeView selectedNodeExpand:true. |
558 | 956 |
treeView selectNode: newItem. |
300 | 957 |
self updateChannels. |
731 | 958 |
modified := true |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
959 |
] |
300 | 960 |
! |
961 |
||
962 |
doCreateSister |
|
963 |
"create a sister next to selected item |
|
964 |
" |
|
558 | 965 |
|node newItem| |
300 | 966 |
|
731 | 967 |
((node := treeView selectedNode) notNil and: [self askForItemModification]) |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
968 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
969 |
[ |
558 | 970 |
newItem := self newItem. |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
971 |
node parent notNil |
562 | 972 |
ifTrue: [treeView model add: newItem after:node] |
558 | 973 |
ifFalse:[treeView model add: newItem beforeIndex:1 below:node]. |
562 | 974 |
|
558 | 975 |
newItem name: 'Child ', (self getDepthAndSistersNumberOfNode: newItem onParentNode: node parent). |
976 |
treeView selectNode: newItem. |
|
506 | 977 |
self updateChannels. |
731 | 978 |
modified := true |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
979 |
] |
300 | 980 |
! |
981 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
982 |
doCut |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
983 |
"cut current selected nodes" |
300 | 984 |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
985 |
|selection| |
731 | 986 |
(treeView hasSelection and: [self askForItemModification]) |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
987 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
988 |
[ |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
989 |
self doCopy. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
990 |
selection := treeView selection asSortedCollection. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
991 |
treeView selectedNodesRemove. |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
992 |
treeView selection: selection first - 1. |
747 | 993 |
self updateAllToolInstances. |
731 | 994 |
modified := true |
995 |
] |
|
996 |
! |
|
997 |
||
998 |
doDelete |
|
999 |
"delete current selected nodes" |
|
1000 |
||
1001 |
|selection| |
|
1002 |
(treeView hasSelection and: [self askForItemModification]) |
|
1003 |
ifTrue: |
|
1004 |
[ |
|
1005 |
selection := treeView selection asSortedCollection. |
|
1006 |
treeView selectedNodesRemove. |
|
1007 |
treeView selection: selection first - 1. |
|
1008 |
self updateChannels. |
|
1009 |
modified := true |
|
300 | 1010 |
] |
1011 |
! |
|
1012 |
||
731 | 1013 |
doNew |
736 | 1014 |
"first do super new; then make a build |
1015 |
of a resource spec containing a root" |
|
300 | 1016 |
|
736 | 1017 |
super doNew ifTrue: [self buildRoot] |
300 | 1018 |
|
731 | 1019 |
|
1020 |
||
300 | 1021 |
! |
1022 |
||
731 | 1023 |
doPaste |
1024 |
"paste after current selected item" |
|
1025 |
||
736 | 1026 |
(self askForItemModification and: [self class clipboard notNil]) |
731 | 1027 |
ifTrue: |
1028 |
[ |
|
1029 |
|copiedNode| |
|
1030 |
self class clipboard do: |
|
1031 |
[:node| |
|
1032 |
copiedNode := node copy. |
|
1033 |
treeView selectedNodeAdd: copiedNode. |
|
1034 |
treeView selectNode: copiedNode. |
|
1035 |
]. |
|
1036 |
self updateChannels. |
|
1037 |
modified := true |
|
1038 |
] |
|
1039 |
! |
|
1040 |
||
1041 |
doReload |
|
1042 |
"reload spec from current class and selector" |
|
1043 |
||
1044 |
self buildFrom:specClass andSelector:specSelector |
|
1045 |
||
1046 |
! |
|
1047 |
||
1048 |
doSave |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1049 |
"install code" |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1050 |
|
731 | 1051 |
|cls code spec category mthd stream| |
300 | 1052 |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1053 |
(specClass notNil and:[specSelector notNil]) |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1054 |
ifFalse: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1055 |
[ |
731 | 1056 |
^self doSaveAs |
300 | 1057 |
]. |
1058 |
||
731 | 1059 |
cls := self resolveName: specClass. |
300 | 1060 |
spec := (treeView nodeAtIndex:1) literalArrayEncoding. |
1061 |
stream := WriteStream on:String new. |
|
1062 |
self class prettyPrintArray:spec on:stream indent:4. |
|
1063 |
spec := stream contents. |
|
731 | 1064 |
category := 'list specs'. |
300 | 1065 |
|
731 | 1066 |
(mthd := cls class compiledMethodAt:specSelector) notNil |
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1067 |
ifTrue: |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1068 |
[ |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1069 |
category := mthd category |
300 | 1070 |
]. |
1071 |
||
1072 |
code := Character excla asString |
|
731 | 1073 |
, cls name , ' class methodsFor:' , category storeString |
300 | 1074 |
, Character excla asString , '\\' |
1075 |
||
1076 |
, specSelector , '\' |
|
736 | 1077 |
, (self class codeGenerationComment replChar:$!! withString:'!!!!') |
1078 |
, '\\ "\' |
|
731 | 1079 |
, ' HierarchicalListEditor openOnClass:' , cls name , ' andSelector:#' , specSelector , '\' |
300 | 1080 |
, ' "\'. |
1081 |
||
1082 |
code := code |
|
1083 |
, '\' |
|
1084 |
, ' <resource: #hierarchicalList>\\' |
|
1085 |
, ' ^\' |
|
1086 |
, spec |
|
1087 |
, ' decodeAsLiteralArray\' |
|
1088 |
, Character excla asString |
|
1089 |
, ' ' |
|
1090 |
, Character excla asString |
|
1091 |
, '\\'. |
|
1092 |
||
1093 |
code := code withCRs. |
|
1094 |
(ReadStream on:code) fileIn. |
|
1095 |
||
731 | 1096 |
self updateHistory. |
1097 |
hasSaved := true. |
|
1098 |
modified := false. |
|
300 | 1099 |
! |
1100 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1101 |
doStepDown |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1102 |
"move selected item after next item" |
300 | 1103 |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1104 |
treeView selectedNodeChangeSequenceOrder:1. |
506 | 1105 |
self updateChannels. |
731 | 1106 |
modified := true |
506 | 1107 |
|
300 | 1108 |
! |
1109 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1110 |
doStepIn |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1111 |
"lets become the selected item a child of its next sister" |
300 | 1112 |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1113 |
treeView selectedNodeBecomeChildOfNext. |
506 | 1114 |
self updateChannels. |
731 | 1115 |
modified := true |
506 | 1116 |
|
1117 |
||
1118 |
||
300 | 1119 |
! |
1120 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1121 |
doStepOut |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1122 |
"let selected node become a sister of its current parent" |
300 | 1123 |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1124 |
treeView selectedNodeBecomeSisterOfParent. |
506 | 1125 |
self updateChannels. |
731 | 1126 |
modified := true |
506 | 1127 |
|
1128 |
||
1129 |
||
300 | 1130 |
! |
1131 |
||
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1132 |
doStepUp |
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1133 |
"move selected item before previous item" |
300 | 1134 |
|
423
ea6880a0e024
totally revised version; create icons will be changed next days
tz
parents:
372
diff
changeset
|
1135 |
treeView selectedNodeChangeSequenceOrder:-1. |
506 | 1136 |
self updateChannels. |
731 | 1137 |
modified := true |
506 | 1138 |
|
1139 |
||
1140 |
||
1856 | 1141 |
! |
1142 |
||
1143 |
openDocumentation |
|
1144 |
self openHTMLDocument:'tools/uipainter/HierarchicalListEditor.html'. |
|
300 | 1145 |
! ! |
1146 |
||
1147 |
!HierarchicalListEditor class methodsFor:'documentation'! |
|
1148 |
||
1149 |
version |
|
1150 |
^ '$Header$' |
|
1151 |
! ! |
|
3306 | 1152 |