author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Thu, 09 Feb 2017 09:56:47 +0000 | |
branch | jv |
changeset 17459 | 9f54cb54204c |
parent 16773 | a524b01249c1 |
child 18226 | 346376844040 |
permissions | -rw-r--r-- |
5591 | 1 |
" |
2 |
COPYRIGHT (c) 2000 by eXept Software AG |
|
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 |
" |
|
5592 | 12 |
"{ Package: 'stx:libtool' }" |
5591 | 13 |
|
14 |
"{ NameSpace: Tools }" |
|
15 |
||
16 |
BrowserList subclass:#VariableList |
|
16537 | 17 |
instanceVariableNames:'classHolder groupVariablesByInheritance selectedVariableEntries |
18 |
showClassVars showWarningAboutMissingEntryInXmlSpec |
|
19 |
sortVariablesByName variableList' |
|
5591 | 20 |
classVariableNames:'' |
21 |
poolDictionaries:'' |
|
22 |
category:'Interface-Browsers-New' |
|
23 |
! |
|
24 |
||
10255 | 25 |
Object subclass:#VariableEntry |
15455 | 26 |
instanceVariableNames:'label application class name type icon sortingByNameHolder |
16537 | 27 |
classShown groupByInheritanceHolder' |
10255 | 28 |
classVariableNames:'' |
29 |
poolDictionaries:'' |
|
30 |
privateIn:VariableList |
|
31 |
! |
|
32 |
||
5591 | 33 |
!VariableList class methodsFor:'documentation'! |
34 |
||
35 |
copyright |
|
36 |
" |
|
37 |
COPYRIGHT (c) 2000 by eXept Software AG |
|
38 |
All Rights Reserved |
|
39 |
||
40 |
This software is furnished under a license and may be used |
|
41 |
only in accordance with the terms of that license and with the |
|
42 |
inclusion of the above copyright notice. This software may not |
|
43 |
be provided or otherwise made available to, or used by, any |
|
44 |
other person. No title to or ownership of the software is |
|
45 |
hereby transferred. |
|
46 |
" |
|
11878 | 47 |
! |
48 |
||
49 |
documentation |
|
50 |
" |
|
51 |
I implement the variable list (below class list) in the new system browser |
|
52 |
" |
|
5591 | 53 |
! ! |
54 |
||
55 |
!VariableList class methodsFor:'interface specs'! |
|
56 |
||
57 |
windowSpec |
|
58 |
"This resource specification was automatically generated |
|
59 |
by the UIPainter of ST/X." |
|
60 |
||
61 |
"Do not manually edit this!! If it is corrupted, |
|
62 |
the UIPainter may not be able to read the specification." |
|
63 |
||
64 |
" |
|
10287 | 65 |
UIPainter new openOnClass:Tools::VariableList andSelector:#windowSpec |
66 |
Tools::VariableList new openInterface:#windowSpec |
|
67 |
Tools::VariableList open |
|
5591 | 68 |
" |
69 |
||
70 |
<resource: #canvas> |
|
71 |
||
72 |
^ |
|
10287 | 73 |
#(FullSpec |
74 |
name: windowSpec |
|
75 |
window: |
|
76 |
(WindowSpec |
|
77 |
label: 'VariableList' |
|
78 |
name: 'VariableList' |
|
79 |
min: (Point 0 0) |
|
80 |
bounds: (Rectangle 0 0 300 300) |
|
9461 | 81 |
) |
10287 | 82 |
component: |
83 |
(SpecCollection |
|
84 |
collection: ( |
|
85 |
(SequenceViewSpec |
|
86 |
name: 'List' |
|
87 |
layout: (LayoutFrame 0 0.0 0 0.0 0 1.0 0 1.0) |
|
88 |
tabable: true |
|
89 |
model: selectedVariableEntries |
|
90 |
menu: menuHolder |
|
91 |
hasHorizontalScrollBar: true |
|
92 |
hasVerticalScrollBar: true |
|
93 |
miniScrollerHorizontal: true |
|
94 |
isMultiSelect: true |
|
95 |
valueChangeSelector: selectionChangedByClick |
|
96 |
useIndex: false |
|
97 |
sequenceList: variableList |
|
98 |
doubleClickChannel: doubleClickChannel |
|
9461 | 99 |
) |
100 |
) |
|
5591 | 101 |
|
9461 | 102 |
) |
5591 | 103 |
) |
104 |
! ! |
|
105 |
||
106 |
!VariableList class methodsFor:'plugIn spec'! |
|
107 |
||
108 |
aspectSelectors |
|
109 |
"This resource specification was automatically generated |
|
110 |
by the UIPainter of ST/X." |
|
111 |
||
112 |
"Do not manually edit this. If it is corrupted, |
|
113 |
the UIPainter may not be able to read the specification." |
|
114 |
||
115 |
"Return a description of exported aspects; |
|
116 |
these can be connected to aspects of an embedding application |
|
117 |
(if this app is embedded in a subCanvas)." |
|
118 |
||
119 |
^ #( |
|
14021
ff0b42e2c251
Refactoring of NavigatorModel's environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13827
diff
changeset
|
120 |
environmentHolder |
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
121 |
#(#doubleClickChannel #action ) |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
122 |
#classHolder |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
123 |
#forceGeneratorTrigger |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
124 |
#immediateUpdate |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
125 |
#inGeneratorHolder |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
126 |
#menuHolder |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
127 |
#outGeneratorHolder |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
128 |
#packageFilter |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
129 |
#selectedVariables |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
130 |
#selectionChangeCondition |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
131 |
#updateTrigger |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
132 |
#showClassVarsInVariableList |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
133 |
#slaveMode |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
134 |
#sortVariablesByName |
16537 | 135 |
#groupVariablesByInheritance |
5591 | 136 |
). |
14021
ff0b42e2c251
Refactoring of NavigatorModel's environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13827
diff
changeset
|
137 |
|
ff0b42e2c251
Refactoring of NavigatorModel's environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13827
diff
changeset
|
138 |
"Modified: / 24-02-2014 / 10:37:14 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
5591 | 139 |
! ! |
140 |
||
141 |
!VariableList methodsFor:'aspects'! |
|
142 |
||
143 |
classHolder |
|
144 |
classHolder isNil ifTrue:[ |
|
145 |
classHolder := #() asValue. |
|
146 |
classHolder addDependent:self |
|
147 |
]. |
|
148 |
^ classHolder |
|
149 |
! |
|
150 |
||
151 |
classHolder:aValueHolder |
|
152 |
classHolder notNil ifTrue:[ |
|
10308 | 153 |
classHolder removeDependent:self |
5591 | 154 |
]. |
155 |
classHolder := aValueHolder. |
|
156 |
classHolder notNil ifTrue:[ |
|
10308 | 157 |
classHolder isBehavior ifTrue:[self error:'should not happen']. |
158 |
classHolder addDependent:self |
|
5591 | 159 |
]. |
10308 | 160 |
|
161 |
"Modified: / 11-07-2011 / 17:04:19 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5591 | 162 |
! |
163 |
||
164 |
defaultSlaveModeValue |
|
165 |
^ false. |
|
166 |
! |
|
167 |
||
16537 | 168 |
groupVariablesByInheritance |
169 |
"/ groupVariablesByInheritance and sortVariablesByName form a 3-state value |
|
170 |
"/ groupVariablesByInheritance sortVariablesByName |
|
171 |
"/ T T - sort within each defining class |
|
172 |
"/ T F - by inst-order grouped by defining class |
|
173 |
"/ F T - show all of them in one big sorted list |
|
174 |
"/ F F - useless - show all of them by inst-order |
|
175 |
groupVariablesByInheritance isNil ifTrue:[ |
|
176 |
groupVariablesByInheritance := true asValue. |
|
177 |
groupVariablesByInheritance addDependent:self |
|
178 |
]. |
|
179 |
^ groupVariablesByInheritance |
|
180 |
! |
|
181 |
||
182 |
groupVariablesByInheritance:aValueHolder |
|
183 |
"/ self assert:(aValueHolder value isBoolean). |
|
184 |
||
185 |
groupVariablesByInheritance notNil ifTrue:[ |
|
186 |
groupVariablesByInheritance removeDependent:self |
|
187 |
]. |
|
188 |
groupVariablesByInheritance := aValueHolder. |
|
189 |
groupVariablesByInheritance notNil ifTrue:[ |
|
190 |
groupVariablesByInheritance addDependent:self |
|
191 |
]. |
|
192 |
! |
|
193 |
||
10255 | 194 |
selectedVariableEntries |
195 |
<resource: #uiAspect> |
|
196 |
||
197 |
"automatically generated by UIPainter ..." |
|
198 |
||
199 |
selectedVariableEntries isNil ifTrue:[ |
|
200 |
selectedVariableEntries := #() asValue. |
|
16192 | 201 |
selectedVariableEntries addDependent:self. |
10255 | 202 |
]. |
203 |
^ selectedVariableEntries. |
|
204 |
||
205 |
"Modified: / 12-04-2011 / 15:49:31 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
206 |
! |
|
207 |
||
5591 | 208 |
selectedVariables |
209 |
^ self selectionHolder |
|
210 |
||
211 |
! |
|
212 |
||
213 |
selectedVariables:aValueHolder |
|
214 |
^ self selectionHolder:aValueHolder |
|
215 |
||
216 |
! |
|
217 |
||
218 |
showClassVarsInVariableList |
|
219 |
showClassVars isNil ifTrue:[ |
|
220 |
showClassVars := false asValue. |
|
221 |
showClassVars addDependent:self |
|
222 |
]. |
|
223 |
^ showClassVars |
|
224 |
! |
|
225 |
||
226 |
showClassVarsInVariableList:aValueHolder |
|
227 |
showClassVars notNil ifTrue:[ |
|
228 |
showClassVars removeDependent:self |
|
229 |
]. |
|
230 |
showClassVars := aValueHolder. |
|
231 |
showClassVars notNil ifTrue:[ |
|
232 |
showClassVars addDependent:self |
|
233 |
]. |
|
234 |
! |
|
235 |
||
236 |
showingInheritedClassVars |
|
237 |
^ false |
|
238 |
"/ ^ true |
|
239 |
! |
|
240 |
||
241 |
sortVariablesByName |
|
16537 | 242 |
"/ groupVariablesByInheritance and sortVariablesByName form a 3-state value |
243 |
"/ groupVariablesByInheritance sortVariablesByName |
|
244 |
"/ T T - sort within each defining class |
|
245 |
"/ T F - by inst-order grouped by defining class |
|
246 |
"/ F T - show all of them in one big sorted list |
|
247 |
"/ F F - useless - show all of them by inst-order |
|
5591 | 248 |
sortVariablesByName isNil ifTrue:[ |
16537 | 249 |
sortVariablesByName := false asValue. |
250 |
sortVariablesByName addDependent:self |
|
5591 | 251 |
]. |
252 |
^ sortVariablesByName |
|
253 |
! |
|
254 |
||
255 |
sortVariablesByName:aValueHolder |
|
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
256 |
"/ self assert:(aValueHolder value isBoolean). |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
257 |
|
5591 | 258 |
sortVariablesByName notNil ifTrue:[ |
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
259 |
sortVariablesByName removeDependent:self |
5591 | 260 |
]. |
261 |
sortVariablesByName := aValueHolder. |
|
262 |
sortVariablesByName notNil ifTrue:[ |
|
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
263 |
sortVariablesByName addDependent:self |
5591 | 264 |
]. |
265 |
! |
|
266 |
||
267 |
variableList |
|
268 |
variableList isNil ifTrue:[ |
|
269 |
variableList := ValueHolder new |
|
270 |
]. |
|
271 |
^ variableList |
|
272 |
||
273 |
||
274 |
! ! |
|
275 |
||
276 |
!VariableList methodsFor:'change & update'! |
|
277 |
||
278 |
delayedUpdate:something with:aParameter from:changedObject |
|
279 |
|selectedClasses changedClass anyChange| |
|
280 |
||
281 |
self inSlaveModeOrInvisible ifTrue:[self invalidateList. ^ self]. |
|
282 |
||
283 |
changedObject == slaveMode ifTrue:[ |
|
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
284 |
listValid ~~ true ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
285 |
self enqueueDelayedUpdateList |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
286 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
287 |
"/ self invalidateList. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
288 |
^ self |
5591 | 289 |
]. |
290 |
||
291 |
changedObject == classHolder ifTrue:[ |
|
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
292 |
self invalidateList. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
293 |
^ self |
5591 | 294 |
]. |
295 |
changedObject == showClassVars ifTrue:[ |
|
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
296 |
self invalidateList. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
297 |
^ self. |
5591 | 298 |
]. |
299 |
changedObject == sortVariablesByName ifTrue:[ |
|
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
300 |
self invalidateList. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
301 |
^ self. |
5591 | 302 |
]. |
16537 | 303 |
changedObject == groupVariablesByInheritance ifTrue:[ |
304 |
self invalidateList. |
|
305 |
^ self. |
|
306 |
]. |
|
13498
b8d845e42988
Added `environment` instance variable to Tools__NewSystemBrowser and
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13458
diff
changeset
|
307 |
changedObject == environment ifTrue:[ |
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
308 |
(something == #projectOrganization) ifTrue:[^ self]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
309 |
(something == #currentChangeSet) ifTrue:[^ self]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
310 |
(something == #aboutToAutoloadClass) ifTrue:[^ self]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
311 |
|
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
312 |
(something == #classDefinition |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
313 |
or:[ (something == #newClass) |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
314 |
or:[ something == #classVariables and:[showClassVars value == true]]]) |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
315 |
ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
316 |
changedClass := aParameter. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
317 |
selectedClasses := classHolder value. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
318 |
selectedClasses notNil ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
319 |
selectedClasses isSequenceable ifFalse:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
320 |
selectedClasses := selectedClasses asOrderedCollection |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
321 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
322 |
selectedClasses keysAndValuesDo:[:idx :cls | |nm| |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
323 |
cls notNil ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
324 |
cls isObsolete ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
325 |
cls isMeta ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
326 |
nm := cls theNonMetaclass name. |
13498
b8d845e42988
Added `environment` instance variable to Tools__NewSystemBrowser and
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13458
diff
changeset
|
327 |
selectedClasses at:idx put:(environment at:nm) class. |
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
328 |
] ifFalse:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
329 |
nm := cls name. |
13498
b8d845e42988
Added `environment` instance variable to Tools__NewSystemBrowser and
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13458
diff
changeset
|
330 |
selectedClasses at:idx put:(environment at:nm). |
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
331 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
332 |
anyChange := true. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
333 |
] ifFalse:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
334 |
(cls == aParameter |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
335 |
or:[something == #classVariables |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
336 |
and:[showClassVars value == true |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
337 |
and:[cls theNonMetaclass == aParameter theNonMetaclass]]]) ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
338 |
anyChange := true. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
339 |
] |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
340 |
] |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
341 |
] |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
342 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
343 |
(selectedClasses includes:nil) ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
344 |
"/ can happen, if a selected class is removed... |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
345 |
"/ self halt:'should this happen ?'. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
346 |
"/ fix it ... |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
347 |
selectedClasses := selectedClasses select:[:each | each notNil]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
348 |
classHolder value:selectedClasses. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
349 |
anyChange := true. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
350 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
351 |
anyChange == true ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
352 |
self invalidateList. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
353 |
^ self |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
354 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
355 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
356 |
^ self |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
357 |
]. |
5591 | 358 |
] ifFalse:[ |
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
359 |
changedObject isBehavior ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
360 |
anyChange := false. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
361 |
selectedClasses := classHolder value. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
362 |
selectedClasses notNil ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
363 |
selectedClasses keysAndValuesDo:[:idx :cls | |nm| |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
364 |
cls isObsolete ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
365 |
nm := cls name. |
13498
b8d845e42988
Added `environment` instance variable to Tools__NewSystemBrowser and
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13458
diff
changeset
|
366 |
selectedClasses at:idx put:(environment at:nm). |
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
367 |
anyChange := true. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
368 |
] |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
369 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
370 |
anyChange == true ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
371 |
self invalidateList. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
372 |
^ self |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
373 |
]. |
5591 | 374 |
|
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
375 |
(selectedClasses includesIdentical:something) ifTrue:[ |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
376 |
self invalidateList. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
377 |
^ self |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
378 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
379 |
]. |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
380 |
^ self |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
381 |
]. |
5591 | 382 |
]. |
383 |
super delayedUpdate:something with:aParameter from:changedObject |
|
11296
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
384 |
|
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
385 |
"Modified: / 01-03-2012 / 09:18:11 / cg" |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
386 |
! |
2fec94a88af2
added: #enqueueDelayedUpdateList
Claus Gittinger <cg@exept.de>
parents:
10974
diff
changeset
|
387 |
|
5591 | 388 |
makeDependent |
13498
b8d845e42988
Added `environment` instance variable to Tools__NewSystemBrowser and
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13458
diff
changeset
|
389 |
environment addDependent:self |
5591 | 390 |
|
391 |
! |
|
392 |
||
393 |
makeIndependent |
|
13498
b8d845e42988
Added `environment` instance variable to Tools__NewSystemBrowser and
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13458
diff
changeset
|
394 |
environment removeDependent:self |
5591 | 395 |
|
396 |
! |
|
397 |
||
398 |
selectionChangedByClick |
|
399 |
"we are not interested in that - get another notification |
|
400 |
via the changed valueHolder" |
|
401 |
||
402 |
||
403 |
! |
|
404 |
||
405 |
update:something with:aParameter from:changedObject |
|
406 |
"/ ^ self delayedUpdate:something with:aParameter from:changedObject. |
|
407 |
||
13498
b8d845e42988
Added `environment` instance variable to Tools__NewSystemBrowser and
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13458
diff
changeset
|
408 |
changedObject == environment ifTrue:[ |
10255 | 409 |
something == #methodDictionary ifTrue:[ |
410 |
^ self |
|
411 |
]. |
|
412 |
something == #methodTrap ifTrue:[ |
|
413 |
^ self |
|
414 |
]. |
|
10366 | 415 |
something == #methodCoverageInfo ifTrue:[ |
416 |
^ self |
|
417 |
]. |
|
10255 | 418 |
something == #methodInClass ifTrue:[ |
419 |
^ self |
|
420 |
]. |
|
421 |
something == #methodInClassRemoved ifTrue:[ |
|
422 |
^ self |
|
423 |
]. |
|
424 |
something == #classComment ifTrue:[ |
|
425 |
^ self. |
|
426 |
]. |
|
14293 | 427 |
something == #lastTestRunResult ifTrue:[ |
428 |
^ self |
|
429 |
]. |
|
430 |
something isNil ifTrue:[ |
|
431 |
^ self |
|
432 |
]. |
|
5591 | 433 |
]. |
434 |
"/ self window sensor isNil ifTrue:[ |
|
435 |
"/ "/ I am not visible ... |
|
436 |
"/ self invalidateList. |
|
437 |
"/ ^ self |
|
438 |
"/ ]. |
|
10255 | 439 |
changedObject == selectedVariableEntries ifTrue:[ |
440 |
self selectedVariables value: |
|
441 |
((selectedVariableEntries value ? #()) |
|
14144
9bcb9fef21b6
Access graphicsDevice via method send instead of instVar access
Stefan Vogel <sv@exept.de>
parents:
14114
diff
changeset
|
442 |
select:[:e| e isString not] "filter out class name header strings" |
9bcb9fef21b6
Access graphicsDevice via method send instead of instVar access
Stefan Vogel <sv@exept.de>
parents:
14114
diff
changeset
|
443 |
thenCollect:[:e|e name]). |
10255 | 444 |
^self. |
445 |
]. |
|
446 |
||
447 |
||
5591 | 448 |
super update:something with:aParameter from:changedObject |
449 |
||
10255 | 450 |
"Modified: / 12-04-2011 / 15:54:23 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10366 | 451 |
"Modified: / 20-07-2011 / 18:52:44 / cg" |
5591 | 452 |
! ! |
453 |
||
454 |
!VariableList methodsFor:'generators'! |
|
455 |
||
456 |
makeGenerator |
|
457 |
||
458 |
||
459 |
||
460 |
! ! |
|
461 |
||
462 |
!VariableList methodsFor:'private'! |
|
463 |
||
5909 | 464 |
commonPostBuild |
5591 | 465 |
|list| |
466 |
||
5909 | 467 |
super commonPostBuild. |
5591 | 468 |
|
5909 | 469 |
list := builder componentAt:#List. |
5591 | 470 |
list notNil ifTrue:[ |
5909 | 471 |
list selectConditionBlock:[:item | self selectionChangeAllowed:item]. |
472 |
list ignoreReselect:false. |
|
5591 | 473 |
]. |
474 |
! |
|
475 |
||
476 |
commonSubClassIn:classes |
|
477 |
"return true if there is a common subclass" |
|
478 |
||
479 |
|theCommonSubClass "classesByInheritance"| |
|
480 |
||
481 |
theCommonSubClass := nil. |
|
482 |
classes do:[:eachClass | |
|
483 |
theCommonSubClass isNil ifTrue:[ |
|
484 |
theCommonSubClass := eachClass |
|
485 |
] ifFalse:[ |
|
486 |
(eachClass isSubclassOf:theCommonSubClass) ifTrue:[ |
|
487 |
theCommonSubClass := eachClass |
|
488 |
] ifFalse:[ |
|
489 |
(theCommonSubClass isSubclassOf:eachClass) ifFalse:[ |
|
490 |
^ nil |
|
491 |
] |
|
492 |
] |
|
493 |
] |
|
494 |
]. |
|
495 |
^ theCommonSubClass. |
|
496 |
||
497 |
"/ classesByInheritance := classes topologicalSort:[:a :b | a isSubclassOf:b]. |
|
498 |
"/ classesByInheritance keysAndValuesDo:[:index :eachClass | |
|
499 |
"/ "/ all classes after that one must be superclasses ... |
|
500 |
"/ classesByInheritance from:index+1 to:classesByInheritance size do:[:otherClass | |
|
501 |
"/ (eachClass isSubclassOf:otherClass) ifFalse:[ |
|
502 |
"/ ^ nil. |
|
503 |
"/ ] |
|
504 |
"/ ]. |
|
505 |
"/ ]. |
|
506 |
"/ ^ classesByInheritance first |
|
507 |
! |
|
508 |
||
10324
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
509 |
iconInBrowserForVariable:varName in:aClass |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
510 |
"variables for which an entry is found in the xml-spec (if any) are marked |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
511 |
with an <xml>-icon." |
10255 | 512 |
|
10324
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
513 |
(Expecco::ExpeccoXMLDecoder notNil |
11586 | 514 |
and:[aClass canUnderstand: #xmlSpecForObject:]) ifTrue:[ |
10324
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
515 |
Error handle:[:ex | |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
516 |
] do:[ |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
517 |
(Expecco::ExpeccoXMLDecoder xmlSpecForObject:aClass basicNew) |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
518 |
do:[:spec | spec getter = varName ifTrue:[ |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
519 |
^ SystemBrowser instVarOverlayXmlSpec |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
520 |
] |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
521 |
]. |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
522 |
]. |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
523 |
]. |
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
524 |
^ nil |
10255 | 525 |
|
526 |
"Created: / 12-04-2011 / 19:58:08 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10324
d68f7aa2e449
I dont like extensions too much.
Claus Gittinger <cg@exept.de>
parents:
10308
diff
changeset
|
527 |
"Modified: / 15-07-2011 / 18:32:47 / cg" |
11586 | 528 |
"Modified: / 22-06-2012 / 13:17:28 / sr" |
10255 | 529 |
! |
530 |
||
531 |
listEntryForClass: cls name:name |
|
16537 | 532 |
^ self listEntryForClass: cls name:name info:nil |
10255 | 533 |
! |
534 |
||
16537 | 535 |
listEntryForClass: cls name:name info: classInfoOrNil |
536 |
| entry | |
|
10974 | 537 |
|
16537 | 538 |
entry := Tools::VariableList::VariableEntry application: self class: cls name: name. |
13382 | 539 |
entry sortingByNameHolder:sortVariablesByName. |
16537 | 540 |
entry groupByInheritanceHolder:groupVariablesByInheritance. |
541 |
classInfoOrNil notNil ifTrue:[ |
|
542 |
entry type: (classInfoOrNil infoForInstvarOrNil: name). |
|
10974 | 543 |
]. |
544 |
^entry |
|
545 |
||
546 |
"Created: / 27-11-2011 / 17:17:11 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
13827 | 547 |
"Modified: / 07-10-2013 / 08:28:32 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10974 | 548 |
! |
549 |
||
5591 | 550 |
listOfVariables |
10974 | 551 |
|
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
552 |
|nameList numClasses classes class commonSubclass showingClassVars |
16537 | 553 |
sortByName groupByInheritance classesAlreadyProcessed hasSmallSense smallSenseManager info | |
5591 | 554 |
|
555 |
classHolder isNil ifTrue:[ |
|
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
556 |
"/ testing |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
557 |
^ #() |
5591 | 558 |
]. |
559 |
||
13458
842c7f563bd5
class: Tools::VariableList
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13457
diff
changeset
|
560 |
hasSmallSense := (ConfigurableFeatures includesFeature:'SmallSenseEnabled') |
842c7f563bd5
class: Tools::VariableList
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13457
diff
changeset
|
561 |
and:[(Smalltalk at: #'SmallSense::Manager') notNil]. |
10974 | 562 |
hasSmallSense ifTrue:[ |
13457
630e14513fec
Fix for recent SmallSense (moved to its own namespace)
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
13382
diff
changeset
|
563 |
smallSenseManager := (Smalltalk at: #'SmallSense::Manager') instance. |
10974 | 564 |
]. |
565 |
||
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
566 |
showingClassVars := self showClassVarsInVariableList value == true. |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
567 |
sortByName := self sortVariablesByName value. |
16537 | 568 |
groupByInheritance := self groupVariablesByInheritance value. |
569 |
self assert:(sortByName isBoolean). |
|
570 |
self assert:(groupByInheritance isBoolean). |
|
5591 | 571 |
|
572 |
classes := classHolder value. |
|
573 |
(numClasses := classes size) == 0 ifTrue:[^ #() ]. |
|
574 |
numClasses > 1 ifTrue:[ |
|
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
575 |
"/ multiple classes - see if there is a common subclass ... |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
576 |
commonSubclass := self commonSubClassIn:classes. |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
577 |
commonSubclass notNil ifTrue:[ |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
578 |
"/ yes - treat like a single class |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
579 |
classes := Array with:(commonSubclass). |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
580 |
numClasses := 1. |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
581 |
]. |
13155 | 582 |
"/ commonSuperclass := Behavior commonSuperclassOf:classes. |
583 |
"/ commonSuperclass notNil ifTrue:[ |
|
584 |
"/ "/ yes - treat like a single class |
|
585 |
"/ classes := Array with:(commonSuperclass). |
|
586 |
"/ numClasses := 1. |
|
587 |
"/ ]. |
|
5591 | 588 |
]. |
589 |
||
590 |
numClasses > 1 ifTrue:[ |
|
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
591 |
"/ multiple classes - sort alphabetically ... |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
592 |
"/ unless there is a common subclass ... |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
593 |
nameList := Set new. |
10550 | 594 |
classesAlreadyProcessed := IdentitySet new. |
13155 | 595 |
classes do:[:eachClass | |
596 |
|class| |
|
597 |
||
598 |
class := eachClass. |
|
599 |
"/ showingClassVars ifTrue:[ |
|
600 |
"/ class := class theNonMetaclass |
|
601 |
"/ ]. |
|
602 |
||
10974 | 603 |
hasSmallSense ifTrue:[ |
604 |
info := smallSenseManager infoForClassOrNil: class. |
|
605 |
]. |
|
606 |
||
10550 | 607 |
(classesAlreadyProcessed includes:class) ifFalse:[ |
608 |
showingClassVars ifTrue:[ |
|
609 |
self showingInheritedClassVars ifTrue:[ |
|
610 |
class theNonMetaclass withAllSuperclassesDo:[:cls| |
|
10974 | 611 |
hasSmallSense ifTrue:[ |
612 |
info := smallSenseManager infoForClassOrNil: cls. |
|
613 |
]. |
|
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
614 |
|
10550 | 615 |
(classesAlreadyProcessed includes:cls) ifFalse:[ |
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
616 |
"/ Must check whether environment contains the class and filter it out, |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
617 |
"/ if not. Think of limited environment to Java classes which should not |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
618 |
"/ show Object & JavaObject even if they are real superclasses of any Java |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
619 |
"/ class. |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
620 |
"/ Q: Should we rather ignore all superclasses after first class which is not |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
621 |
"/ in environment? |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
622 |
|
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
623 |
(environment at: cls name ifAbsent:[nil]) notNil ifTrue:[ |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
624 |
nameList addAll: |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
625 |
(cls classVarNames collect:[:nm|self listEntryForClass: cls name: nm info: info]). |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
626 |
]. |
10550 | 627 |
classesAlreadyProcessed add:cls. |
628 |
] |
|
629 |
] |
|
630 |
] ifFalse:[ |
|
10255 | 631 |
nameList addAll: |
10974 | 632 |
(class classVarNames collect:[:nm|self listEntryForClass: class name: nm info: info ]) |
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
633 |
] |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
634 |
] ifFalse:[ |
10550 | 635 |
class withAllSuperclassesDo:[:cls| |
636 |
(classesAlreadyProcessed includes:cls) ifFalse:[ |
|
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
637 |
"/ Must check whether environment contains the class and filter it out, |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
638 |
"/ if not. Think of limited environment to Java classes which should not |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
639 |
"/ show Object & JavaObject even if they are real superclasses of any Java |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
640 |
"/ class. |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
641 |
"/ Q: Should we rather ignore all superclasses after first class which is not |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
642 |
"/ in environment? |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
643 |
|
14806
56a544a200ce
Fix Tools::VariableList>>listOfVariables - pass non-metaclass name when checking
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14612
diff
changeset
|
644 |
(environment at: cls theNonMetaclass name ifAbsent:[nil]) notNil ifTrue:[ |
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
645 |
nameList addAll: |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
646 |
(cls instVarNames collect:[:nm|self listEntryForClass: cls name: nm info: info ]). |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
647 |
]. |
10550 | 648 |
classesAlreadyProcessed add:cls. |
649 |
] |
|
650 |
] |
|
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
651 |
] |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
652 |
] |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
653 |
]. |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
654 |
nameList := nameList asOrderedCollection. |
5591 | 655 |
] ifFalse:[ |
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
656 |
"/ only a single class - sort by inheritance |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
657 |
class := classes first. |
5591 | 658 |
|
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
659 |
nameList := OrderedCollection new. |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
660 |
class notNil ifTrue:[ |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
661 |
showingClassVars ifTrue:[ |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
662 |
class := class theNonMetaclass |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
663 |
]. |
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
664 |
class withAllSuperclassesDo:[:cls| |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
665 |
"/ Must check whether environment contains the class and filter it out, |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
666 |
"/ if not. Think of limited environment to Java classes which should not |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
667 |
"/ show Object & JavaObject even if they are real superclasses of any Java |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
668 |
"/ class. |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
669 |
"/ Q: Should we rather ignore all superclasses after first class which is not |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
670 |
"/ in environment? |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
671 |
|
14335
6ad2d132a5af
class: Tools::VariableList
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14293
diff
changeset
|
672 |
(environment at: cls theNonMetaclass name ifAbsent:[nil]) notNil ifTrue:[ |
15455 | 673 |
|varNames classShown| |
5591 | 674 |
|
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
675 |
(hasSmallSense and:[showingClassVars not]) ifTrue:[ |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
676 |
info := smallSenseManager infoForClassOrNil: cls. |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
677 |
]. |
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
678 |
varNames := showingClassVars ifTrue:[ cls classVarNames ] ifFalse:[ cls instVarNames ]. |
15455 | 679 |
classShown := (cls ~~ class). "/ only append the class in the shown name, if the var is inherited |
16537 | 680 |
sortByName ifTrue:[ |
16707 | 681 |
varNames := varNames copy sort. |
16537 | 682 |
]. |
15537 | 683 |
varNames reversed do:[:varName| |
15455 | 684 |
|entry| |
685 |
nameList addFirst: (entry := self listEntryForClass: cls name: varName info: info). |
|
686 |
classShown ifFalse:[ entry classShown:classShown ]. |
|
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
687 |
]. |
16537 | 688 |
groupByInheritance ifTrue:[ |
16500 | 689 |
nameList addFirst:(("'----- ' , "cls nameInBrowser" , ' -----'") withColor: Color gray). |
14288
01c8bbd5b6dd
Fix in #listOfVariables - must check whether all superclasses are actually in environment.
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14144
diff
changeset
|
690 |
] |
6721
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
691 |
]. |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
692 |
]. |
c49f5a3cbca2
variableList (sort) fixed in hierarchy views
Claus Gittinger <cg@exept.de>
parents:
5909
diff
changeset
|
693 |
]. |
5591 | 694 |
]. |
695 |
||
16537 | 696 |
(numClasses > 1 or:[sortByName and:[groupByInheritance not]]) ifTrue:[ |
10255 | 697 |
nameList := nameList asSortedCollection:[:a :b|a name < b name]. |
5591 | 698 |
]. |
699 |
^ nameList |
|
700 |
||
10255 | 701 |
"Created: / 05-02-2000 / 13:42:11 / cg" |
10550 | 702 |
"Modified: / 08-08-2011 / 16:20:58 / cg" |
14806
56a544a200ce
Fix Tools::VariableList>>listOfVariables - pass non-metaclass name when checking
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
14612
diff
changeset
|
703 |
"Modified: / 28-10-2014 / 11:42:18 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
5591 | 704 |
! |
705 |
||
706 |
postBuildWith:aBuilder |
|
707 |
|listView| |
|
708 |
||
709 |
(listView := aBuilder componentAt:#List) notNil ifTrue:[ |
|
710 |
listView scrollWhenUpdating:#end |
|
711 |
]. |
|
712 |
super postBuildWith:aBuilder |
|
713 |
||
714 |
! |
|
715 |
||
716 |
release |
|
717 |
super release. |
|
718 |
||
719 |
classHolder removeDependent:self. |
|
720 |
showClassVars removeDependent:self. |
|
721 |
! |
|
722 |
||
723 |
selectionChangeAllowed:index |
|
10255 | 724 |
|
725 |
| entry | |
|
726 |
^((entry := variableList value at:index) isString" and:[entry startsWith:'---']") not. |
|
727 |
||
728 |
"Modified: / 28-04-2011 / 13:18:21 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5591 | 729 |
! |
730 |
||
731 |
updateList |
|
732 |
| prevSelection newSelection newList oldList selectedVariablesHolder| |
|
733 |
||
734 |
oldList := self variableList value copy. |
|
10255 | 735 |
showWarningAboutMissingEntryInXmlSpec := false. |
5591 | 736 |
newList := self listOfVariables. |
737 |
||
738 |
newList ~= variableList value ifTrue:[ |
|
10495 | 739 |
selectedVariablesHolder := self selectedVariableEntries. |
11360 | 740 |
prevSelection := (self selectedVariables value "selectedVariablesHolder value" copy) ? #(). |
10255 | 741 |
variableList value:newList. |
742 |
||
11360 | 743 |
newSelection := newList select:[:item | prevSelection includes:item string]. |
744 |
"/ newSelection := prevSelection select:[:item | newList includes:item]. |
|
5591 | 745 |
|
10255 | 746 |
newSelection size > 0 ifTrue:[ |
747 |
"/ force change (for dependents) |
|
11360 | 748 |
"/ selectedVariablesHolder value:nil. |
749 |
selectedVariablesHolder |
|
750 |
setValue:newSelection; |
|
11461 | 751 |
removeDependent:self; |
752 |
changed; |
|
753 |
addDependent:self. |
|
10255 | 754 |
] ifFalse:[ |
755 |
prevSelection := selectedVariablesHolder value. |
|
756 |
selectedVariablesHolder value:nil. |
|
757 |
]. |
|
11360 | 758 |
(prevSelection size > 0 or:[newSelection size > 0 |
759 |
"and:[ prevSelection ~= newSelection]"]) ifTrue:[ |
|
10255 | 760 |
self updateOutputGenerator. |
761 |
]. |
|
762 |
]. |
|
763 |
(showWarningAboutMissingEntryInXmlSpec and:[self topApplication respondsTo: #showMessage:]) |
|
764 |
ifTrue: |
|
765 |
[ |
|
766 |
self topApplication showMessage: |
|
767 |
'One or more instance variables are not listed in #xmlSpecFor:'. |
|
768 |
]. |
|
769 |
showWarningAboutMissingEntryInXmlSpec := false. |
|
14861
87aa6288286b
access listValid only via setter (for easier trapping)
Claus Gittinger <cg@exept.de>
parents:
14806
diff
changeset
|
770 |
self setListValid:true. |
10255 | 771 |
|
10495 | 772 |
"Modified: / 05-08-2011 / 12:34:47 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
11461 | 773 |
"Modified: / 23-03-2012 / 15:55:47 / cg" |
10255 | 774 |
! ! |
775 |
||
776 |
!VariableList::VariableEntry class methodsFor:'instance creation'! |
|
777 |
||
778 |
application: app class: aClass name: aString |
|
779 |
||
780 |
^self new application: app; class: aClass; name: aString |
|
781 |
||
782 |
"Created: / 12-04-2011 / 19:53:06 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
783 |
! |
|
784 |
||
785 |
class: aClass name: aString |
|
786 |
||
787 |
^self new class: aClass; name: aString |
|
788 |
||
789 |
"Created: / 12-04-2011 / 15:39:30 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
790 |
! ! |
|
791 |
||
792 |
!VariableList::VariableEntry methodsFor:'accessing'! |
|
793 |
||
794 |
application: anObject |
|
5591 | 795 |
|
10255 | 796 |
application := anObject |
797 |
||
798 |
"Created: / 12-04-2011 / 19:55:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
799 |
! |
|
800 |
||
10308 | 801 |
asString |
802 |
||
803 |
^self name |
|
804 |
||
805 |
"Created: / 11-07-2011 / 17:03:02 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
806 |
! |
|
807 |
||
10255 | 808 |
class:aClass |
809 |
class := aClass. |
|
810 |
! |
|
811 |
||
15455 | 812 |
classShown:aBoolean |
813 |
classShown := aBoolean. |
|
814 |
! |
|
815 |
||
16537 | 816 |
groupByInheritanceHolder:aValueHolder |
817 |
"/ is there a need for a valueHolder? |
|
818 |
groupByInheritanceHolder := aValueHolder. |
|
819 |
! |
|
820 |
||
10255 | 821 |
icon |
10871 | 822 |
icon isNil ifTrue:[ |
823 |
icon := application iconInBrowserForVariable: name in: class. |
|
824 |
icon isNil ifTrue:[icon := #NOICON]. |
|
825 |
]. |
|
10255 | 826 |
^icon |
827 |
||
828 |
"Created: / 12-04-2011 / 15:54:50 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
829 |
"Modified: / 12-04-2011 / 19:58:34 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10871 | 830 |
"Modified: / 18-11-2011 / 15:05:18 / cg" |
10255 | 831 |
! |
832 |
||
833 |
klass |
|
834 |
^ class |
|
835 |
||
836 |
"Created: / 12-04-2011 / 19:54:33 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
837 |
! |
|
838 |
||
10974 | 839 |
label |
840 |
||
841 |
label isNil ifTrue:[ |
|
842 |
label := name. |
|
843 |
type notNil ifTrue:[ |
|
16500 | 844 |
label := (label , ' ' , (type displayString withColor: Color brown)) |
13827 | 845 |
] ifFalse:[ |
846 |
"/ Hack for Java classes to display field type |
|
847 |
class theNonMetaclass isJavaClass ifTrue:[ |
|
848 |
| field | |
|
16773
a524b01249c1
Catch up with stx:libjava commit e35b48285df7
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16709
diff
changeset
|
849 |
field := class theNonMetaclass lookupFieldFor:name static: (class isMetaclass). |
13827 | 850 |
field notNil ifTrue:[ |
851 |
label := label asText , |
|
852 |
' ' , |
|
853 |
(('< ' , (JavaMethod fieldTypeFromStream: (field descriptor readStream) in: class theNonMetaclass javaPackage) , ' >') |
|
16500 | 854 |
withColor: Color brown). |
13827 | 855 |
]. |
856 |
]. |
|
13382 | 857 |
]. |
10974 | 858 |
]. |
859 |
^label |
|
860 |
||
861 |
"Created: / 16-12-2011 / 00:54:58 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
16773
a524b01249c1
Catch up with stx:libjava commit e35b48285df7
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16709
diff
changeset
|
862 |
"Modified: / 29-07-2016 / 21:29:58 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
10974 | 863 |
! |
864 |
||
13382 | 865 |
labelWithClass |
866 |
|l| |
|
867 |
||
868 |
l := self label. |
|
869 |
class notNil ifTrue:[ |
|
16500 | 870 |
^ label,' (' ,(class nameWithoutPrefix withColor: Color gray),')' |
13382 | 871 |
]. |
872 |
^label |
|
873 |
! |
|
874 |
||
10255 | 875 |
name |
876 |
^ name |
|
877 |
! |
|
878 |
||
879 |
name:aString |
|
880 |
name := aString. |
|
881 |
! |
|
882 |
||
16537 | 883 |
sortingByNameHolder:aValueHolder |
884 |
"/ is there a need for a valueHolder? |
|
885 |
sortingByNameHolder := aValueHolder. |
|
13382 | 886 |
! |
887 |
||
10255 | 888 |
string |
889 |
||
890 |
^name |
|
891 |
||
892 |
"Created: / 12-04-2011 / 15:45:20 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10974 | 893 |
! |
894 |
||
895 |
type |
|
896 |
"Return a SmallSense inferred type" |
|
897 |
||
898 |
^ type |
|
899 |
||
900 |
"Modified (format): / 16-12-2011 / 00:41:38 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
901 |
! |
|
902 |
||
903 |
type:aSmallSenseType |
|
904 |
"Sets a SmallSense inferred type" |
|
905 |
||
906 |
type := aSmallSenseType. |
|
907 |
||
908 |
"Modified (format): / 16-12-2011 / 00:41:35 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10255 | 909 |
! ! |
910 |
||
911 |
!VariableList::VariableEntry methodsFor:'displaying'! |
|
912 |
||
15455 | 913 |
displayOn:aGC x:x y:y opaque:opaque |
13382 | 914 |
| icn shownLabel | |
10255 | 915 |
|
916 |
icn := self icon. |
|
917 |
icn ~~ #NOICON ifTrue:[ |
|
918 |
icn displayOn:aGC x:x + 1 y:y - icn height. |
|
5591 | 919 |
]. |
13382 | 920 |
|
16537 | 921 |
shownLabel := ((classShown ? true) and:[sortingByNameHolder value and:[groupByInheritanceHolder value not]]) |
13382 | 922 |
ifTrue:[ self labelWithClass ] |
923 |
ifFalse: [ self label ]. |
|
924 |
||
925 |
shownLabel displayOn:aGC x:x + 20 y:y opaque: opaque |
|
10255 | 926 |
|
927 |
"Created: / 12-04-2011 / 15:47:09 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
5591 | 928 |
! ! |
929 |
||
10974 | 930 |
!VariableList::VariableEntry methodsFor:'queries'! |
931 |
||
932 |
widthOn:aGC |
|
933 |
||
934 |
^20"space for icon, see displayOn:..." |
|
935 |
+ (self label widthOn:aGC) |
|
936 |
||
937 |
"Created: / 16-12-2011 / 01:04:01 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
938 |
! ! |
|
939 |
||
5591 | 940 |
!VariableList class methodsFor:'documentation'! |
941 |
||
9461 | 942 |
version_CVS |
16192 | 943 |
^ '$Header$' |
16773
a524b01249c1
Catch up with stx:libjava commit e35b48285df7
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16709
diff
changeset
|
944 |
! |
a524b01249c1
Catch up with stx:libjava commit e35b48285df7
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16709
diff
changeset
|
945 |
|
a524b01249c1
Catch up with stx:libjava commit e35b48285df7
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16709
diff
changeset
|
946 |
version_HG |
a524b01249c1
Catch up with stx:libjava commit e35b48285df7
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16709
diff
changeset
|
947 |
|
a524b01249c1
Catch up with stx:libjava commit e35b48285df7
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
16709
diff
changeset
|
948 |
^ '$Changeset: <not expanded> $' |
5591 | 949 |
! ! |
12450 | 950 |