author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Wed, 30 Jan 2013 11:15:09 +0000 | |
branch | jv |
changeset 12401 | 4714b9640528 |
parent 12205 | f210b6224ef0 |
parent 11314 | 2f70adb99ceb |
child 12431 | 9f0c59c742d5 |
permissions | -rw-r--r-- |
9999 | 1 |
" |
10094 | 2 |
Copyright (c) 2007-2010 Jan Vrany, SWING Research Group, Czech Technical University in Prague |
3 |
Copyright (c) 2009-2010 eXept Software AG |
|
9999 | 4 |
|
10094 | 5 |
Permission is hereby granted, free of charge, to any person |
6 |
obtaining a copy of this software and associated documentation |
|
7 |
files (the 'Software'), to deal in the Software without |
|
8 |
restriction, including without limitation the rights to use, |
|
9 |
copy, modify, merge, publish, distribute, sublicense, and/or sell |
|
10 |
copies of the Software, and to permit persons to whom the |
|
11 |
Software is furnished to do so, subject to the following |
|
12 |
conditions: |
|
13 |
||
14 |
The above copyright notice and this permission notice shall be |
|
15 |
included in all copies or substantial portions of the Software. |
|
16 |
||
17 |
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, |
|
18 |
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
|
19 |
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
|
20 |
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
|
21 |
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
|
22 |
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
|
23 |
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
|
24 |
OTHER DEALINGS IN THE SOFTWARE. |
|
9999 | 25 |
" |
26 |
"{ Package: 'stx:libtool' }" |
|
27 |
||
28 |
"{ NameSpace: Tools }" |
|
29 |
||
30 |
ApplicationModel subclass:#LintRuleDetail |
|
10671 | 31 |
instanceVariableNames:'ruleHolder rationaleVisibleHolder rationalView' |
10480 | 32 |
classVariableNames:'' |
33 |
poolDictionaries:'' |
|
34 |
category:'Interface-Lint' |
|
9999 | 35 |
! |
36 |
||
37 |
!LintRuleDetail class methodsFor:'documentation'! |
|
38 |
||
39 |
copyright |
|
40 |
" |
|
10094 | 41 |
Copyright (c) 2007-2010 Jan Vrany, SWING Research Group, Czech Technical University in Prague |
42 |
Copyright (c) 2009-2010 eXept Software AG |
|
43 |
||
44 |
Permission is hereby granted, free of charge, to any person |
|
45 |
obtaining a copy of this software and associated documentation |
|
46 |
files (the 'Software'), to deal in the Software without |
|
47 |
restriction, including without limitation the rights to use, |
|
48 |
copy, modify, merge, publish, distribute, sublicense, and/or sell |
|
49 |
copies of the Software, and to permit persons to whom the |
|
50 |
Software is furnished to do so, subject to the following |
|
51 |
conditions: |
|
9999 | 52 |
|
10094 | 53 |
The above copyright notice and this permission notice shall be |
54 |
included in all copies or substantial portions of the Software. |
|
55 |
||
56 |
THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND, |
|
57 |
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES |
|
58 |
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND |
|
59 |
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT |
|
60 |
HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, |
|
61 |
WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING |
|
62 |
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR |
|
63 |
OTHER DEALINGS IN THE SOFTWARE. |
|
9999 | 64 |
" |
65 |
! ! |
|
66 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
67 |
|
10672 | 68 |
!LintRuleDetail class methodsFor:'help specs'! |
69 |
||
70 |
flyByHelpSpec |
|
71 |
"This resource specification was automatically generated |
|
72 |
by the UIHelpTool of ST/X." |
|
73 |
||
74 |
"Do not manually edit this!! If it is corrupted, |
|
75 |
the UIHelpTool may not be able to read the specification." |
|
76 |
||
77 |
" |
|
78 |
UIHelpTool openOnClass:Tools::LintRuleDetail |
|
79 |
" |
|
80 |
||
81 |
<resource: #help> |
|
82 |
||
83 |
^ super flyByHelpSpec addPairsFrom:#( |
|
84 |
||
85 |
#ruleName |
|
86 |
'Click to browse the lint rule' |
|
87 |
||
88 |
) |
|
89 |
||
90 |
"Created: / 07-09-2011 / 04:08:11 / cg" |
|
91 |
! ! |
|
92 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
93 |
|
9999 | 94 |
!LintRuleDetail class methodsFor:'interface specs'! |
95 |
||
96 |
windowSpec |
|
97 |
"This resource specification was automatically generated |
|
98 |
by the UIPainter of ST/X." |
|
99 |
||
100 |
"Do not manually edit this!! If it is corrupted, |
|
101 |
the UIPainter may not be able to read the specification." |
|
102 |
||
103 |
" |
|
104 |
UIPainter new openOnClass:Tools::LintRuleDetail andSelector:#windowSpec |
|
105 |
Tools::LintRuleDetail new openInterface:#windowSpec |
|
106 |
Tools::LintRuleDetail open |
|
107 |
" |
|
108 |
||
109 |
<resource: #canvas> |
|
110 |
||
10500 | 111 |
^ |
9999 | 112 |
#(FullSpec |
10500 | 113 |
name: windowSpec |
114 |
window: |
|
9999 | 115 |
(WindowSpec |
10500 | 116 |
label: 'SmalllintRuleDetail' |
117 |
name: 'SmalllintRuleDetail' |
|
118 |
min: (Point 10 10) |
|
119 |
bounds: (Rectangle 0 0 560 300) |
|
120 |
) |
|
121 |
component: |
|
9999 | 122 |
(SpecCollection |
10500 | 123 |
collection: ( |
124 |
(VerticalPanelViewSpec |
|
125 |
name: 'Panel' |
|
126 |
layout: (LayoutFrame 0 0 0 0 0 1 0 1) |
|
127 |
horizontalLayout: fit |
|
128 |
verticalLayout: topSpaceFit |
|
129 |
horizontalSpace: 0 |
|
130 |
verticalSpace: 0 |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
131 |
ignoreInvisibleComponents: true |
10500 | 132 |
component: |
133 |
(SpecCollection |
|
134 |
collection: ( |
|
135 |
(ViewSpec |
|
136 |
name: 'Label' |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
137 |
visibilityChannel: false |
10500 | 138 |
component: |
139 |
(SpecCollection |
|
140 |
collection: ( |
|
10672 | 141 |
(LinkButtonSpec |
142 |
name: 'Button1' |
|
143 |
layout: (LayoutFrame 0 0 0 0 -150 1 30 0) |
|
144 |
activeHelpKey: ruleName |
|
10500 | 145 |
translateLabel: true |
146 |
labelChannel: ruleNameAspect |
|
147 |
adjust: left |
|
10672 | 148 |
model: browseLintRule |
10500 | 149 |
) |
150 |
(CheckBoxSpec |
|
151 |
label: 'Show Rationale' |
|
152 |
name: 'CheckBox1' |
|
153 |
layout: (LayoutFrame -150 1 0 0 0 1 30 0) |
|
154 |
model: rationaleVisibleHolder |
|
155 |
translateLabel: true |
|
156 |
) |
|
157 |
) |
|
158 |
||
159 |
) |
|
160 |
extent: (Point 560 30) |
|
161 |
) |
|
162 |
(HTMLViewSpec |
|
163 |
name: 'Rationale' |
|
164 |
level: 0 |
|
165 |
visibilityChannel: rationaleVisibleHolder |
|
166 |
hasHorizontalScrollBar: true |
|
167 |
hasVerticalScrollBar: true |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
168 |
backgroundColor: (Color 86.9993133440147 86.9993133440147 86.9993133440147) |
10500 | 169 |
htmlText: ruleRationaleAspect |
170 |
extent: (Point 560 270) |
|
171 |
postBuildCallback: setupHTMLView: |
|
172 |
) |
|
173 |
) |
|
174 |
||
175 |
) |
|
176 |
) |
|
177 |
) |
|
178 |
||
179 |
) |
|
9999 | 180 |
) |
181 |
! ! |
|
182 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
183 |
|
9999 | 184 |
!LintRuleDetail class methodsFor:'plugIn spec'! |
185 |
||
186 |
aspectSelectors |
|
187 |
"This resource specification was automatically generated |
|
188 |
by the UIPainter of ST/X." |
|
189 |
||
190 |
"Do not manually edit this. If it is corrupted, |
|
191 |
the UIPainter may not be able to read the specification." |
|
192 |
||
193 |
"Return a description of exported aspects; |
|
194 |
these can be connected to aspects of an embedding application |
|
195 |
(if this app is embedded in a subCanvas)." |
|
196 |
||
197 |
^ #( |
|
10663
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
198 |
#ruleHolder |
11306 | 199 |
#ruleRationaleAspect |
9999 | 200 |
). |
201 |
||
11306 | 202 |
"Modified: / 01-03-2012 / 16:31:04 / cg" |
9999 | 203 |
! ! |
204 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
205 |
|
10672 | 206 |
!LintRuleDetail methodsFor:'actions'! |
207 |
||
208 |
browseLintRule |
|
209 |
|rule ruleClass sel| |
|
210 |
||
211 |
rule := self ruleHolder value. |
|
212 |
rule isNil ifTrue:[^ self]. |
|
213 |
ruleClass := rule class. |
|
214 |
(ruleClass implements:#rationale) ifTrue:[ |
|
215 |
sel := #rationale. |
|
216 |
]. |
|
217 |
UserPreferences current systemBrowserClass |
|
218 |
openInClass:ruleClass selector:sel |
|
219 |
||
220 |
"Created: / 07-09-2011 / 04:09:38 / cg" |
|
221 |
! ! |
|
222 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
223 |
|
9999 | 224 |
!LintRuleDetail methodsFor:'aspects'! |
225 |
||
10473 | 226 |
rationaleVisibleHolder |
227 |
"return/create the 'rationaleVisibleHolder' value holder (automatically generated)" |
|
228 |
||
229 |
rationaleVisibleHolder isNil ifTrue:[ |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
230 |
rationaleVisibleHolder := ValueHolder with: true "false". |
10500 | 231 |
rationaleVisibleHolder addDependent:self. |
10473 | 232 |
]. |
233 |
^ rationaleVisibleHolder |
|
234 |
||
235 |
"Modified: / 04-08-2011 / 21:39:51 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
236 |
"Modified: / 01-03-2012 / 08:50:20 / cg" |
10473 | 237 |
! |
238 |
||
239 |
rationaleVisibleHolder:something |
|
240 |
"set the 'rationaleVisibleHolder' value holder (automatically generated)" |
|
241 |
||
242 |
|oldValue newValue| |
|
243 |
||
244 |
rationaleVisibleHolder notNil ifTrue:[ |
|
10500 | 245 |
oldValue := rationaleVisibleHolder value. |
246 |
rationaleVisibleHolder removeDependent:self. |
|
10473 | 247 |
]. |
248 |
rationaleVisibleHolder := something. |
|
249 |
rationaleVisibleHolder notNil ifTrue:[ |
|
10500 | 250 |
rationaleVisibleHolder addDependent:self. |
10473 | 251 |
]. |
252 |
newValue := rationaleVisibleHolder value. |
|
253 |
oldValue ~~ newValue ifTrue:[ |
|
10500 | 254 |
self update:#value with:newValue from:rationaleVisibleHolder. |
10473 | 255 |
]. |
256 |
! |
|
257 |
||
9999 | 258 |
ruleHolder |
259 |
"return/create the 'ruleHolder' value holder (automatically generated)" |
|
260 |
||
261 |
ruleHolder isNil ifTrue:[ |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
262 |
ruleHolder := ValueHolder new. |
9999 | 263 |
]. |
264 |
^ ruleHolder |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
265 |
|
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
266 |
"Modified: / 01-03-2012 / 08:51:03 / cg" |
9999 | 267 |
! |
268 |
||
10473 | 269 |
ruleHolder:something |
9999 | 270 |
"set the 'ruleHolder' value holder (automatically generated)" |
271 |
||
10473 | 272 |
|oldValue newValue| |
273 |
||
274 |
ruleHolder notNil ifTrue:[ |
|
11306 | 275 |
oldValue := ruleHolder value. |
276 |
ruleHolder removeDependent:self. |
|
10473 | 277 |
]. |
278 |
ruleHolder := something. |
|
279 |
ruleHolder notNil ifTrue:[ |
|
11306 | 280 |
ruleHolder addDependent:self. |
10473 | 281 |
]. |
282 |
newValue := ruleHolder value. |
|
283 |
oldValue ~~ newValue ifTrue:[ |
|
11306 | 284 |
self update:#value with:newValue from:ruleHolder. |
10473 | 285 |
]. |
11306 | 286 |
|
287 |
"Modified: / 01-03-2012 / 15:29:30 / cg" |
|
9999 | 288 |
! |
289 |
||
290 |
ruleNameAspect |
|
291 |
<resource: #uiAspect> |
|
292 |
||
293 |
|holder| |
|
294 |
||
295 |
(holder := builder bindingAt:#ruleNameAspect) isNil ifTrue:[ |
|
10672 | 296 |
holder := BlockValue |
10673 | 297 |
with:[:h | |
298 |
"/ h displayString , ' ' , (('[browse]' actionForAll:[ self browseLintRule]) colorizeAllWith:Color blue) |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
299 |
(h ? '') displayString actionForAll:[ self browseLintRule ] |
10673 | 300 |
] |
10672 | 301 |
argument: self ruleHolder. |
302 |
builder aspectAt:#ruleNameAspect put:holder. |
|
9999 | 303 |
]. |
304 |
^ holder. |
|
305 |
||
306 |
"Modified: / 05-02-2010 / 12:51:30 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
307 |
"Modified: / 01-03-2012 / 08:44:23 / cg" |
9999 | 308 |
! |
309 |
||
310 |
ruleRationaleAspect |
|
311 |
<resource: #uiAspect> |
|
312 |
||
313 |
|holder| |
|
314 |
||
315 |
(holder := builder bindingAt:#ruleRationaleAspect) isNil ifTrue:[ |
|
11306 | 316 |
"cannot use a BlockValue linked on the ruleHolder for the |
317 |
ruleRationaleAspect, because the ruleHolder maight be changed dynamically |
|
318 |
via the aspect-linking mechanism" |
|
319 |
"/ holder := (AspectAdaptor forAspect: #rationale) subjectChannel: self ruleHolder. |
|
320 |
holder := '' asValue. |
|
10672 | 321 |
builder aspectAt:#ruleRationaleAspect put:holder. |
9999 | 322 |
]. |
323 |
^ holder. |
|
324 |
||
325 |
"Modified: / 05-02-2010 / 12:51:42 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11306 | 326 |
"Modified: / 01-03-2012 / 15:29:16 / cg" |
9999 | 327 |
! ! |
328 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
329 |
|
10473 | 330 |
!LintRuleDetail methodsFor:'change & update'! |
331 |
||
332 |
update:something with:aParameter from:changedObject |
|
333 |
"Invoked when an object that I depend upon sends a change notification." |
|
334 |
||
335 |
changedObject == ruleHolder ifTrue:[ |
|
10500 | 336 |
self updateVisibility. |
11306 | 337 |
self updateRule. |
10500 | 338 |
^ self. |
10473 | 339 |
]. |
340 |
changedObject == rationaleVisibleHolder ifTrue:[ |
|
10500 | 341 |
self updateVisibility. |
342 |
^ self. |
|
10473 | 343 |
]. |
344 |
super update:something with:aParameter from:changedObject |
|
345 |
||
346 |
"Modified: / 04-08-2011 / 21:31:13 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11306 | 347 |
"Modified: / 01-03-2012 / 15:27:38 / cg" |
348 |
! |
|
349 |
||
350 |
updateRule |
|
351 |
"cannot use a BlockValue linked on the ruleHolder for the |
|
352 |
ruleRationaleAspect, because the ruleHolder maight be changed dynamically |
|
353 |
via the aspect-linking mechanism" |
|
354 |
||
355 |
|rule| |
|
356 |
||
357 |
rule := self ruleHolder value. |
|
11314 | 358 |
self ruleRationaleAspect value: (rule isNil ifTrue:[''] ifFalse:[rule rationaleWithAnchor]). |
11306 | 359 |
|
360 |
"Created: / 01-03-2012 / 15:28:18 / cg" |
|
10473 | 361 |
! |
362 |
||
363 |
updateVisibility |
|
364 |
||
10480 | 365 |
self ruleHolder value notNil |
10663
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
366 |
ifTrue:[self show] |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
367 |
ifFalse:[self hide]. |
10473 | 368 |
|
369 |
"Created: / 04-08-2011 / 16:39:09 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10663
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
370 |
"Modified: / 04-09-2011 / 20:18:48 / cg" |
10473 | 371 |
! ! |
372 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
373 |
|
10500 | 374 |
!LintRuleDetail methodsFor:'initialization'! |
375 |
||
376 |
setupHTMLView:aView |
|
10671 | 377 |
rationalView := aView. |
10500 | 378 |
aView painter |
10671 | 379 |
leftMargin:20; |
380 |
topMargin:5. |
|
10500 | 381 |
|
382 |
"Created: / 04-08-2011 / 18:00:36 / cg" |
|
383 |
! ! |
|
384 |
||
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
385 |
|
10473 | 386 |
!LintRuleDetail methodsFor:'private'! |
387 |
||
10671 | 388 |
heightWhenNotShowingRationale |
389 |
^ 30 |
|
390 |
||
391 |
"Created: / 07-09-2011 / 04:02:34 / cg" |
|
392 |
! |
|
393 |
||
394 |
heightWhenShowingRationale |
|
395 |
^ 100 |
|
396 |
||
397 |
"Created: / 07-09-2011 / 04:02:24 / cg" |
|
398 |
! |
|
399 |
||
10473 | 400 |
hide |
401 |
||
402 |
self visibility: false height: 0 |
|
403 |
||
404 |
"Created: / 11-03-2010 / 09:07:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
405 |
! |
|
406 |
||
407 |
show |
|
10671 | 408 |
self |
409 |
visibility: true |
|
410 |
height: (self rationaleVisibleHolder value |
|
411 |
ifTrue:[ self heightWhenShowingRationale ] |
|
412 |
ifFalse:[ self heightWhenNotShowingRationale ]) |
|
10473 | 413 |
|
414 |
"Created: / 11-03-2010 / 09:07:24 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
10671 | 415 |
"Modified: / 07-09-2011 / 04:03:07 / cg" |
10473 | 416 |
! |
417 |
||
418 |
visibility: visibility height: height |
|
419 |
| container list detail h | |
|
10663
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
420 |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
421 |
"/ cg: the whole conatiner-container access chains below is ugly - use a name to access components. |
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
422 |
"/ and also: there is no layout in list, so the code does crash. |
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
423 |
"/ I disabled the whole visibility stuff. |
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
424 |
^ self. |
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
425 |
|
10663
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
426 |
(container := self window container) isNil ifTrue:[^self]. |
10473 | 427 |
h := visibility ifFalse:[0] ifTrue:[height]. |
428 |
||
10663
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
429 |
container isVisible == visibility ifFalse: [ |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
430 |
container isVisible: visibility |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
431 |
]. |
10473 | 432 |
|
433 |
list := container container subViews first. |
|
434 |
detail := container container subViews second. |
|
435 |
||
10663
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
436 |
(list layout bottomOffset ~= height negated) ifTrue:[ |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
437 |
list layout: (list layout bottomOffset: height negated; yourself) |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
438 |
]. |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
439 |
(detail layout topOffset ~= height negated) ifTrue:[ |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
440 |
detail layout: (detail layout topOffset: height negated; yourself) |
32e84728c885
comment/format in: #updateVisibility
Claus Gittinger <cg@exept.de>
parents:
10500
diff
changeset
|
441 |
]. |
10473 | 442 |
|
443 |
"Created: / 11-03-2010 / 09:51:26 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
11299
3e8397061396
fix: visibility switch and rationale did not work
Claus Gittinger <cg@exept.de>
parents:
10673
diff
changeset
|
444 |
"Modified: / 01-03-2012 / 10:35:51 / cg" |
10480 | 445 |
! ! |
10473 | 446 |
|
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
447 |
|
9999 | 448 |
!LintRuleDetail class methodsFor:'documentation'! |
449 |
||
10672 | 450 |
version |
11314 | 451 |
^ '$Header: /cvs/stx/stx/libtool/Tools__LintRuleDetail.st,v 1.13 2012-03-01 19:59:38 cg Exp $' |
10672 | 452 |
! |
453 |
||
9999 | 454 |
version_CVS |
11314 | 455 |
^ '$Header: /cvs/stx/stx/libtool/Tools__LintRuleDetail.st,v 1.13 2012-03-01 19:59:38 cg Exp $' |
9999 | 456 |
! |
457 |
||
458 |
version_SVN |
|
459 |
^ '§Id: Tools__LintRuleDetail.st 7617 2010-08-25 12:56:19Z vranyj1 §' |
|
460 |
! ! |
|
12401
4714b9640528
Merged 235b77901045 and 8332590c5a41 (branch default)
Jan Vrany <jan.vrany@fit.cvut.cz>
diff
changeset
|
461 |