author | Claus Gittinger <cg@exept.de> |
Wed, 09 Feb 2011 14:03:29 +0100 | |
changeset 9750 | 1b2ef761d2d0 |
parent 9685 | 629e1d789a2d |
child 9879 | 5109d9da29eb |
permissions | -rw-r--r-- |
36 | 1 |
" |
2 |
COPYRIGHT (c) 1989 by Claus Gittinger |
|
4158 | 3 |
All Rights Reserved |
36 | 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 |
" |
|
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
12 |
"{ Package: 'stx:libtool' }" |
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
13 |
|
85 | 14 |
ApplicationModel subclass:#SystemBrowser |
4165 | 15 |
instanceVariableNames:'' |
16 |
classVariableNames:'CheckForInstancesWhenRemovingClasses ClassHistory |
|
17 |
EmphasisForDifferentPackage EmphasisForModifiedBuffer |
|
18 |
EmphasisForObsoleteCode EmphasisForReadVariable |
|
19 |
EmphasisForWrittenVariable EmphasisForChangedCode' |
|
20 |
poolDictionaries:'' |
|
21 |
category:'Interface-Browsers' |
|
36 | 22 |
! |
23 |
||
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
24 |
Object subclass:#BrowserHistoryEntry |
4165 | 25 |
instanceVariableNames:'className meta selector' |
26 |
classVariableNames:'' |
|
27 |
poolDictionaries:'' |
|
28 |
privateIn:SystemBrowser |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
29 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
30 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
31 |
!SystemBrowser class methodsFor:'documentation'! |
203 | 32 |
|
33 |
copyright |
|
34 |
" |
|
35 |
COPYRIGHT (c) 1989 by Claus Gittinger |
|
4158 | 36 |
All Rights Reserved |
203 | 37 |
|
38 |
This software is furnished under a license and may be used |
|
39 |
only in accordance with the terms of that license and with the |
|
40 |
inclusion of the above copyright notice. This software may not |
|
41 |
be provided or otherwise made available to, or used by, any |
|
42 |
other person. No title to or ownership of the software is |
|
43 |
hereby transferred. |
|
44 |
" |
|
45 |
! |
|
46 |
||
47 |
documentation |
|
48 |
" |
|
8893 | 49 |
Notice: SystemBrowser has been completely rewritten to be an instance |
8894 | 50 |
of ApplicationModel. This rewritten version is found under NewSystemBrowser. |
8893 | 51 |
Because the class protocol here was used by many others, it is left here |
52 |
as an instance-less functionality provider only. |
|
203 | 53 |
|
54 |
written winter 89 by claus. |
|
55 |
||
508 | 56 |
[author:] |
57 |
Claus Gittinger |
|
58 |
||
203 | 59 |
" |
60 |
! ! |
|
61 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
62 |
!SystemBrowser class methodsFor:'initialization'! |
75 | 63 |
|
64 |
initialize |
|
65 |
"Browser configuration; |
|
66 |
(values can be changed from your private startup file)" |
|
45 | 67 |
|
254 | 68 |
"/ self classResources. |
85 | 69 |
|
75 | 70 |
" |
71 |
setting this to false, the removeClass function will remove |
|
72 |
classes WITHOUT checking for instances. Otherwise, |
|
73 |
it will check and let you confirm in case there are instances. |
|
74 |
Checking for instances may be a bit time consuming, though. |
|
75 |
The default is true - therefore, it will check |
|
76 |
" |
|
77 |
CheckForInstancesWhenRemovingClasses := true |
|
78 |
||
79 |
" |
|
80 |
CheckForInstancesWhenRemovingClasses := true |
|
81 |
CheckForInstancesWhenRemovingClasses := false |
|
82 |
||
85 | 83 |
SystemBrowser initialize |
75 | 84 |
" |
85 |
! ! |
|
36 | 86 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
87 |
!SystemBrowser class methodsFor:'instance creation'! |
52 | 88 |
|
75 | 89 |
open |
90 |
"launch a standard browser" |
|
91 |
||
2631 | 92 |
self == SystemBrowser ifFalse:[ |
93 |
^ super open |
|
94 |
]. |
|
95 |
||
105 | 96 |
^ self openOnDevice:(Screen current) |
75 | 97 |
|
93 | 98 |
" |
99 |
SystemBrowser open |
|
100 |
" |
|
194 | 101 |
! |
102 |
||
523 | 103 |
openInClass:aClass |
104 |
"launch a standard browser which immediately switches |
|
105 |
to aClass" |
|
106 |
||
107 |
^ self openInClass:aClass selector:nil |
|
108 |
||
109 |
" |
|
110 |
SystemBrowser openInClass:Object |
|
111 |
" |
|
112 |
||
113 |
"Created: 30.4.1996 / 14:43:45 / cg" |
|
114 |
! |
|
115 |
||
194 | 116 |
openInClass:aClass selector:aSelector |
117 |
"launch a standard browser which immediately switches |
|
118 |
to aClass>>aSelector." |
|
119 |
||
3626 | 120 |
|brwsr classesName| |
194 | 121 |
|
122 |
brwsr := self openOnDevice:(Screen current). |
|
123 |
brwsr waitUntilVisible. |
|
1561 | 124 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
125 |
aClass notNil ifTrue:[ |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
126 |
"/ cls := aClass. |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
127 |
"/ cls isMeta ifTrue:[ |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
128 |
"/ cls := aClass soleInstance |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
129 |
"/ ]. |
1561 | 130 |
aClass isMeta ifTrue:[ |
131 |
brwsr instanceProtocol:false |
|
132 |
]. |
|
1931
03de5c5f4402
care for javaClass in #openInClass:selector:
Claus Gittinger <cg@exept.de>
parents:
1919
diff
changeset
|
133 |
aClass isJavaClass ifTrue:[ |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
134 |
classesName := aClass fullName. |
1931
03de5c5f4402
care for javaClass in #openInClass:selector:
Claus Gittinger <cg@exept.de>
parents:
1919
diff
changeset
|
135 |
] ifFalse:[ |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
136 |
classesName := aClass name. |
1931
03de5c5f4402
care for javaClass in #openInClass:selector:
Claus Gittinger <cg@exept.de>
parents:
1919
diff
changeset
|
137 |
]. |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
138 |
brwsr switchToClassNamed:classesName. |
1681 | 139 |
brwsr classSelectionChanged. |
1561 | 140 |
aSelector notNil ifTrue:[ |
141 |
brwsr switchToMethodNamed:aSelector. |
|
142 |
] |
|
194 | 143 |
]. |
144 |
^ brwsr |
|
145 |
||
146 |
" |
|
147 |
SystemBrowser openInClass:Object selector:#at:put: |
|
148 |
SystemBrowser openInClass:Object selector:nil |
|
149 |
SystemBrowser openInClass:nil selector:nil |
|
150 |
" |
|
151 |
||
1561 | 152 |
"Created: / 22.11.1995 / 21:04:50 / cg" |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
153 |
"Modified: / 5.11.2001 / 16:51:02 / cg" |
203 | 154 |
! |
155 |
||
3588 | 156 |
openOn:anEnvironment |
4921 | 157 |
^ self |
158 |
openOn:anEnvironment |
|
159 |
label:(self classResources string:'System Browser') |
|
3588 | 160 |
|
161 |
" |
|
162 |
SystemBrowser openOn:Smalltalk |
|
3589 | 163 |
SystemBrowser openOn:Demos |
3588 | 164 |
" |
165 |
! |
|
166 |
||
4921 | 167 |
openOn:aClassEnvironment label:title |
168 |
^ self |
|
169 |
openOn:aClassEnvironment |
|
170 |
label:title |
|
171 |
onDevice:(Screen current) |
|
172 |
! |
|
173 |
||
174 |
openOn:aClassEnvironment label:title onDevice:aDisplayDevice |
|
175 |
|browser| |
|
176 |
||
177 |
browser := self |
|
178 |
newWithLabel:title |
|
179 |
setupBlock:[:browser | browser environment:aClassEnvironment. |
|
180 |
browser setupForAll] |
|
181 |
onDevice:aDisplayDevice. |
|
182 |
^ browser |
|
183 |
! |
|
184 |
||
203 | 185 |
openOnDevice:aDisplay |
186 |
"launch a standard browser on another display." |
|
187 |
||
2631 | 188 |
self == SystemBrowser ifFalse:[ |
189 |
^ super openOnDevice:aDisplay |
|
190 |
]. |
|
191 |
||
3519 | 192 |
^ self |
4921 | 193 |
openOn:Smalltalk |
194 |
label:(self classResources string:'System Browser') |
|
3519 | 195 |
onDevice:aDisplay |
203 | 196 |
|
197 |
"|d| |
|
198 |
||
199 |
d := XWorkstation new initializeFor:'porty:0'. |
|
200 |
d startDispatch. |
|
201 |
SystemBrowser openOnDevice:d |
|
202 |
" |
|
2818 | 203 |
! |
204 |
||
3573 | 205 |
openOnRemoteImageOnHost:aHostName port:portOrNil |
4921 | 206 |
|environment| |
3573 | 207 |
|
208 |
environment := RemoteImage onHost:aHostName port:portOrNil. |
|
4921 | 209 |
^ self |
210 |
openOn:environment |
|
211 |
label:(self classResources string:'RemoteImage Browser - %1' with:aHostName) |
|
3573 | 212 |
|
213 |
" |
|
214 |
SystemBrowser openOnRemoteImageOnHost:'funkfix' port:nil |
|
7998 | 215 |
SystemBrowser openOnRemoteImageOnHost:'192.168.8.1' port:nil |
3573 | 216 |
" |
217 |
! |
|
218 |
||
2818 | 219 |
openOnSnapShotImage:anImageFileName |
4921 | 220 |
|environment| |
2818 | 221 |
|
222 |
environment := SnapShotImage for:anImageFileName. |
|
4921 | 223 |
^ self |
224 |
openOn:environment |
|
225 |
label:(self classResources string:'Image Browser - %1' with:anImageFileName asFilename baseName) |
|
2818 | 226 |
|
227 |
" |
|
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
228 |
SystemBrowser openOnSnapShotImage:('/tmp/stmeas.img') |
2824 | 229 |
" |
230 |
! ! |
|
36 | 231 |
|
4909 | 232 |
!SystemBrowser class methodsFor:'Compatibility-ST80'! |
1356 | 233 |
|
234 |
newOnClass:aClass |
|
235 |
^ self browseClass:aClass |
|
236 |
||
237 |
"Created: / 27.10.1997 / 20:10:39 / cg" |
|
238 |
! ! |
|
239 |
||
4909 | 240 |
!SystemBrowser class methodsFor:'accessing-history'! |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
241 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
242 |
addToHistory:aClass selector:aSelectorOrNil |
3679 | 243 |
|newEntry oldEntry classHistory| |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
244 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
245 |
(newEntry := self historyEntryForClass:aClass selector:aSelectorOrNil) isNil ifTrue:[^ self]. |
3679 | 246 |
classHistory := self classHistory. |
247 |
||
248 |
oldEntry := classHistory detect:[:entry | entry className = newEntry className] ifNone:nil. |
|
249 |
oldEntry notNil ifTrue:[ |
|
250 |
classHistory removeIdentical:oldEntry. |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
251 |
]. |
3679 | 252 |
classHistory addFirst:newEntry. |
253 |
classHistory size > self visitedHistoryMaxSize ifTrue:[ |
|
254 |
classHistory removeLast |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
255 |
]. |
7524
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
256 |
SystemBrowser changed:#visitedClassHistory with:classHistory. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
257 |
|
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
258 |
"Modified: / 20-11-2006 / 12:29:45 / cg" |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
259 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
260 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
261 |
checkClassHistory |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
262 |
"checks the class history for non-existing classes" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
263 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
264 |
"/ reverse, since we might modify while enumerating |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
265 |
self classHistory reverseDo:[:histEntry| |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
266 |
(Smalltalk at: (histEntry className) asSymbol) isBehavior |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
267 |
ifFalse:[ |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
268 |
self classHistory remove: histEntry |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
269 |
] |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
270 |
] |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
271 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
272 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
273 |
classHistory |
3679 | 274 |
ClassHistory isNil ifTrue:[ |
275 |
ClassHistory := List new |
|
276 |
]. |
|
277 |
^ ClassHistory |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
278 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
279 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
280 |
classHistory:newCollection |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
281 |
ClassHistory := newCollection |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
282 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
283 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
284 |
emptyClassHistory |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
285 |
"removes all class history entries" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
286 |
|
7524
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
287 |
|classHistory| |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
288 |
|
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
289 |
classHistory := self classHistory. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
290 |
classHistory removeAll. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
291 |
SystemBrowser changed:#visitedClassHistory with:classHistory. |
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
292 |
|
0257265ae6b7
do not make dependent on the history-list;
Claus Gittinger <cg@exept.de>
parents:
7395
diff
changeset
|
293 |
"Modified: / 20-11-2006 / 12:29:42 / cg" |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
294 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
295 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
296 |
historyEntryForClass:aClass selector:aSelectorOrNil |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
297 |
|newEntry meta cls| |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
298 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
299 |
aClass isBehavior ifFalse:[^ nil]. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
300 |
|
3151 | 301 |
(meta := aClass isMeta) ifTrue:[ |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
302 |
cls := aClass theNonMetaclass. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
303 |
] ifFalse:[ |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
304 |
cls := aClass |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
305 |
]. |
3151 | 306 |
newEntry := BrowserHistoryEntry new. |
307 |
newEntry |
|
308 |
className:cls name |
|
309 |
meta:meta |
|
310 |
selector:aSelectorOrNil. |
|
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
311 |
^ newEntry |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
312 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
313 |
"Modified: / 24.2.2000 / 18:03:52 / cg" |
9189
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
314 |
! |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
315 |
|
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
316 |
visitedClassNamesHistory |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
317 |
^ self classHistory |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
318 |
collect:[:e | e className] |
9f57319e21ca
added: #visitedClassNamesHistory
Claus Gittinger <cg@exept.de>
parents:
9157
diff
changeset
|
319 |
thenSelect:[:nm | nm notEmptyOrNil] |
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
320 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
321 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
322 |
!SystemBrowser class methodsFor:'defaults'! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
323 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
324 |
classHistoryMaxLevels |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
325 |
^ 3 |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
326 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
327 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
328 |
classHistoryMaxSize |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
329 |
^ 15 |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
330 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
331 |
|
3549 | 332 |
methodTemplate |
8877 | 333 |
"return a method definition template string or nil" |
334 |
||
335 |
^ SmalltalkLanguage instance methodTemplate |
|
3549 | 336 |
! |
337 |
||
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
338 |
visitedHistoryMaxSize |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
339 |
"the maximum number of remembered visited-class-history entries" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
340 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
341 |
^ 15 |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
342 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
343 |
|
4909 | 344 |
!SystemBrowser class methodsFor:'defaults-presentation'! |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
345 |
|
3352 | 346 |
emphasisForChangedCode |
4499 | 347 |
^ UserPreferences current emphasisForChangedCode. |
3352 | 348 |
|
349 |
" |
|
350 |
EmphasisForChangedCode := #underwave |
|
4112 | 351 |
EmphasisForChangedCode := #color->Color blue |
3352 | 352 |
EmphasisForChangedCode := #color->Color red lightened lightened lightened |
353 |
" |
|
354 |
||
355 |
"Created: / 31.10.2001 / 10:15:33 / cg" |
|
356 |
! |
|
357 |
||
358 |
emphasisForChangedCode:anEmphasis |
|
359 |
EmphasisForChangedCode := anEmphasis |
|
360 |
||
361 |
" |
|
362 |
self emphasisForChangedCode:#underwave |
|
363 |
self emphasisForChangedCode:(#color->Color red lightened lightened lightened) |
|
364 |
" |
|
365 |
||
366 |
"Created: / 31.10.2001 / 10:15:44 / cg" |
|
367 |
! |
|
368 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
369 |
emphasisForDifferentPackage |
4499 | 370 |
^ UserPreferences current emphasisForDifferentPackage. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
371 |
|
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
372 |
" |
3352 | 373 |
EmphasisForDifferentPackage := nil. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
374 |
EmphasisForDifferentPackage := #underwave |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
375 |
EmphasisForDifferentPackage := #color->Color red lightened lightened lightened |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
376 |
" |
3352 | 377 |
|
378 |
"Modified: / 31.10.2001 / 10:47:25 / cg" |
|
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
379 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
380 |
|
3241 | 381 |
emphasisForDifferentPackage:anEmphasis |
382 |
EmphasisForDifferentPackage := anEmphasis |
|
383 |
||
384 |
" |
|
385 |
self emphasisForDifferentPackage:#underwave |
|
386 |
self emphasisForDifferentPackage:(#color->Color red lightened lightened lightened) |
|
387 |
" |
|
388 |
! |
|
389 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
390 |
emphasisForModifiedBuffer |
4499 | 391 |
^ UserPreferences current emphasisForModifiedBuffer. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
392 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
393 |
|
3241 | 394 |
emphasisForModifiedBuffer:anEmphasis |
395 |
EmphasisForModifiedBuffer := anEmphasis |
|
396 |
! |
|
397 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
398 |
emphasisForObsoleteCode |
4499 | 399 |
^ UserPreferences current emphasisForObsoleteCode. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
400 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
401 |
|
3241 | 402 |
emphasisForObsoleteCode:anEmphasis |
403 |
EmphasisForObsoleteCode := anEmphasis |
|
404 |
! |
|
405 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
406 |
emphasisForReadVariable |
4499 | 407 |
^ UserPreferences current emphasisForReadVariable. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
408 |
|
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
409 |
" |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
410 |
EmphasisForReadVariable := #underline |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
411 |
EmphasisForReadVariable := Array with:#underline with:#underlineColor->Color yellow |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
412 |
" |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
413 |
! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
414 |
|
3241 | 415 |
emphasisForReadVariable:anEmphasis |
416 |
EmphasisForReadVariable := anEmphasis |
|
417 |
||
418 |
" |
|
419 |
self emphasisForReadVariable:#underline |
|
420 |
self emphasisForReadVariable:(Array with:#underline with:#underlineColor->Color yellow) |
|
421 |
" |
|
422 |
! |
|
423 |
||
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
424 |
emphasisForWrittenVariable |
4499 | 425 |
^ UserPreferences current emphasisForWrittenVariable. |
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
426 |
|
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
427 |
" |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
428 |
EmphasisForWrittenVariable := #underline |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
429 |
EmphasisForWrittenVariable := Array with:#underline with:#underlineColor->Color red lightened |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
430 |
" |
3241 | 431 |
! |
432 |
||
433 |
emphasisForWrittenVariable:anEmphasis |
|
434 |
EmphasisForWrittenVariable := anEmphasis |
|
435 |
||
436 |
" |
|
437 |
self emphasisForWrittenVariable:#underline |
|
438 |
self emphasisForWrittenVariable:(Array with:#underline with:#underlineColor->Color red lightened) |
|
439 |
" |
|
6901 | 440 |
! |
441 |
||
442 |
iconForClass:aClass |
|
8851 | 443 |
"now ask the class for its browser symbol; thats a key/selector in the |
444 |
ToolbarIconLibrary" |
|
6901 | 445 |
|
7827 | 446 |
aClass withAllSuperclassesDo:[:eachCls | |
447 |
| iconSymbol | |
|
448 |
||
449 |
iconSymbol := eachCls iconInBrowserSymbol. |
|
450 |
iconSymbol notNil ifTrue:[ |
|
451 |
^ ToolbarIconLibrary perform:iconSymbol |
|
452 |
]. |
|
453 |
]. |
|
454 |
||
6901 | 455 |
^ nil |
456 |
||
457 |
"Created: / 17-08-2006 / 09:11:27 / cg" |
|
7827 | 458 |
"Modified: / 20-07-2007 / 09:01:43 / cg" |
6901 | 459 |
! |
460 |
||
461 |
resourceIconForMethod:aMethod |
|
462 |
|resources| |
|
463 |
||
464 |
(resources := aMethod resources) isNil ifTrue:[^ nil]. |
|
465 |
||
466 |
(resources includesKey:#obsolete) ifTrue:[ |
|
467 |
^ self deprecatedMethodIcon |
|
468 |
]. |
|
469 |
(resources includesKey:#canvas) ifTrue:[ |
|
470 |
^ self canvasIcon |
|
471 |
]. |
|
472 |
(resources includesKey:#menu) ifTrue:[ |
|
473 |
^ self menuIcon |
|
474 |
]. |
|
475 |
(resources includesKey:#image) ifTrue:[ |
|
476 |
^ self imageIcon |
|
477 |
]. |
|
478 |
(resources includesKey:#fileImage) ifTrue:[ |
|
479 |
^ self fileImageIcon |
|
480 |
]. |
|
481 |
(resources includesKey:#programImage) ifTrue:[ |
|
482 |
^ self programImageIcon |
|
483 |
]. |
|
484 |
(resources includesKey:#help) ifTrue:[ |
|
485 |
^ self helpIcon |
|
486 |
]. |
|
487 |
(resources includesKey:#programMenu) ifTrue:[ |
|
488 |
^ self programMenuIcon |
|
489 |
]. |
|
490 |
(resources includesKey:#tableColumns) ifTrue:[ |
|
491 |
^ self tableColumnsIcon |
|
492 |
]. |
|
493 |
(resources includesKey:#tabList) ifTrue:[ |
|
494 |
^ self tabListIcon |
|
495 |
]. |
|
496 |
(resources includesKey:#hierarchicalList) ifTrue:[ |
|
497 |
^ self hierarchicalListIcon |
|
498 |
]. |
|
499 |
(resources includesKey:#programImage) ifTrue:[ |
|
500 |
^ self programImageIcon |
|
501 |
]. |
|
502 |
^ nil |
|
503 |
||
504 |
"Created: / 17-08-2006 / 09:08:11 / cg" |
|
3240
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
505 |
! ! |
34f017469465
allow for some colors to be parametrized (Timos red-green blindness)
Claus Gittinger <cg@exept.de>
parents:
3221
diff
changeset
|
506 |
|
8702 | 507 |
!SystemBrowser class methodsFor:'dialogs'! |
508 |
||
509 |
askForClassNameMatching:matchStringArg inEnvironment:anEnvironmentOrClassOrNil for:aBrowserOrNil |
|
510 |
"open a dialog to ask for a class name. |
|
511 |
env is either a nameSpace or a class (to ask for a private class)" |
|
512 |
||
513 |
|classNames caselessMatchingNames |
|
514 |
substringMatchingNames caselessSubstringMatchingNames |
|
515 |
caselessWithoutPrefixSubstringMatchingNames |
|
516 |
lcMatchString subMatch lcSubMatch box className |
|
517 |
needSearch cls env searchBlock searchBlock2 |
|
518 |
idx pref aMatchString allNames sortedBySpellingDistance msg resources| |
|
519 |
||
520 |
resources := self classResources. |
|
521 |
env := anEnvironmentOrClassOrNil ? Smalltalk. |
|
522 |
||
523 |
aMatchString := matchStringArg. |
|
524 |
||
525 |
"/ try to limit search to a namespace (but only if nameSpace is not a matchCharacter) |
|
526 |
||
527 |
(aMatchString includesString:'::') ifTrue:[ |
|
528 |
"/ pref := aMatchString upTo:$:. |
|
529 |
idx := aMatchString lastIndexOf:$:. |
|
530 |
pref := aMatchString copyTo:idx-2. |
|
531 |
pref includesMatchCharacters ifTrue:[ |
|
532 |
"/ search all in Smalltalk |
|
533 |
] ifFalse:[ |
|
534 |
cls := Smalltalk at:pref asSymbol ifAbsent:nil. |
|
535 |
(cls notNil and:[cls isBehavior]) ifTrue:[ |
|
536 |
env := cls. |
|
537 |
aMatchString := aMatchString copyFrom:pref size + 1 + 2. |
|
538 |
]. |
|
539 |
]. |
|
540 |
]. |
|
541 |
||
542 |
classNames := Set new. |
|
543 |
caselessMatchingNames := Set new. |
|
544 |
substringMatchingNames := Set new. |
|
545 |
caselessSubstringMatchingNames := Set new. |
|
546 |
caselessWithoutPrefixSubstringMatchingNames := Set new. |
|
547 |
||
548 |
lcMatchString := aMatchString asLowercase. |
|
549 |
needSearch := true. |
|
550 |
aMatchString includesMatchCharacters ifFalse:[ |
|
551 |
subMatch := '*' , aMatchString , '*'. |
|
552 |
lcSubMatch := subMatch asLowercase. |
|
553 |
||
554 |
"/ if the name is already a good one, avoid the expensive search |
|
555 |
className := aMatchString asSymbolIfInterned. |
|
556 |
className notNil ifTrue:[ |
|
557 |
env isNameSpace ifTrue:[ |
|
558 |
cls := env at:className ifAbsent:nil. |
|
559 |
] ifFalse:[ |
|
560 |
cls := env privateClassesAt:className. |
|
561 |
]. |
|
562 |
(cls notNil and:[cls isBehavior]) ifTrue:[ |
|
563 |
needSearch := false. |
|
564 |
] |
|
565 |
] |
|
566 |
]. |
|
567 |
||
568 |
needSearch ifTrue:[ |
|
569 |
searchBlock := [:aClass | |
|
570 |
|thisName| |
|
571 |
||
572 |
"/ use dotted names for java |
|
573 |
aClass isJavaClass ifTrue:[ |
|
574 |
thisName := aClass displayString. "/ fullName copyReplaceAll:$/ with:$. |
|
575 |
] ifFalse:[ |
|
576 |
thisName := aClass name |
|
577 |
]. |
|
578 |
(lcMatchString match:aClass name asLowercase) ifTrue:[ |
|
579 |
caselessWithoutPrefixSubstringMatchingNames add:thisName |
|
580 |
]. |
|
581 |
aClass nameWithoutPrefix ~= aClass name ifTrue:[ |
|
582 |
(lcMatchString match:aClass nameWithoutPrefix asLowercase) ifTrue:[ |
|
583 |
caselessWithoutPrefixSubstringMatchingNames add:thisName |
|
584 |
]. |
|
585 |
]. |
|
586 |
||
587 |
(aMatchString match:thisName) ifTrue:[ |
|
588 |
classNames add:thisName |
|
589 |
] ifFalse:[ |
|
590 |
(lcMatchString match:thisName asLowercase) ifTrue:[ |
|
591 |
caselessMatchingNames add:thisName |
|
592 |
] ifFalse:[ |
|
593 |
subMatch notNil ifTrue:[ |
|
594 |
(subMatch match:thisName) ifTrue:[ |
|
595 |
substringMatchingNames add:thisName |
|
596 |
] ifFalse:[ |
|
597 |
(lcSubMatch match:thisName asLowercase) ifTrue:[ |
|
598 |
caselessSubstringMatchingNames add:thisName |
|
599 |
] |
|
600 |
] |
|
601 |
] |
|
602 |
] |
|
603 |
] |
|
604 |
]. |
|
605 |
||
606 |
(env == Smalltalk or:[env isNameSpace]) ifTrue:[ |
|
607 |
env allClassesDo:searchBlock |
|
608 |
] ifFalse:[ |
|
609 |
env allPrivateClasses do:searchBlock |
|
610 |
]. |
|
611 |
||
612 |
sortedBySpellingDistance := false. |
|
613 |
"/ if nothing matched - try caseless matches |
|
614 |
classNames size == 0 ifTrue:[ |
|
615 |
classNames := caselessMatchingNames. |
|
616 |
||
617 |
"/ if nothing matched - try substring matches |
|
618 |
classNames size == 0 ifTrue:[ |
|
8704 | 619 |
aMatchString isUppercaseFirst ifTrue:[ |
8702 | 620 |
classNames := substringMatchingNames. |
621 |
]. |
|
622 |
"/ if nothing matched - try caseless substring matches |
|
623 |
classNames size == 0 ifTrue:[ |
|
624 |
classNames := caselessSubstringMatchingNames. |
|
625 |
||
626 |
"/ if nothing matched - try best fitting |
|
627 |
classNames size == 0 ifTrue:[ |
|
628 |
aMatchString includesMatchCharacters ifFalse:[ |
|
629 |
allNames := SortedCollection sortBlock:[:a :b | a value > b value]. |
|
630 |
searchBlock2 := |
|
631 |
[:aClass | |
|
632 |
|thisName dist| |
|
633 |
||
634 |
aClass isJavaClass ifTrue:[ |
|
635 |
thisName := aClass displayString. "/ fullName copyReplaceAll:$/ with:$. |
|
636 |
] ifFalse:[ |
|
637 |
thisName := aClass name |
|
638 |
]. |
|
639 |
dist := thisName asLowercase spellAgainst:lcMatchString. |
|
640 |
(thisName asLowercase startsWith:lcMatchString) ifTrue:[ |
|
641 |
dist := dist + (thisName size * 10). |
|
642 |
]. |
|
643 |
allNames add:(thisName -> dist). |
|
644 |
]. |
|
645 |
(env == Smalltalk or:[env isNameSpace]) ifTrue:[ |
|
646 |
env allClassesDo:searchBlock2 |
|
647 |
] ifFalse:[ |
|
648 |
env allPrivateClasses do:searchBlock2 |
|
649 |
]. |
|
650 |
classNames := (allNames copyTo:(allNames size min:40)) collect:[:each | each key]. |
|
651 |
sortedBySpellingDistance := true. |
|
652 |
] |
|
653 |
] |
|
654 |
] |
|
655 |
] |
|
656 |
]. |
|
657 |
||
658 |
(classNames size == 0) ifTrue:[^ nil]. |
|
659 |
(classNames size == 1) ifTrue:[ |
|
660 |
className := classNames first |
|
661 |
] ifFalse:[ |
|
662 |
|browseButton| |
|
663 |
||
664 |
sortedBySpellingDistance ifFalse:[ |
|
665 |
classNames := classNames asArray sort. |
|
666 |
]. |
|
667 |
||
668 |
aMatchString includesMatchCharacters ifTrue:[ |
|
9065
efb483eb10a8
changed: #askForClassNameMatching:inEnvironment:for:
Claus Gittinger <cg@exept.de>
parents:
9010
diff
changeset
|
669 |
msg := 'Classes matching or similar to "%1"\\Select or enter name of class to switch to:' |
8702 | 670 |
] ifFalse:[ |
9065
efb483eb10a8
changed: #askForClassNameMatching:inEnvironment:for:
Claus Gittinger <cg@exept.de>
parents:
9010
diff
changeset
|
671 |
msg := 'Classes containing or similar to "%1"\\Select or enter name of class to switch to:' |
8702 | 672 |
]. |
673 |
||
674 |
box := self listBoxTitle:(resources string:msg with:matchStringArg) withCRs |
|
675 |
okText:'OK' |
|
676 |
list:classNames. |
|
677 |
caselessWithoutPrefixSubstringMatchingNames notEmpty ifTrue:[ |
|
678 |
box initialText:(caselessWithoutPrefixSubstringMatchingNames first). |
|
679 |
]. |
|
680 |
box action:[:aString | className := aString]. |
|
681 |
||
682 |
browseButton := Button label:(resources string:'Browse All'). |
|
683 |
browseButton action:[ |
|
684 |
|classes title| |
|
685 |
||
9065
efb483eb10a8
changed: #askForClassNameMatching:inEnvironment:for:
Claus Gittinger <cg@exept.de>
parents:
9010
diff
changeset
|
686 |
title := resources string:'Classes Matching or Similar to "%1"' with:matchStringArg. |
8702 | 687 |
classes := classNames collect:[:nm | Smalltalk classNamed:nm]. |
688 |
aBrowserOrNil isNil ifTrue:[ |
|
689 |
SystemBrowser |
|
690 |
browseClasses:classes |
|
691 |
label:title. |
|
692 |
] ifFalse:[ |
|
693 |
aBrowserOrNil |
|
694 |
spawnClassBrowserFor:classes |
|
695 |
label:title |
|
696 |
in:#newBrowser |
|
697 |
select:false. |
|
698 |
]. |
|
699 |
box hide |
|
700 |
]. |
|
701 |
box addButton:browseButton before:box okButton. |
|
9157
c8166dbf5a5a
changed: #askForClassNameMatching:inEnvironment:for:
Claus Gittinger <cg@exept.de>
parents:
9065
diff
changeset
|
702 |
box minExtent:300@250. |
8702 | 703 |
|
704 |
box open. |
|
705 |
(box accepted not or:[className isNil]) ifTrue:[ "/ cancel |
|
706 |
^ nil |
|
707 |
] |
|
708 |
]. |
|
709 |
]. |
|
710 |
||
711 |
className notNil ifTrue:[ |
|
712 |
"/ use slashed javaName for search. |
|
713 |
(className includes:$.) ifTrue:[ |
|
714 |
className := className copyReplaceAll:$. with:$/ |
|
715 |
]. |
|
716 |
]. |
|
717 |
||
718 |
"/ pref notNil ifTrue:[ |
|
719 |
"/ ^ pref , '::' , className |
|
720 |
"/ ]. |
|
721 |
^ className |
|
722 |
||
723 |
"Modified: / 16-10-2006 / 11:36:20 / cg" |
|
724 |
! |
|
725 |
||
726 |
listBoxTitle:title okText:okText list:aList |
|
727 |
"convenient method: setup a listBox & return it" |
|
728 |
||
729 |
|box resources| |
|
730 |
||
731 |
resources := self classResources. |
|
732 |
||
733 |
box := ListSelectionBox |
|
734 |
title:(resources string:title) |
|
735 |
okText:(resources string:okText) |
|
736 |
action:nil. |
|
737 |
box list:aList. |
|
738 |
^ box |
|
739 |
! ! |
|
740 |
||
2692 | 741 |
!SystemBrowser class methodsFor:'image specs'! |
742 |
||
2748 | 743 |
abstractMethodIcon |
744 |
<resource: #programImage> |
|
745 |
||
746 |
^ self padLockGrayMiniIcon |
|
747 |
! |
|
748 |
||
3813 | 749 |
addBreakPointIcon |
750 |
"This resource specification was automatically generated |
|
751 |
by the ImageEditor of ST/X." |
|
752 |
||
753 |
"Do not manually edit this!! If it is corrupted, |
|
754 |
the ImageEditor may not be able to read the specification." |
|
755 |
||
756 |
" |
|
757 |
self addBreakPointIcon inspect |
|
758 |
ImageEditor openOnClass:self andSelector:#addBreakPointIcon |
|
4852 | 759 |
Icon flushCachedIcons |
3813 | 760 |
" |
761 |
||
762 |
<resource: #image> |
|
763 |
||
764 |
^Icon |
|
7968 | 765 |
constantNamed:'SystemBrowser class addBreakPointIcon' |
3813 | 766 |
ifAbsentPut:[(Depth1Image new) width: 16; height: 16; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@8@C @N@@8@A@@@@@P@C @D@@@@@@@@@@@@b') ; colorMapFromArray:#[255 0 0 255 255 255]; mask:((Depth1Image new) width: 16; height: 16; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@O8A?0O?!!??G?<_?1??G?<_?1??C?8G?@O8@@@@@@b') ; yourself); yourself] |
767 |
! |
|
768 |
||
769 |
addBreakPointIcon2 |
|
6115 | 770 |
^ XPToolbarIconLibrary addBreakPointIcon2 |
3813 | 771 |
! |
772 |
||
4341 | 773 |
autoloadedClassIcon |
7827 | 774 |
<resource: #programImage> |
775 |
||
776 |
^ ToolbarIconLibrary autoloadedClassBrowserIcon |
|
777 |
||
778 |
"Modified: / 20-07-2007 / 09:15:37 / cg" |
|
4341 | 779 |
! |
780 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
781 |
canvasIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
782 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
783 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
784 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
785 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
786 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
787 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
788 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
789 |
ImageEditor openOnClass:self andSelector:#canvasIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
790 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
791 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
792 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
793 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
794 |
^Icon |
7968 | 795 |
constantNamed:'SystemBrowser class canvasIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
796 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@.;.;.;.0@@@@@@@@@@C.;/C.;/@@9&XP9&XP@NY&DNY&D@C&Y!!C&Y!!@@9&XP9&XP@NY&DNY&D@C1DQC1DQ@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 255 0 0 0 255 0 0 0 255 0 255 255 255 255 0 255 0 255 127 0 0 0 127 0 0 0 127 0 127 127 127 127 0 127 0 127 127 127 127 170 170 170]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
797 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
798 |
|
4143 | 799 |
containerClassIcon |
7827 | 800 |
<resource: #programImage> |
801 |
||
802 |
^ ToolbarIconLibrary containerClassBrowserIcon |
|
803 |
||
804 |
"Modified: / 20-07-2007 / 09:14:54 / cg" |
|
4143 | 805 |
! |
806 |
||
2692 | 807 |
defaultIcon |
808 |
"This resource specification was automatically generated |
|
809 |
by the ImageEditor of ST/X." |
|
810 |
||
811 |
"Do not manually edit this!! If it is corrupted, |
|
812 |
the ImageEditor may not be able to read the specification." |
|
813 |
||
814 |
" |
|
815 |
self defaultIcon inspect |
|
816 |
ImageEditor openOnClass:self andSelector:#defaultIcon |
|
817 |
" |
|
818 |
||
819 |
<resource: #image> |
|
820 |
||
821 |
^Icon |
|
7968 | 822 |
constantNamed:'SystemBrowser class defaultIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
823 |
ifAbsentPut:[(Depth4Image new) width: 28; height: 28; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
824 |
@@@@@@@@@@@@@@@@@@@FY&Y&Y&X0@@@@@@@@@@YDQDQDQB@@@@@@@@@@A$QDQDQDH@@@@@@@@@@CH"H"H"H @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H@@@ |
3794 | 825 |
@@@@@@@@@@@@@@@ @@@@@@@@@@@@@@@@@B@@@@@@@@@@@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@A&Y&Y&Y#@@@@@F@"H"HFDQDQDQH@@@@@@@@@@@L"H"H" |
826 |
H @@@@@ @@@@@@@@@@@@@@@@@B@@@@@@@@@@@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@A&Y&Y&Y#@@@@@F@"H"HFUUUUUUH@@@@@@@@@@@L"H"H"H @@@@@@ |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
827 |
@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@H@@@@B@B@ @@H@@@@ @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
828 |
@@@@@@@@@@@@@@@@@@@@@@@@H@@@@@@@@@H@@ @@@@Hb') ; colorMapFromArray:#[0 0 0 0 255 0 127 127 127 170 170 170 255 0 0 255 255 0 255 255 255]; mask:((Depth1Image new) width: 28; height: 28; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' |
3794 | 829 |
??0@@O?<@@C??@@@??0@@O?<@@C??@@@@ @@@@H@@@@B@@@@@ O?8@\C?>@G??? A0O?8@HC?>@B@@@@@ O?8@\C?>@G??? A0O?8@@C?>@@@@@@9O\7\IRT |
2846 | 830 |
QDBD%DQ@!!OH''HHRQEABT$QPP99]7\@@a') ; yourself); yourself] |
831 |
! |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
832 |
|
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
833 |
deprecatedMethodIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
834 |
^ self doNotEnterIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
835 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
836 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
837 |
doNotEnterIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
838 |
"This resource specification was automatically generated |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
839 |
by the ImageEditor of ST/X." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
840 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
841 |
"Do not manually edit this!! If it is corrupted, |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
842 |
the ImageEditor may not be able to read the specification." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
843 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
844 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
845 |
self doNotEnterIcon inspect |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
846 |
ImageEditor openOnClass:self andSelector:#doNotEnterIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
847 |
Icon flushCachedIcons |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
848 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
849 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
850 |
<resource: #image> |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
851 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
852 |
^Icon |
7968 | 853 |
constantNamed:'SystemBrowser class doNotEnterIcon' |
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
854 |
ifAbsentPut:[(Depth1Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(1)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??C0<NA00CB@EY>P''9B@DL@08GC0<@@a') ; colorMapFromArray:#[255 0 0 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@O@A>@O<A?8G? _>A?8C?@G8@O@@@a') ; yourself); yourself] |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
855 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
856 |
|
3354 | 857 |
emptyIcon |
858 |
"This resource specification was automatically generated |
|
859 |
by the ImageEditor of ST/X." |
|
860 |
||
861 |
"Do not manually edit this!! If it is corrupted, |
|
862 |
the ImageEditor may not be able to read the specification." |
|
863 |
||
864 |
" |
|
865 |
self emptyIcon inspect |
|
866 |
ImageEditor openOnClass:self andSelector:#emptyIcon |
|
867 |
" |
|
868 |
||
869 |
<resource: #image> |
|
870 |
||
871 |
^Icon |
|
7968 | 872 |
constantNamed:'SystemBrowser class emptyIcon' |
3354 | 873 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself] |
874 |
||
875 |
"Created: / 5.11.2001 / 09:39:54 / cg" |
|
876 |
! |
|
877 |
||
4143 | 878 |
errorClassIcon |
7827 | 879 |
<resource: #programImage> |
880 |
||
881 |
^ ToolbarIconLibrary errorClassBrowserIcon |
|
882 |
||
883 |
"Modified: / 20-07-2007 / 09:14:06 / cg" |
|
4143 | 884 |
! |
885 |
||
886 |
exceptionClassIcon |
|
887 |
"This resource specification was automatically generated |
|
888 |
by the ImageEditor of ST/X." |
|
889 |
||
890 |
"Do not manually edit this!! If it is corrupted, |
|
891 |
the ImageEditor may not be able to read the specification." |
|
892 |
||
893 |
" |
|
894 |
self exceptionClassIcon inspect |
|
895 |
ImageEditor openOnClass:self andSelector:#exceptionClassIcon |
|
896 |
Icon flushCachedIcons |
|
897 |
" |
|
898 |
||
7827 | 899 |
<resource: #programImage> |
900 |
||
901 |
^ ToolbarIconLibrary exceptionClassBrowserIcon |
|
902 |
||
903 |
"Modified: / 20-07-2007 / 09:13:18 / cg" |
|
4143 | 904 |
! |
905 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
906 |
fileImageIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
907 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
908 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
909 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
910 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
911 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
912 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
913 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
914 |
self fileImageIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
915 |
ImageEditor openOnClass:self andSelector:#fileImageIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
916 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
917 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
918 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
919 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
920 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
921 |
constantNamed:'SystemBrowser class fileImageIcon' |
2846 | 922 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@H"H"H"@@@BQBH!!D"@@@$P"HQH"@@H"H"DQH @BH"HQDRH@@"H"DQH"@@L3L3DSL0@CL3L1D3L@@3L3L3L3@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 51 153 153 51 255 255 255 153 0 255 255 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'?<C?8O?0??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
923 |
! |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
924 |
|
4166 | 925 |
greenCheckIcon |
926 |
"This resource specification was automatically generated |
|
927 |
by the ImageEditor of ST/X." |
|
928 |
||
929 |
"Do not manually edit this!! If it is corrupted, |
|
930 |
the ImageEditor may not be able to read the specification." |
|
931 |
||
932 |
" |
|
933 |
self greenCheckIcon inspect |
|
934 |
ImageEditor openOnClass:self andSelector:#greenCheckIcon |
|
935 |
Icon flushCachedIcons |
|
936 |
" |
|
937 |
||
938 |
<resource: #image> |
|
939 |
||
940 |
^Icon |
|
7968 | 941 |
constantNamed:'SystemBrowser class greenCheckIcon' |
4166 | 942 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@H @@@@@@@"@@@@@@@@H@@@@@@ @"@@@@@@H H@@@@@@@H"@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 0 127 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@C@@X@A@AL@F @N@@P@@@@@@@@a') ; yourself); yourself] |
943 |
! |
|
944 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
945 |
greenLockIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
946 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
947 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
948 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
949 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
950 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
951 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
952 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
953 |
self greenLockIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
954 |
ImageEditor openOnClass:self andSelector:#greenLockIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
955 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
956 |
|
3354 | 957 |
<resource: #programImage> |
958 |
||
2892 | 959 |
^ self padLockGreenMiniIcon |
3354 | 960 |
|
961 |
"Modified: / 5.11.2001 / 09:40:12 / cg" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
962 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
963 |
|
4165 | 964 |
greenThumbUpIcon |
965 |
"This resource specification was automatically generated |
|
966 |
by the ImageEditor of ST/X." |
|
967 |
||
968 |
"Do not manually edit this!! If it is corrupted, |
|
969 |
the ImageEditor may not be able to read the specification." |
|
970 |
||
971 |
" |
|
972 |
self greenThumbUpIcon inspect |
|
973 |
ImageEditor openOnClass:self andSelector:#greenThumbUpIcon |
|
974 |
Icon flushCachedIcons |
|
975 |
" |
|
976 |
||
977 |
<resource: #image> |
|
978 |
||
979 |
^Icon |
|
7968 | 980 |
constantNamed:'SystemBrowser class greenThumbUpIcon' |
4165 | 981 |
ifAbsentPut:[(Depth4Image new) width: 15; height: 15; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' |
982 |
@@@@@@@@@@@@A)<@@@@@@@@G( @@@@@@@@^/@@@@@@@@A9@@@@@@@@C)$@@@@@@@A)+<>]BM]0BZ(->&E''3&@I**J&DN];@@VZ*''G^DV] C%&Y8AY7,@@MQU |
|
983 |
P]8QY6@@@MSPE''XP@@@@@CL0!!''X@@@@@@@@@@@@@') ; colorMapFromArray:#[0 0 0 0 64 0 77 242 77 0 128 0 0 160 32 8 215 50 50 173 50 45 210 45 0 32 0 40 247 40 77 242 118 0 64 32 22 105 22 18 141 18 13 178 13 45 210 86]; mask:((ImageMask new) width: 15; height: 15; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'G@@>@C8@O @<@G?<??;??/?>??;??O?<?? ?>@?0') ; yourself); yourself] |
|
984 |
! |
|
985 |
||
4166 | 986 |
greenThumbUpSmallIcon |
987 |
"This resource specification was automatically generated |
|
988 |
by the ImageEditor of ST/X." |
|
989 |
||
990 |
"Do not manually edit this!! If it is corrupted, |
|
991 |
the ImageEditor may not be able to read the specification." |
|
992 |
||
993 |
" |
|
994 |
self greenThumbUpSmallIcon inspect |
|
995 |
ImageEditor openOnClass:self andSelector:#greenThumbUpSmallIcon |
|
996 |
Icon flushCachedIcons |
|
997 |
" |
|
998 |
||
999 |
<resource: #image> |
|
1000 |
||
1001 |
^Icon |
|
7968 | 1002 |
constantNamed:'SystemBrowser class greenThumbUpSmallIcon' |
4166 | 1003 |
ifAbsentPut:[(Depth2Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@P@@@@D@@@@A@@L@@P@B@@U*@@@UZ@@@UV @@EV @@@@@@B@@@@B@b') ; colorMapFromArray:#[0 0 0 0 255 0 0 127 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'C@@N@@8@C @_8A?0O?@?8C?@O8@@@@@a') ; yourself); yourself] |
1004 |
! |
|
1005 |
||
1006 |
greyCheckIcon |
|
1007 |
"This resource specification was automatically generated |
|
1008 |
by the ImageEditor of ST/X." |
|
1009 |
||
1010 |
"Do not manually edit this!! If it is corrupted, |
|
1011 |
the ImageEditor may not be able to read the specification." |
|
1012 |
||
1013 |
" |
|
1014 |
self greyCheckIcon inspect |
|
1015 |
ImageEditor openOnClass:self andSelector:#greyCheckIcon |
|
1016 |
Icon flushCachedIcons |
|
1017 |
" |
|
1018 |
||
1019 |
<resource: #image> |
|
1020 |
||
1021 |
^Icon |
|
7968 | 1022 |
constantNamed:'SystemBrowser class greyCheckIcon' |
4166 | 1023 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@H @@@@@@@"@@@@@@@@H@@@@@@ @"@@@@@@H H@@@@@@@H"@@@@@@@@H@@@@@@@@@@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 127 127 127]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@C@@X@A@AL@F @N@@P@@@@@@@@a') ; yourself); yourself] |
1024 |
! |
|
1025 |
||
4165 | 1026 |
greyThumbUpIcon |
1027 |
"This resource specification was automatically generated |
|
1028 |
by the ImageEditor of ST/X." |
|
1029 |
||
1030 |
"Do not manually edit this!! If it is corrupted, |
|
1031 |
the ImageEditor may not be able to read the specification." |
|
1032 |
||
1033 |
" |
|
1034 |
self greyThumbUpIcon inspect |
|
1035 |
ImageEditor openOnClass:self andSelector:#greyThumbUpIcon |
|
1036 |
Icon flushCachedIcons |
|
1037 |
" |
|
1038 |
||
1039 |
<resource: #image> |
|
1040 |
||
1041 |
^Icon |
|
7968 | 1042 |
constantNamed:'SystemBrowser class greyThumbUpIcon' |
4165 | 1043 |
ifAbsentPut:[(Depth4Image new) width: 15; height: 15; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' |
1044 |
@@@@@@@@@@ @@4\@@@@@@@@GE@@@@@@@@@\W@@@@@@@@A4@@@@@@@@@4P@@@@@@H@4E2]FAV]0AAEF\SH7X3@DDQPSHC]2@@]ADWI#H#\0@7]7LBM7H@@FY7 |
|
1045 |
YVL"M3@@@FY T7L @@@@@BH T7L@@@@@@@@@@@@@') ; colorMapFromArray:#[0 0 0 224 224 224 64 64 64 128 128 128 192 192 192 32 32 32 96 96 96 160 160 160]; mask:((ImageMask new) width: 15; height: 15; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'G@@>@C8@O @<@G?<??;??/?>??;??O?<?? ?>@?0') ; yourself); yourself] |
|
1046 |
! |
|
1047 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1048 |
helpIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1049 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1050 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1051 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1052 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1053 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1054 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1055 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1056 |
self helpIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1057 |
ImageEditor openOnClass:self andSelector:#helpIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1058 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1059 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1060 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1061 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1062 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1063 |
constantNamed:'SystemBrowser class helpIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1064 |
ifAbsentPut:[(Depth1Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@A?<G#0]7A?\G;0__A?<G72_?@@@@@a') ; colorMapFromArray:#[0 0 0 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1065 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1066 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1067 |
hierarchicalListIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1068 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1069 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1070 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1071 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1072 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1073 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1074 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1075 |
ImageEditor openOnClass:self andSelector:#hierarchicalListIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1076 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1077 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1078 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1079 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1080 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1081 |
constantNamed:'SystemBrowser class hierarchicalListIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1082 |
ifAbsentPut:[(Depth2Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@NAUUU0@R??8@GO?>@A0@C @\??88G@@N@A3?? @^@@8@N***@@@@@C b') ; colorMapFromArray:#[0 0 0 255 255 255 127 127 127 170 170 170]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1083 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1084 |
|
5997 | 1085 |
ignoredMethodIcon |
1086 |
<resource: #programImage> |
|
1087 |
||
1088 |
^ self padLockBlackMiniIcon |
|
1089 |
! |
|
1090 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1091 |
imageIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1092 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1093 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1094 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1095 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1096 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1097 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1098 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1099 |
self imageIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1100 |
ImageEditor openOnClass:self andSelector:#imageIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1101 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1102 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1103 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1104 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1105 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1106 |
constantNamed:'SystemBrowser class imageIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1107 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@H"H"H"H @BQBH!!D"H@@$P"HQH"@@H"H"DQH @BH"HQDRH@@"H"DQH"@@L3L3DSL0@CL3L1D3L@@3L3L3L3@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 51 153 153 51 255 255 255 153 0 255 255 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1108 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1109 |
|
7992 | 1110 |
instrumentationIcon |
1111 |
<resource: #programImage> |
|
1112 |
||
1113 |
^ ToolbarIconLibrary pipette16x16Icon |
|
1114 |
! |
|
1115 |
||
3675 | 1116 |
medium_methodEmptyInheritedIcon |
1117 |
"This resource specification was automatically generated |
|
1118 |
by the ImageEditor of ST/X." |
|
1119 |
||
1120 |
"Do not manually edit this!! If it is corrupted, |
|
1121 |
the ImageEditor may not be able to read the specification." |
|
1122 |
||
1123 |
" |
|
1124 |
self medium_methodEmptyInheritedIcon inspect |
|
1125 |
ImageEditor openOnClass:self andSelector:#medium_methodEmptyInheritedIcon |
|
1126 |
" |
|
1127 |
||
1128 |
<resource: #image> |
|
1129 |
||
1130 |
^Icon |
|
7968 | 1131 |
constantNamed:'SystemBrowser class medium_methodEmptyInheritedIcon' |
3675 | 1132 |
ifAbsentPut:[(Depth4Image new) width: 9; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; colorMapFromArray:#[0 0 0]; mask:((Depth1Image new) width: 9; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@a') ; yourself); yourself] |
1133 |
! |
|
1134 |
||
1135 |
medium_methodInheritedFromAboveAndRedefinedBelowIcon |
|
1136 |
"This resource specification was automatically generated |
|
1137 |
by the ImageEditor of ST/X." |
|
1138 |
||
1139 |
"Do not manually edit this!! If it is corrupted, |
|
1140 |
the ImageEditor may not be able to read the specification." |
|
1141 |
||
1142 |
" |
|
1143 |
self medium_methodInheritedFromAboveAndRedefinedBelowIcon inspect |
|
1144 |
ImageEditor openOnClass:self andSelector:#medium_methodInheritedFromAboveAndRedefinedBelowIcon |
|
4130 | 1145 |
Icon flushCachedIcons |
3675 | 1146 |
" |
1147 |
||
1148 |
<resource: #image> |
|
1149 |
||
1150 |
^Icon |
|
7968 | 1151 |
constantNamed:'SystemBrowser class medium_methodInheritedFromAboveAndRedefinedBelowIcon' |
4130 | 1152 |
ifAbsentPut:[(Depth2Image new) width: 9; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@B()@B(@A@ @A@ @A@ (EP@HEP@@@@@@@@@@') ; colorMapFromArray:#[0 0 0 255 255 127 255 127 127]; mask:((Depth1Image new) width: 9; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@/ B>@K8A7@G\@]0C:@O(@> @@@@@a') ; yourself); yourself] |
3675 | 1153 |
! |
1154 |
||
1155 |
medium_methodInheritedFromAboveIcon |
|
1156 |
"This resource specification was automatically generated |
|
1157 |
by the ImageEditor of ST/X." |
|
1158 |
||
1159 |
"Do not manually edit this!! If it is corrupted, |
|
1160 |
the ImageEditor may not be able to read the specification." |
|
1161 |
||
1162 |
" |
|
1163 |
self medium_methodInheritedFromAboveIcon inspect |
|
1164 |
ImageEditor openOnClass:self andSelector:#medium_methodInheritedFromAboveIcon |
|
4130 | 1165 |
Icon flushCachedIcons |
3675 | 1166 |
" |
1167 |
||
1168 |
<resource: #image> |
|
1169 |
||
1170 |
^Icon |
|
7968 | 1171 |
constantNamed:'SystemBrowser class medium_methodInheritedFromAboveIcon' |
4130 | 1172 |
ifAbsentPut:[(Depth1Image new) width: 9; height: 11; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@A@@@ @B@@HA=0LG@@@@@@@@@a') ; colorMapFromArray:#[0 0 0 255 255 127]; mask:((Depth1Image new) width: 9; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@ @B@@H@A0@G@@\@C8@O @>@@@@@@a') ; yourself); yourself] |
3675 | 1173 |
! |
1174 |
||
1175 |
medium_methodRedefinedBelowIcon |
|
1176 |
"This resource specification was automatically generated |
|
1177 |
by the ImageEditor of ST/X." |
|
1178 |
||
1179 |
"Do not manually edit this!! If it is corrupted, |
|
1180 |
the ImageEditor may not be able to read the specification." |
|
1181 |
||
1182 |
" |
|
1183 |
self medium_methodRedefinedBelowIcon inspect |
|
1184 |
ImageEditor openOnClass:self andSelector:#medium_methodRedefinedBelowIcon |
|
4130 | 1185 |
Icon flushCachedIcons |
3675 | 1186 |
" |
1187 |
||
1188 |
<resource: #image> |
|
1189 |
||
1190 |
^Icon |
|
7968 | 1191 |
constantNamed:'SystemBrowser class medium_methodRedefinedBelowIcon' |
4130 | 1192 |
ifAbsentPut:[(Depth1Image new) width: 9; height: 11; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@ED@L@\@A0@B@@H@@"8@P@@@@@@@@@@a') ; colorMapFromArray:#[0 0 0 255 127 127]; mask:((Depth1Image new) width: 9; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@O @>@C8@G@@\@A0@B@@H@@ @@@@@a') ; yourself); yourself] |
3675 | 1193 |
! |
1194 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1195 |
menuIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1196 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1197 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1198 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1199 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1200 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1201 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1202 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1203 |
self menuIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1204 |
ImageEditor openOnClass:self andSelector:#menuIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1205 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1206 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1207 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1208 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1209 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1210 |
constantNamed:'SystemBrowser class menuIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1211 |
ifAbsentPut:[(Depth2Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@B***P@%UUT@@@@@@B***P@%UUT@@@@@@B***P@%UUT@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 170 170 170 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8?? @@@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1212 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1213 |
|
3675 | 1214 |
methodEmptyInheritedIcon |
1215 |
^ self small_methodEmptyInheritedIcon |
|
1216 |
! |
|
1217 |
||
1218 |
methodInheritedFromAboveAndRedefinedBelowIcon |
|
1219 |
^ self small_methodInheritedFromAboveAndRedefinedBelowIcon |
|
1220 |
! |
|
1221 |
||
1222 |
methodInheritedFromAboveIcon |
|
1223 |
^ self small_methodInheritedFromAboveIcon |
|
1224 |
! |
|
1225 |
||
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1226 |
methodIsSubclassResponsibilityAndRedefinedBelowIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1227 |
"This resource specification was automatically generated |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1228 |
by the ImageEditor of ST/X." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1229 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1230 |
"Do not manually edit this!! If it is corrupted, |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1231 |
the ImageEditor may not be able to read the specification." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1232 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1233 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1234 |
self methodIsSubclassResponsibilityAndRedefinedBelowIcon inspect |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1235 |
ImageEditor openOnClass:self andSelector:#methodIsSubclassResponsibilityAndRedefinedBelowIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1236 |
Icon flushCachedIcons |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1237 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1238 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1239 |
<resource: #image> |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1240 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1241 |
^Icon |
7968 | 1242 |
constantNamed:'SystemBrowser class methodIsSubclassResponsibilityAndRedefinedBelowIcon' |
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1243 |
ifAbsentPut:[(Depth2Image new) width: 5; height: 11; photometric:(#palette); bitsPerSample:(#(2)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' @D@@H@@@@@B@@@@@@4UBHR@A@@"@@@a') ; colorMapFromArray:#[0 0 0 255 127 127 127 127 127]; mask:((Depth1Image new) width: 5; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'<HC DO@@>O#8\G@b') ; yourself); yourself] |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1244 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1245 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1246 |
methodIsSubclassResponsibilityIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1247 |
"This resource specification was automatically generated |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1248 |
by the ImageEditor of ST/X." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1249 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1250 |
"Do not manually edit this!! If it is corrupted, |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1251 |
the ImageEditor may not be able to read the specification." |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1252 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1253 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1254 |
self methodIsSubclassResponsibilityIcon inspect |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1255 |
ImageEditor openOnClass:self andSelector:#methodIsSubclassResponsibilityIcon |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1256 |
Icon flushCachedIcons |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1257 |
" |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1258 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1259 |
<resource: #image> |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1260 |
|
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1261 |
^Icon |
7968 | 1262 |
constantNamed:'SystemBrowser class methodIsSubclassResponsibilityIcon' |
5761
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1263 |
ifAbsentPut:[(Depth2Image new) width: 5; height: 11; photometric:(#palette); bitsPerSample:(#(2)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' @D@@H@@@@@B@@@@@ 4@B@H@@@@@@@@a') ; colorMapFromArray:#[0 0 0 255 127 127 127 127 127]; mask:((Depth1Image new) width: 5; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1)); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'<HC DO@@<IC0(I@b') ; yourself); yourself] |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1264 |
! |
b350e042dc9f
Icons for subclassResponsibility and deprecated methods
Stefan Vogel <sv@exept.de>
parents:
5546
diff
changeset
|
1265 |
|
3675 | 1266 |
methodRedefinedBelowIcon |
1267 |
^ self small_methodRedefinedBelowIcon |
|
1268 |
! |
|
1269 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1270 |
nameSpaceIcon |
7827 | 1271 |
<resource: #programImage> |
1272 |
||
1273 |
^ ToolbarIconLibrary nameSpaceBrowserIcon |
|
1274 |
||
1275 |
"Modified: / 20-07-2007 / 09:12:26 / cg" |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1276 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1277 |
|
4308 | 1278 |
notificationClassIcon |
7827 | 1279 |
<resource: #programImage> |
1280 |
||
1281 |
^ ToolbarIconLibrary notificationClassBrowserIcon |
|
1282 |
||
1283 |
"Modified: / 20-07-2007 / 09:11:21 / cg" |
|
4308 | 1284 |
! |
1285 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1286 |
packageIcon |
8853 | 1287 |
<resource: #programImage> |
1288 |
||
1289 |
^ ToolbarIconLibrary smallYellowPackageIcon |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1290 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1291 |
|
6954 | 1292 |
packageIconGraySmall |
8853 | 1293 |
<resource: #programImage> |
1294 |
||
1295 |
^ ToolbarIconLibrary smallGrayPackageIcon |
|
6954 | 1296 |
! |
1297 |
||
6925 | 1298 |
packageIconGreenSmall |
8853 | 1299 |
<resource: #programImage> |
1300 |
||
1301 |
^ ToolbarIconLibrary smallGreenPackageIcon |
|
6925 | 1302 |
! |
1303 |
||
1304 |
packageIconOrangeSmall |
|
8853 | 1305 |
<resource: #programImage> |
1306 |
||
1307 |
^ ToolbarIconLibrary smallOrangePackageIcon |
|
6925 | 1308 |
! |
1309 |
||
6901 | 1310 |
packageIconSmall |
8853 | 1311 |
<resource: #programImage> |
1312 |
||
1313 |
^ ToolbarIconLibrary smallYellowPackageIcon |
|
6901 | 1314 |
! |
1315 |
||
5997 | 1316 |
padLockBlackMiniIcon |
6333 | 1317 |
<resource: #programImage> |
1318 |
||
1319 |
^ XPToolbarIconLibrary padLockBlackMiniIcon |
|
5997 | 1320 |
! |
1321 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1322 |
padLockBlueMiniIcon |
6333 | 1323 |
<resource: #programImage> |
1324 |
||
1325 |
^ XPToolbarIconLibrary padLockBlueMiniIcon |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1326 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1327 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1328 |
padLockGrayMiniIcon |
6333 | 1329 |
<resource: #programImage> |
1330 |
||
1331 |
^ GenericToolbarIconLibrary padLockGrayMiniIcon |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1332 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1333 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1334 |
padLockGreenMiniIcon |
6333 | 1335 |
<resource: #programImage> |
1336 |
||
1337 |
^ GenericToolbarIconLibrary padLockGreenMiniIcon |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1338 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1339 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1340 |
padLockRedMiniIcon |
6333 | 1341 |
<resource: #programImage> |
1342 |
||
1343 |
^ GenericToolbarIconLibrary padLockRedMiniIcon |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1344 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1345 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1346 |
privateMethodIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1347 |
<resource: #programImage> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1348 |
|
2748 | 1349 |
^ self padLockRedMiniIcon |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1350 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1351 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1352 |
programImageIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1353 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1354 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1355 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1356 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1357 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1358 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1359 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1360 |
self programImageIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1361 |
ImageEditor openOnClass:self andSelector:#programImageIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1362 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1363 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1364 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1365 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1366 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1367 |
constantNamed:#'SystemBrowser class programImageIcon' |
2846 | 1368 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@H"H"H"H @BQBH!!D"H@@$P"HQH"@@H"H"DQH @BH"HQDRH@@"H"DQH"@@L3L3DSL0@CL3L1D3L@@3L3L3L3@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 25 77 77 51 255 255 128 128 0 128 77 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
1369 |
! |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1370 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1371 |
programMenuIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1372 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1373 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1374 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1375 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1376 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1377 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1378 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1379 |
self programMenuIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1380 |
ImageEditor openOnClass:self andSelector:#programMenuIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1381 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1382 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1383 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1384 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1385 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1386 |
constantNamed:#'SystemBrowser class programMenuIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1387 |
ifAbsentPut:[(Depth1Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@A?<G?0@@A?<G?0@@A?<G?3@@@@@@@a') ; colorMapFromArray:#[0 0 0 170 170 170]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8?? @@@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1388 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1389 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1390 |
protectedMethodIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1391 |
<resource: #programImage> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1392 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1393 |
^ self padLockGreenMiniIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1394 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1395 |
|
4308 | 1396 |
queryClassIcon |
7827 | 1397 |
<resource: #programImage> |
1398 |
||
1399 |
^ ToolbarIconLibrary queryClassBrowserIcon |
|
1400 |
||
1401 |
"Modified: / 20-07-2007 / 09:10:32 / cg" |
|
4308 | 1402 |
! |
1403 |
||
4166 | 1404 |
redCheckIcon |
1405 |
"This resource specification was automatically generated |
|
1406 |
by the ImageEditor of ST/X." |
|
1407 |
||
1408 |
"Do not manually edit this!! If it is corrupted, |
|
1409 |
the ImageEditor may not be able to read the specification." |
|
1410 |
||
1411 |
" |
|
1412 |
self redCheckIcon inspect |
|
1413 |
ImageEditor openOnClass:self andSelector:#redCheckIcon |
|
1414 |
Icon flushCachedIcons |
|
1415 |
" |
|
1416 |
||
1417 |
<resource: #image> |
|
1418 |
||
1419 |
^Icon |
|
1420 |
constantNamed:#'SystemBrowser class redCheckIcon' |
|
1421 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@"@@@@@@@BH@@@@ @@H @@@BH @"@@@@@BH"H @@@@@BH"@@@@@@@BH @@@@@@@B@@@@@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 255 0 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@A @L@!! GL@O0@^@@8@A@@@@@@a') ; yourself); yourself] |
|
1422 |
! |
|
1423 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1424 |
redLockIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1425 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1426 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1427 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1428 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1429 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1430 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1431 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1432 |
self redLockIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1433 |
ImageEditor openOnClass:self andSelector:#redLockIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1434 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1435 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1436 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1437 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1438 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1439 |
constantNamed:#'SystemBrowser class redLockIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1440 |
ifAbsentPut:[(Depth2Image new) width: 9; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@T@@AA@@AA@@EUP@EUP@EQP@EQP@EQP@EAP@AU@@@@@@') ; colorMapFromArray:#[0 0 0 255 0 0]; mask:((Depth1Image new) width: 9; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'F@@$@BP@_ A>@G8@_ A>@G8@O@@@@@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1441 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1442 |
|
4165 | 1443 |
redThumbDownIcon |
1444 |
"This resource specification was automatically generated |
|
1445 |
by the ImageEditor of ST/X." |
|
1446 |
||
1447 |
"Do not manually edit this!! If it is corrupted, |
|
1448 |
the ImageEditor may not be able to read the specification." |
|
1449 |
||
1450 |
" |
|
1451 |
self redThumbDownIcon inspect |
|
1452 |
ImageEditor openOnClass:self andSelector:#redThumbDownIcon |
|
1453 |
Icon flushCachedIcons |
|
1454 |
" |
|
1455 |
||
1456 |
<resource: #image> |
|
1457 |
||
1458 |
^Icon |
|
1459 |
constantNamed:#'SystemBrowser class redThumbDownIcon' |
|
1460 |
ifAbsentPut:[(Depth4Image new) width: 15; height: 15; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:' |
|
1461 |
@@@@@@@@@@@@@L3@!!;\@@@C6<J^7(@@H=-5*<Z);\@@]UUDJ^;(@@MH3N:<Z);\@H3MC^ F;(@@#MO$7);8WB@\#'')K0#;,@@AH @@@@@@@@B2@@@@@@@@@K |
|
1462 |
NP@@@@@L@@,4@@@@@@T@A2$@@@@@@@@@@@@@@@@@') ; colorMapFromArray:#[0 0 0 191 20 1 255 44 33 255 131 65 255 84 65 255 88 33 160 40 0 184 67 40 32 27 0 223 99 33 64 22 0 223 52 33 128 13 0 224 56 0 112 16 31 152 35 8]; mask:((ImageMask new) width: 15; height: 15; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'C?@?>O?8??3??O?>??;??/?>_?0<@C8@O @>@A0@') ; yourself); yourself] |
|
1463 |
! |
|
1464 |
||
4166 | 1465 |
redThumbDownSmallIcon |
1466 |
"This resource specification was automatically generated |
|
1467 |
by the ImageEditor of ST/X." |
|
1468 |
||
1469 |
"Do not manually edit this!! If it is corrupted, |
|
1470 |
the ImageEditor may not be able to read the specification." |
|
1471 |
||
1472 |
" |
|
1473 |
self redThumbDownSmallIcon inspect |
|
1474 |
ImageEditor openOnClass:self andSelector:#redThumbDownSmallIcon |
|
1475 |
Icon flushCachedIcons |
|
1476 |
" |
|
1477 |
||
1478 |
<resource: #image> |
|
1479 |
||
1480 |
^Icon |
|
1481 |
constantNamed:#'SystemBrowser class redThumbDownSmallIcon' |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
1482 |
ifAbsentPut:[(Depth2Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@B@@@@@@EV @@AUZ@@@EV C@@U*@@@A@@@@@P@@@@D@@@@A@@@@@@@@ b') ; colorMapFromArray:#[0 0 0 255 0 0 127 0 0 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@? C?@O>@?<A?0G>@N@@8@C @L@@@a') ; yourself); yourself] |
4166 | 1483 |
! |
1484 |
||
3813 | 1485 |
removeBreakPointIcon2 |
6115 | 1486 |
^ XPToolbarIconLibrary removeBreakPointIcon2 |
3813 | 1487 |
! |
1488 |
||
3675 | 1489 |
small_methodEmptyInheritedIcon |
1490 |
"This resource specification was automatically generated |
|
1491 |
by the ImageEditor of ST/X." |
|
1492 |
||
1493 |
"Do not manually edit this!! If it is corrupted, |
|
1494 |
the ImageEditor may not be able to read the specification." |
|
1495 |
||
1496 |
" |
|
1497 |
self small_methodEmptyInheritedIcon inspect |
|
1498 |
ImageEditor openOnClass:self andSelector:#small_methodEmptyInheritedIcon |
|
1499 |
" |
|
1500 |
||
1501 |
<resource: #image> |
|
1502 |
||
1503 |
^Icon |
|
1504 |
constantNamed:#'SystemBrowser class small_methodEmptyInheritedIcon' |
|
1505 |
ifAbsentPut:[(Depth4Image new) width: 5; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@') ; colorMapFromArray:#[0 0 0]; mask:((Depth1Image new) width: 5; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@@@@@@b') ; yourself); yourself] |
|
1506 |
! |
|
1507 |
||
1508 |
small_methodInheritedFromAboveAndRedefinedBelowIcon |
|
1509 |
"This resource specification was automatically generated |
|
1510 |
by the ImageEditor of ST/X." |
|
1511 |
||
1512 |
"Do not manually edit this!! If it is corrupted, |
|
1513 |
the ImageEditor may not be able to read the specification." |
|
1514 |
||
1515 |
" |
|
1516 |
self small_methodInheritedFromAboveAndRedefinedBelowIcon inspect |
|
1517 |
ImageEditor openOnClass:self andSelector:#small_methodInheritedFromAboveAndRedefinedBelowIcon |
|
4130 | 1518 |
Icon flushCachedIcons |
3675 | 1519 |
" |
1520 |
||
1521 |
<resource: #image> |
|
1522 |
||
1523 |
^Icon |
|
1524 |
constantNamed:#'SystemBrowser class small_methodInheritedFromAboveAndRedefinedBelowIcon' |
|
4130 | 1525 |
ifAbsentPut:[(Depth2Image new) width: 5; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'L1@DLLS,ES@@@@@0@@@*@L#@B@@3@@@a') ; colorMapFromArray:#[0 0 0 255 255 127 255 127 127 127 127 127]; mask:((Depth1Image new) width: 5; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'\GC8>O @>O#8\G@b') ; yourself); yourself] |
3675 | 1526 |
! |
1527 |
||
1528 |
small_methodInheritedFromAboveIcon |
|
1529 |
"This resource specification was automatically generated |
|
1530 |
by the ImageEditor of ST/X." |
|
1531 |
||
1532 |
"Do not manually edit this!! If it is corrupted, |
|
1533 |
the ImageEditor may not be able to read the specification." |
|
1534 |
||
1535 |
" |
|
1536 |
self small_methodInheritedFromAboveIcon inspect |
|
1537 |
ImageEditor openOnClass:self andSelector:#small_methodInheritedFromAboveIcon |
|
4130 | 1538 |
Icon flushCachedIcons |
3675 | 1539 |
" |
1540 |
||
1541 |
<resource: #image> |
|
1542 |
||
1543 |
^Icon |
|
1544 |
constantNamed:#'SystemBrowser class small_methodInheritedFromAboveIcon' |
|
4130 | 1545 |
ifAbsentPut:[(Depth2Image new) width: 5; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'H#HDLHR@EP@@@@@@@BD@IP@!!@B@@IP@a') ; colorMapFromArray:#[0 0 0 255 255 127 127 127 127]; mask:((Depth1Image new) width: 5; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'\GC8>O @@@@@@@@b') ; yourself); yourself] |
3675 | 1546 |
! |
1547 |
||
1548 |
small_methodRedefinedBelowIcon |
|
1549 |
"This resource specification was automatically generated |
|
1550 |
by the ImageEditor of ST/X." |
|
1551 |
||
1552 |
"Do not manually edit this!! If it is corrupted, |
|
1553 |
the ImageEditor may not be able to read the specification." |
|
1554 |
||
1555 |
" |
|
1556 |
self small_methodRedefinedBelowIcon inspect |
|
1557 |
ImageEditor openOnClass:self andSelector:#small_methodRedefinedBelowIcon |
|
4130 | 1558 |
Icon flushCachedIcons |
3675 | 1559 |
" |
1560 |
||
1561 |
<resource: #image> |
|
1562 |
||
1563 |
^Icon |
|
1564 |
constantNamed:#'SystemBrowser class small_methodRedefinedBelowIcon' |
|
4130 | 1565 |
ifAbsentPut:[(Depth2Image new) width: 5; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@D@@@@@@@@@@@@@@@4UBHR@A@@"@@@a') ; colorMapFromArray:#[0 0 0 255 127 127 127 127 127]; mask:((Depth1Image new) width: 5; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@>O#8\G@b') ; yourself); yourself] |
3675 | 1566 |
! |
1567 |
||
3354 | 1568 |
startableClassIcon |
7827 | 1569 |
<resource: #programImage> |
1570 |
||
1571 |
^ ToolbarIconLibrary startableClassBrowserIcon |
|
1572 |
||
1573 |
"Created: / 05-11-2001 / 09:50:16 / cg" |
|
1574 |
"Modified: / 20-07-2007 / 09:09:40 / cg" |
|
3354 | 1575 |
! |
1576 |
||
1577 |
startableVisualAppIcon |
|
7827 | 1578 |
<resource: #programImage> |
1579 |
||
1580 |
^ ToolbarIconLibrary visualStartableClassBrowserIcon |
|
1581 |
||
1582 |
"Created: / 05-11-2001 / 09:49:00 / cg" |
|
1583 |
"Modified: / 20-07-2007 / 09:08:34 / cg" |
|
3354 | 1584 |
! |
1585 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1586 |
stopIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1587 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1588 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1589 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1590 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1591 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1592 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1593 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1594 |
self stopIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1595 |
ImageEditor openOnClass:self andSelector:#stopIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1596 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1597 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1598 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1599 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1600 |
^Icon |
3813 | 1601 |
constantNamed:#'SystemBrowser class stopIcon' |
1602 |
ifAbsentPut:[(Depth1Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@N@@8@C @N@@P@@@@D@@8@A@@@@@@a') ; colorMapFromArray:#[255 0 0 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'G0@? G?@?>C?8O? ?>C?8G?@O8@_@@@a') ; yourself); yourself] |
|
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1603 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1604 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1605 |
tabListIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1606 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1607 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1608 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1609 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1610 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1611 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1612 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1613 |
self tabListIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1614 |
ImageEditor openOnClass:self andSelector:#tabListIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1615 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1616 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1617 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1618 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1619 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1620 |
constantNamed:#'SystemBrowser class tabListIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1621 |
ifAbsentPut:[(Depth2Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@D3!!QP@@8TT@@N@@J@C***P@:**$AN**)@C***P@:**$@IUUUB @@@@@b') ; colorMapFromArray:#[0 0 0 127 127 127 170 170 170 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'?8C?0O?0??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1622 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1623 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1624 |
tableColumnsIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1625 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1626 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1627 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1628 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1629 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1630 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1631 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1632 |
self tableColumnsIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1633 |
ImageEditor openOnClass:self andSelector:#tableColumnsIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1634 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1635 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1636 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1637 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1638 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1639 |
constantNamed:#'SystemBrowser class tableColumnsIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1640 |
ifAbsentPut:[(Depth2Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@C??? @8(($@L@@AHC"""R@0@@D@NJJI@C@@@P@8(($@IUUU@@@@@@@b') ; colorMapFromArray:#[0 0 0 127 127 127 170 170 170 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1641 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1642 |
|
4150 | 1643 |
testCaseClassIcon |
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1644 |
<resource: #programImage> |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1645 |
|
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1646 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1647 |
^ ToolbarIconLibrary testCaseClassIcon |
4150 | 1648 |
! |
1649 |
||
1650 |
testCaseClassIconFor:cls |
|
4167 | 1651 |
<resource: #programImage> |
1652 |
||
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1653 |
"/ decision moved to TestCase - see there. |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1654 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1655 |
|
4150 | 1656 |
|lastResult| |
1657 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
1658 |
lastResult := cls lastTestRunResultOrNil. |
4150 | 1659 |
|
1660 |
lastResult == true ifTrue:[ |
|
1661 |
^ self testCasePassedIcon |
|
1662 |
]. |
|
1663 |
lastResult == false ifTrue:[ |
|
1664 |
^ self testCaseFailedIcon |
|
1665 |
]. |
|
1666 |
^ self testCaseUnknownResultIcon |
|
6848 | 1667 |
|
1668 |
"Modified: / 06-08-2006 / 11:14:12 / cg" |
|
4150 | 1669 |
! |
1670 |
||
1671 |
testCaseFailedIcon |
|
4166 | 1672 |
<resource: #programImage> |
1673 |
||
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1674 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1675 |
^ ToolbarIconLibrary testCaseFailedIcon |
4150 | 1676 |
! |
1677 |
||
1678 |
testCasePassedIcon |
|
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1679 |
<resource: #programImage> |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1680 |
|
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1681 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1682 |
^ ToolbarIconLibrary testCasePassedIcon |
4150 | 1683 |
! |
1684 |
||
1685 |
testCaseUnknownResultIcon |
|
4166 | 1686 |
<resource: #programImage> |
1687 |
||
8862
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1688 |
"/ only left here for backward compatibility... |
dece7957557d
comment/format in: #testCaseClassIconFor:
Claus Gittinger <cg@exept.de>
parents:
8853
diff
changeset
|
1689 |
^ ToolbarIconLibrary testCaseClassIcon |
4150 | 1690 |
! |
1691 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1692 |
timeIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1693 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1694 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1695 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1696 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1697 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1698 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1699 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1700 |
self timeIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1701 |
ImageEditor openOnClass:self andSelector:#timeIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1702 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1703 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1704 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1705 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1706 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1707 |
constantNamed:#'SystemBrowser class timeIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1708 |
ifAbsentPut:[(Depth1Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@G@A7@G\@=8C0 O>@_0A?@A0@@@@@a') ; colorMapFromArray:#[0 0 0 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'A0@_0C? O>A?<G?0_?@?8C? G<@G@@@a') ; yourself); yourself] |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1709 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1710 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1711 |
traceIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1712 |
"This resource specification was automatically generated |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1713 |
by the ImageEditor of ST/X." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1714 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1715 |
"Do not manually edit this!! If it is corrupted, |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1716 |
the ImageEditor may not be able to read the specification." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1717 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1718 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1719 |
self traceIcon inspect |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1720 |
ImageEditor openOnClass:self andSelector:#traceIcon |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1721 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1722 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1723 |
<resource: #image> |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1724 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1725 |
^Icon |
8478
ca4c5daa3fb3
image resource method fixes (key must be name of method)
Claus Gittinger <cg@exept.de>
parents:
8281
diff
changeset
|
1726 |
constantNamed:#'SystemBrowser class traceIcon' |
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
1727 |
ifAbsentPut:[(Depth1Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@>@C8@G@@\@@ @B@@@@@@@@@@@a') ; colorMapFromArray:#[255 0 0 255 255 255]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'_?A?<C? O>@_0A?@C8@O @\@A0@B@@@a') ; yourself); yourself] |
2830 | 1728 |
! |
1729 |
||
1730 |
visualStartableClassIcon |
|
1731 |
"This resource specification was automatically generated |
|
1732 |
by the ImageEditor of ST/X." |
|
1733 |
||
1734 |
"Do not manually edit this!! If it is corrupted, |
|
1735 |
the ImageEditor may not be able to read the specification." |
|
1736 |
||
1737 |
" |
|
1738 |
self visualStartableClassIcon inspect |
|
1739 |
ImageEditor openOnClass:self andSelector:#visualStartableClassIcon |
|
1740 |
" |
|
1741 |
||
1742 |
<resource: #image> |
|
1743 |
||
1744 |
^Icon |
|
2892 | 1745 |
constantNamed:#'SystemBrowser class visualStartableClassIcon' |
3354 | 1746 |
ifAbsentPut:[(Depth2Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(2 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'**J*NJ*"*#"*!!J(@*!!T*@J(DJ B*DR(@*!!T*NJ(*J B*O2(@*+.*@J*** @b') ; colorMapFromArray:#[0 0 0 127 127 127 255 0 0 255 255 0]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@ @B@@\@C8@O @>@C8@H @>@A0@G@@@a') ; yourself); yourself] |
1747 |
||
1748 |
"Modified: / 5.11.2001 / 09:49:30 / cg" |
|
2892 | 1749 |
! |
1750 |
||
4275 | 1751 |
warningClassIcon |
7827 | 1752 |
<resource: #programImage> |
1753 |
||
1754 |
^ ToolbarIconLibrary warningClassBrowserIcon |
|
1755 |
||
1756 |
"Modified: / 20-07-2007 / 09:04:39 / cg" |
|
4275 | 1757 |
! |
1758 |
||
2892 | 1759 |
watchIcon |
1760 |
"This resource specification was automatically generated |
|
1761 |
by the ImageEditor of ST/X." |
|
1762 |
||
1763 |
"Do not manually edit this!! If it is corrupted, |
|
1764 |
the ImageEditor may not be able to read the specification." |
|
1765 |
||
1766 |
" |
|
1767 |
self watchIcon inspect |
|
1768 |
ImageEditor openOnClass:self andSelector:#watchIcon |
|
1769 |
" |
|
1770 |
||
1771 |
<resource: #image> |
|
1772 |
||
1773 |
^Icon |
|
1774 |
constantNamed:#'SystemBrowser class watchIcon' |
|
1775 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 12; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@X@@@X@@@@AE XQY @@XALCDFD@@AD0@CDV@@XAL@@1A @AD0@P@1D@XBI!!DVH A QUPQEEU@@%"EDAVHT@IX]R@%!!5@FQUH@@%U@A&H$@@P"X@') ; colorMapFromArray:#[0 0 51 0 0 60 0 51 102 51 102 153 71 102 145 128 213 221 153 153 204 153 255 255 255 255 255]; mask:((Depth1Image new) width: 13; height: 12; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'FL@]0C7 O>A?<G?0??#=>O78?_#8>GA0') ; yourself); yourself] |
|
3354 | 1776 |
! |
1777 |
||
4143 | 1778 |
windowClassIcon |
7827 | 1779 |
<resource: #programImage> |
1780 |
||
1781 |
^ ToolbarIconLibrary windowClassBrowserIcon |
|
1782 |
||
1783 |
"Modified: / 20-07-2007 / 09:05:57 / cg" |
|
4143 | 1784 |
! |
1785 |
||
3354 | 1786 |
windowIcon |
1787 |
"This resource specification was automatically generated |
|
1788 |
by the ImageEditor of ST/X." |
|
1789 |
||
1790 |
"Do not manually edit this!! If it is corrupted, |
|
1791 |
the ImageEditor may not be able to read the specification." |
|
1792 |
||
1793 |
" |
|
1794 |
self windowIcon inspect |
|
1795 |
ImageEditor openOnClass:self andSelector:#windowIcon |
|
1796 |
" |
|
1797 |
||
1798 |
<resource: #image> |
|
1799 |
||
1800 |
^Icon |
|
1801 |
constantNamed:#'SystemBrowser class windowIcon' |
|
1802 |
ifAbsentPut:[(Depth4Image new) width: 13; height: 11; photometric:(#palette); bitsPerSample:(#(4 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'@@@@@@@@@@.;.;.;.0@@@@@@@@@@C.;.;.;/@@9&Y&Y&XP@NY&Y&Y&D@C&Y&Y&Y!!@@9&Y&Y&XP@NY&Y&Y&D@C1DQDQDQ@@@@@@@@@@@b') ; colorMapFromArray:#[0 0 0 255 255 255 255 0 0 0 255 0 0 0 255 0 255 255 255 255 0 255 0 255 127 0 0 0 127 0 0 0 127 0 127 127 127 127 0 127 0 127 127 127 127 170 170 170]; mask:((Depth1Image new) width: 13; height: 11; photometric:(#blackIs0); bitsPerSample:(#(1 )); samplesPerPixel:(1); bits:(ByteArray fromPackedString:'??#?>O?8??#?>O?8??#?>O?8??#?>@@a') ; yourself); yourself] |
|
1803 |
||
1804 |
"Created: / 5.11.2001 / 09:39:03 / cg" |
|
2846 | 1805 |
! ! |
2692 | 1806 |
|
1203 | 1807 |
!SystemBrowser class methodsFor:'interface specs'! |
1808 |
||
1367 | 1809 |
metaSpec |
1810 |
"UIPainter new openOnClass: self andSelector: #metaSpec" |
|
1811 |
||
1812 |
<resource: #canvas> |
|
1813 |
^#(#FullSpec |
|
1814 |
#window: |
|
1815 |
#(#WindowSpec |
|
1816 |
#label: 'Unlabeled Canvas' |
|
1817 |
#bounds: #(#Rectangle 27 249 325 334 ) ) |
|
1818 |
#component: |
|
1819 |
#(#SpecCollection |
|
1820 |
#collection: #( |
|
1821 |
#(#RadioButtonSpec |
|
1822 |
#layout: #(#LayoutFrame 0 0 4 0 -1 0.575 20 0 ) |
|
1823 |
#name: #instanceSwitch |
|
1824 |
#model: #metaHolder |
|
1825 |
#callbacksSpec: |
|
1826 |
#(#UIEventCallbackSubSpec |
|
1827 |
#requestValueChangeSelector: #changeRequest ) |
|
1828 |
#label: 'instance' |
|
1829 |
#select: false ) |
|
1830 |
#(#RadioButtonSpec |
|
1831 |
#layout: #(#LayoutFrame 1 0.575 4 0 -1 1 20 0 ) |
|
1832 |
#name: #classSwitch |
|
1833 |
#model: #metaHolder |
|
1834 |
#callbacksSpec: |
|
1835 |
#(#UIEventCallbackSubSpec |
|
1836 |
#requestValueChangeSelector: #changeRequest ) |
|
1837 |
#label: 'class' |
|
1838 |
#select: true ) ) ) ) |
|
1839 |
||
1840 |
"Created: / 30.10.1997 / 19:07:29 / cg" |
|
1841 |
! |
|
1842 |
||
1203 | 1843 |
methodMoveDialogSpec |
1844 |
"this window spec was automatically generated by the ST/X UIPainter" |
|
1845 |
||
1846 |
"do not manually edit this - the painter/builder may not be able to |
|
1847 |
handle the specification if its corrupted." |
|
1848 |
||
1849 |
" |
|
1850 |
UIPainter new openOnClass:SystemBrowser andSelector:#methodMoveDialogSpec |
|
1851 |
SystemBrowser new openDialogInterface:#methodMoveDialogSpec |
|
1852 |
" |
|
1853 |
||
1854 |
<resource: #canvas> |
|
1855 |
||
1856 |
^ |
|
1857 |
||
1858 |
#(#FullSpec |
|
1859 |
#'window:' |
|
1860 |
#(#WindowSpec |
|
1861 |
#'name:' 'uIPainterView' |
|
1862 |
#'layout:' #(#LayoutFrame 0 0.0 0 0.0 0 1.0 0 1.0) |
|
1863 |
#'label:' 'move method' |
|
1864 |
#'bounds:' #(#Rectangle 0 0 279 118) |
|
1865 |
) |
|
1866 |
#'component:' |
|
1867 |
#(#SpecCollection |
|
1868 |
#'collection:' |
|
1869 |
#( |
|
1870 |
#(#HorizontalPanelViewSpec |
|
1871 |
#'name:' 'horizontalPanelView' |
|
1872 |
#'layout:' #(#LayoutFrame 0 0.0 -35 1.0 0 1.0 -2 1.0) |
|
1873 |
#'component:' |
|
1874 |
#(#SpecCollection |
|
1875 |
#'collection:' |
|
1876 |
#( |
|
1877 |
#(#ActionButtonSpec |
|
1878 |
#'name:' 'actionButton2' |
|
1879 |
#'label:' 'cancel' |
|
1880 |
#'tabable:' true |
|
1881 |
#'model:' #cancel |
|
1882 |
#'extent:' #(#Point 133 27) |
|
1883 |
) |
|
1884 |
#(#ActionButtonSpec |
|
1885 |
#'name:' 'actionButton1' |
|
1886 |
#'label:' 'move' |
|
1887 |
#'tabable:' true |
|
1888 |
#'isDefault:' true |
|
1889 |
#'model:' #accept |
|
1890 |
#'extent:' #(#Point 134 27) |
|
1891 |
) |
|
1892 |
) |
|
1893 |
) |
|
1894 |
#'level:' 0 |
|
1895 |
#'horizontalLayout:' #fitSpace |
|
1896 |
#'verticalLayout:' #center |
|
1897 |
#'horizontalSpace:' 4 |
|
1898 |
#'verticalSpace:' 4 |
|
1899 |
) |
|
1900 |
#(#LabelSpec |
|
1901 |
#'name:' 'label' |
|
1902 |
#'layout:' #(#LayoutFrame 2 0 2 0 -2 1.0 25 0) |
|
1903 |
#'label:' 'move current method to which class:' |
|
1904 |
#'style:' |
|
1905 |
#(#Font |
|
1906 |
'helvetica' 'medium' |
|
1907 |
'roman' 12 |
|
1908 |
) |
|
1909 |
#'foregroundColor:' #(#Color 0.0 0.0 0.0) |
|
1910 |
#'backgroundColor:' #(#Color 66.9993 66.9993 66.9993) |
|
1911 |
#'adjust:' #left |
|
1912 |
) |
|
1913 |
#(#ComboBoxSpec |
|
1914 |
#'name:' 'comboBox1' |
|
1915 |
#'layout:' #(#LayoutFrame 2 0 29 0 -2 1.0 51 0) |
|
1916 |
#'tabable:' true |
|
1917 |
#'model:' #className |
|
1918 |
#'comboList:' #classList |
|
1919 |
) |
|
1920 |
) |
|
1921 |
) |
|
1922 |
) |
|
1923 |
||
1924 |
"Created: 25.6.1997 / 13:45:20 / cg" |
|
1925 |
"Modified: 25.6.1997 / 13:46:44 / cg" |
|
1926 |
! ! |
|
1927 |
||
4860 | 1928 |
!SystemBrowser class methodsFor:'private-helpers'! |
36 | 1929 |
|
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1930 |
askForPackageChangeFrom:oldPkg to:newPkg |
3626 | 1931 |
|answer box notAgain chk| |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1932 |
|
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1933 |
box := OptionBox |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1934 |
title: |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1935 |
('You are about to change a method from another (system-) package. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1936 |
The methods original packageID was ''%1''. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1937 |
If you proceed, the new method will be marked as belonging |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1938 |
to the ''%2'' package (and this warning will not be shown again). |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1939 |
If you proceed with ''keep'', the new method will be installed |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1940 |
but the old packageID will be preserved. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1941 |
Otherwise, hit ''cancel'' to leave the code unchanged. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1942 |
|
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1943 |
PS: if you disable this check here, it can be reenabled it in the launchers settings-compilation dialog.' |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1944 |
bindWith:(oldPkg allBold) |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1945 |
with:(newPkg allBold)) |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1946 |
numberOfOptions:3. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1947 |
|
3476 | 1948 |
box buttonTitles:#('Cancel' 'Keep' 'Continue'). |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1949 |
box defaultButtonIndex:3. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1950 |
box action:[:n | answer := #(#cancel #keep #continue) at:n]. |
5833
5c2a75846afc
Do not use obsolete methods with #form:
Stefan Vogel <sv@exept.de>
parents:
5802
diff
changeset
|
1951 |
box label:'Method redefinition'; image:(WarningBox iconBitmap). |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1952 |
box yPosition:(box formLabel bottom max:box textLabel bottom). |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1953 |
box addVerticalSpace:10. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1954 |
chk := box addCheckBox:'Dont show this dialog again (never keep)' on:(notAgain := false asValue). |
8158
f7b891e7fb75
added preferredWidth & preferredHeight
Claus Gittinger <cg@exept.de>
parents:
8139
diff
changeset
|
1955 |
box preferredExtent:(box preferredExtent + (0 @ chk preferredHeight) + (0@10)). |
2880
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1956 |
box resize. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1957 |
box showAtPointer. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1958 |
box destroy. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1959 |
|
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1960 |
(answer ~~ #cancel) ifTrue:[ |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1961 |
notAgain value ifTrue:[ |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1962 |
Class catchMethodRedefinitions:false. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1963 |
]. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1964 |
]. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1965 |
^ answer. |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1966 |
! |
ef6fcc02a924
give user a chance to suppress the annoying package-change-keep
Claus Gittinger <cg@exept.de>
parents:
2846
diff
changeset
|
1967 |
|
203 | 1968 |
showNoneFound |
3244 | 1969 |
self warn:(self classResources string:'None found.'). |
203 | 1970 |
! |
36 | 1971 |
|
203 | 1972 |
showNoneFound:what |
1620 | 1973 |
|rs| |
1974 |
||
1975 |
rs := self classResources. |
|
3244 | 1976 |
self information:((rs string:what) , (rs string:'...\\... none found.')) withCRs. |
203 | 1977 |
! ! |
36 | 1978 |
|
4860 | 1979 |
!SystemBrowser class methodsFor:'private-instance creation'! |
203 | 1980 |
|
1981 |
newWithLabel:aString setupBlock:aBlock |
|
1982 |
"common helper method for all creation methods" |
|
1983 |
||
1984 |
^ self newWithLabel:aString setupBlock:aBlock onDevice:Screen current |
|
36 | 1985 |
! |
1986 |
||
203 | 1987 |
newWithLabel:aString setupBlock:aBlock onDevice:aWorkstation |
1988 |
"common helper method for all creation methods" |
|
36 | 1989 |
|
203 | 1990 |
|newBrowser| |
45 | 1991 |
|
203 | 1992 |
newBrowser := BrowserView onDevice:aWorkstation. |
1993 |
newBrowser title:aString. |
|
1994 |
aBlock value:newBrowser. |
|
45 | 1995 |
|
203 | 1996 |
newBrowser open. |
1997 |
^ newBrowser |
|
1998 |
! |
|
45 | 1999 |
|
203 | 2000 |
newWithLabel:aString setupSelector:aSymbol arg:arg |
2001 |
"common helper method for all creation methods" |
|
36 | 2002 |
|
203 | 2003 |
^ self newWithLabel:aString setupSelector:aSymbol arg:arg onDevice:Screen current |
36 | 2004 |
! |
2005 |
||
203 | 2006 |
newWithLabel:aString setupSelector:aSymbol arg:arg onDevice:aWorkstation |
2007 |
"common helper method for all creation methods" |
|
2008 |
||
2009 |
|newBrowser| |
|
52 | 2010 |
|
203 | 2011 |
newBrowser := BrowserView onDevice:aWorkstation. |
2012 |
newBrowser title:aString. |
|
2013 |
newBrowser perform:aSymbol with:arg. |
|
2014 |
newBrowser open. |
|
2015 |
^ newBrowser |
|
2016 |
! ! |
|
2017 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2018 |
!SystemBrowser class methodsFor:'special search startup'! |
203 | 2019 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2020 |
allCallsOn:aSelectorString |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2021 |
"return a collection of methods which send aSelector." |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2022 |
|
9007 | 2023 |
^ self |
2024 |
allCallsOn:aSelectorString |
|
2025 |
in:(Smalltalk allClasses) |
|
2026 |
ignoreCase:false |
|
2027 |
match:false |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2028 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2029 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2030 |
SystemBrowser allCallsOn:#at:put: |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2031 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2032 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2033 |
"Created: 24.1.1997 / 19:42:57 / cg" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2034 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2035 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2036 |
allCallsOn:aSelectorString in:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2037 |
"return a collection of methods which send aSelector. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2038 |
Methods from classes in aCollectionOfClasses are searched only." |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2039 |
|
9007 | 2040 |
^ self |
2041 |
allCallsOn:aSelectorString |
|
2042 |
in:aCollectionOfClasses |
|
2043 |
ignoreCase:false |
|
2044 |
match:false |
|
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2045 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2046 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2047 |
allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2048 |
"return a collection of methods which send aSelector. |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2049 |
Methods from classes in aCollectionOfClasses are searched only." |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2050 |
|
9007 | 2051 |
^ self |
2052 |
allCallsOn:aSelectorString |
|
2053 |
in:aCollectionOfClasses |
|
2054 |
ignoreCase:ignoreCase |
|
2055 |
match:true |
|
4270 | 2056 |
|
2057 |
" |
|
2058 |
SystemBrowser allCallsOn:#at:put: in:(Smalltalk allClasses) |
|
2059 |
" |
|
2060 |
||
2061 |
"Modified: 18.4.1997 / 10:32:50 / cg" |
|
2062 |
! |
|
2063 |
||
2064 |
allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
2065 |
"return a collection of methods which send aSelector. |
|
2066 |
Methods from classes in aCollectionOfClasses are searched only." |
|
2067 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2068 |
|sel searchBlock classesSearched| |
3471
4c4b41516d96
care for empty selector in allCallsOn.
Claus Gittinger <cg@exept.de>
parents:
3470
diff
changeset
|
2069 |
|
4c4b41516d96
care for empty selector in allCallsOn.
Claus Gittinger <cg@exept.de>
parents:
3470
diff
changeset
|
2070 |
aSelectorString size == 0 ifTrue:[ ^ #() ]. |
4270 | 2071 |
doMatch ifFalse:[ |
5090 | 2072 |
ignoreCase ifFalse:[ |
2073 |
sel := aSelectorString asSymbolIfInterned. |
|
2074 |
sel isNil ifTrue:[ |
|
2075 |
^ #() "/ none (no such selector) |
|
2076 |
]. |
|
4270 | 2077 |
]. |
2078 |
]. |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2079 |
|
2901 | 2080 |
classesSearched := aCollectionOfClasses. |
4270 | 2081 |
(doMatch and:[aSelectorString includesMatchCharacters]) ifFalse:[ |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2082 |
"/ exclude javaClasses, if selector cannot be a valid java-selector |
4270 | 2083 |
(aSelectorString includes:$() ifFalse:[ |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2084 |
classesSearched := classesSearched select:[:eachClass | eachClass theNonMetaclass isJavaClass not]. |
2846 | 2085 |
]. |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2086 |
]. |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
2087 |
|
4270 | 2088 |
searchBlock := self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:doMatch. |
4332 | 2089 |
searchBlock isNil ifTrue:[ |
2090 |
^ #() "/ none (no such selector) |
|
2091 |
]. |
|
2901 | 2092 |
^ self allMethodsIn:classesSearched where:searchBlock |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2093 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2094 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2095 |
SystemBrowser allCallsOn:#at:put: in:(Smalltalk allClasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2096 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2097 |
|
1143
0707461e582a
avoid compilation of lazy methods when searching for senders
Claus Gittinger <cg@exept.de>
parents:
1059
diff
changeset
|
2098 |
"Modified: 18.4.1997 / 10:32:50 / cg" |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2099 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2100 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2101 |
allMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2102 |
"return a collection of methods which pass the given test. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2103 |
wantInst/wantClass control if instMethods and/or classMethods are to be |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2104 |
considered. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2105 |
Only classes in aCollectionOfClasses are inspected in the search" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2106 |
|
2769 | 2107 |
|list activePriority| |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2108 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2109 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2110 |
since this may take a long time, lower my priority ... |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2111 |
" |
2769 | 2112 |
activePriority := Processor activePriority. |
2295
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
2113 |
Processor activeProcess |
2769 | 2114 |
withPriority:activePriority-1 to:activePriority |
2295
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
2115 |
do:[ |
2484
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2116 |
|checkedClasses checkBlock detectedMethods| |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2117 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2118 |
checkedClasses := IdentitySet new. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2119 |
list := OrderedCollection new. |
2484
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2120 |
detectedMethods := IdentitySet new. |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2121 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2122 |
checkBlock := [:cls | |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2123 |
(checkedClasses includes:cls) ifFalse:[ |
8554
441ea25ad1fd
Do not complain about obsolete classes which are unloaded when searching
Stefan Vogel <sv@exept.de>
parents:
8505
diff
changeset
|
2124 |
(cls isObsolete and:[cls isLoaded]) ifTrue:[ |
2882 | 2125 |
Transcript showCR:'Browser method search: skipping obsolete class: ' , cls displayString |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2126 |
] ifFalse:[ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2127 |
cls methodDictionary keysAndValuesDo:[:sel :method | |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2128 |
(aBlock value:cls value:method value:sel) ifTrue:[ |
2484
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2129 |
"/ care for methods being in multiple classes (should not happen) |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2130 |
(detectedMethods includes:method) ifFalse:[ |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2131 |
list add:method. |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2132 |
detectedMethods add:method |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2133 |
] |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2134 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2135 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2136 |
checkedClasses add:cls. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2137 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2138 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2139 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2140 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2141 |
aCollectionOfClasses do:[:aClass | |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2142 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2143 |
output disabled - it slows down things too much (when searching for |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2144 |
implementors or senders) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2145 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2146 |
wantInst ifTrue:[ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2147 |
"/ Transcript show:'searching '; show:aClass name; showCR:' ...'; endEntry. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2148 |
checkBlock value:aClass |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2149 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2150 |
wantClass ifTrue:[ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2151 |
"/ Transcript show:'searching '; show:aClass class name; showCR:' ...'; endEntry. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2152 |
checkBlock value:(aClass class) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2153 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2154 |
Processor yield |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2155 |
] |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2156 |
]. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2157 |
^ list |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2158 |
|
2484
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2159 |
"Created: / 24.1.1997 / 19:41:12 / cg" |
afd8d8dbd9e2
care vor methods being found in multiple classes
Claus Gittinger <cg@exept.de>
parents:
2439
diff
changeset
|
2160 |
"Modified: / 14.12.1999 / 14:59:02 / cg" |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2161 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2162 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2163 |
allMethodsIn:aCollectionOfClasses where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2164 |
"return a collection of methods which pass the given test. |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2165 |
Only classes in aCollectionOfClasses are inspected in the search" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2166 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2167 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2168 |
allMethodsIn:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2169 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2170 |
class:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2171 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2172 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2173 |
"Created: 24.1.1997 / 19:41:49 / cg" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2174 |
! |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2175 |
|
203 | 2176 |
aproposSearch:aString |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2177 |
"browse all methods, which have aString in their selector." |
203 | 2178 |
|
2179 |
^ self aproposSearch:aString in:(Smalltalk allClasses) |
|
75 | 2180 |
|
52 | 2181 |
! |
2182 |
||
203 | 2183 |
aproposSearch:aString in:aCollectionOfClasses |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2184 |
"browse all methods, which have aString. |
203 | 2185 |
This is relatively slow, since all source must be processed." |
52 | 2186 |
|
203 | 2187 |
|matchString list s searchBlock browser| |
52 | 2188 |
|
203 | 2189 |
matchString := '*' , aString , '*'. |
52 | 2190 |
|
203 | 2191 |
list := OrderedCollection new. |
52 | 2192 |
|
203 | 2193 |
(aString includesMatchCharacters) ifTrue:[ |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2194 |
s := '*' , aString asLowercase , '*'. |
256 | 2195 |
"a matchString" |
2196 |
searchBlock := [:text | (text asCollectionOfLinesfindFirst:[:line | s match:line]) ~~ 0]. |
|
203 | 2197 |
] ifFalse:[ |
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2198 |
searchBlock := [:source | (source findString:aString asLowercase) ~~ 0] |
203 | 2199 |
]. |
52 | 2200 |
|
203 | 2201 |
browser := self browseMethodsIn:aCollectionOfClasses |
256 | 2202 |
where:[:class :method :sel | |
2203 |
|comment| |
|
52 | 2204 |
|
2655
9e90bbd1eb18
apropos search is now: selectors containing
Claus Gittinger <cg@exept.de>
parents:
2642
diff
changeset
|
2205 |
(searchBlock value:sel asLowercase) |
256 | 2206 |
] |
2729
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
2207 |
title:(self classResources string:'selectors containing: %1' with:aString). |
52 | 2208 |
|
203 | 2209 |
browser notNil ifTrue:[ |
256 | 2210 |
browser autoSearch:aString |
203 | 2211 |
]. |
2212 |
^ browser |
|
52 | 2213 |
|
2214 |
" |
|
203 | 2215 |
SystemBrowser aproposSearch:'append' in:(Collection withAllSubclasses) |
2216 |
SystemBrowser aproposSearch:'add' in:(Collection withAllSubclasses) |
|
2217 |
SystemBrowser aproposSearch:'sort' in:(Collection withAllSubclasses) |
|
2218 |
SystemBrowser aproposSearch:'[Aa]bsent' in:(Collection withAllSubclasses) |
|
52 | 2219 |
" |
203 | 2220 |
|
256 | 2221 |
"Created: 9.12.1995 / 18:02:36 / cg" |
204
6f4460d5a09d
added supersend searches; offer comparing the current version with the
Claus Gittinger <cg@exept.de>
parents:
203
diff
changeset
|
2222 |
! |
6f4460d5a09d
added supersend searches; offer comparing the current version with the
Claus Gittinger <cg@exept.de>
parents:
203
diff
changeset
|
2223 |
|
203 | 2224 |
browseAllCallsOn:aSelectorString |
4490 | 2225 |
"launch a browser for all senders of aSelector. |
2226 |
Notice: better go via Smalltalk browseAllCallsOn:, which honors the tool-preferences" |
|
52 | 2227 |
|
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2228 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2229 |
browseAllCallsOn:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2230 |
in:(Smalltalk allClasses) |
52 | 2231 |
|
2232 |
" |
|
203 | 2233 |
SystemBrowser browseAllCallsOn:#+ |
52 | 2234 |
" |
256 | 2235 |
|
2236 |
"Created: 9.12.1995 / 18:00:41 / cg" |
|
666 | 2237 |
"Modified: 10.7.1996 / 10:26:15 / cg" |
2238 |
! |
|
2239 |
||
2240 |
browseAllCallsOn:aSelectorString in:aSetOfClasses |
|
2241 |
"launch a browser for all senders of aSelector" |
|
2242 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2243 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2244 |
browseAllCallsOn:aSelectorString |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2245 |
in:aSetOfClasses |
4200 | 2246 |
title:(self classResources string:'Senders of: %1' with:aSelectorString) |
666 | 2247 |
|
2248 |
" |
|
2249 |
SystemBrowser browseAllCallsOn:#+ in:(Number withAllSubclasses) |
|
2250 |
" |
|
2251 |
||
2252 |
"Created: 10.7.1996 / 10:25:49 / cg" |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2253 |
"Modified: 24.1.1997 / 19:49:34 / cg" |
52 | 2254 |
! |
2255 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2256 |
browseAllCallsOn:aSelectorString in:aSetOfClasses ignoreCase:ignoreCase |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2257 |
"launch a browser for all senders of aSelector" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2258 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2259 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2260 |
browseAllCallsOn:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2261 |
in:aSetOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2262 |
ignoreCase:ignoreCase |
6476 | 2263 |
title:(self classResources string:'Senders of: %1' with:aSelectorString) |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2264 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2265 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2266 |
SystemBrowser browseAllCallsOn:#+ in:(Number withAllSubclasses) |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2267 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2268 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2269 |
"Created: 10.7.1996 / 10:25:49 / cg" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2270 |
"Modified: 24.1.1997 / 19:49:34 / cg" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2271 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2272 |
|
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2273 |
browseAllCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:titleArg |
52 | 2274 |
"launch a browser for all senders of aSelector in aCollectionOfClasses" |
2275 |
||
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2276 |
|list list2 browser selWithColon title rs| |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2277 |
|
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2278 |
title := titleArg. |
4200 | 2279 |
|
4270 | 2280 |
list := self allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:true. |
4200 | 2281 |
list isEmpty ifTrue:[ |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2282 |
aSelectorString numArgs == 0 ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2283 |
selWithColon := aSelectorString , ':'. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2284 |
selWithColon knownAsSymbol ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2285 |
list2 := self allCallsOn:selWithColon in:aCollectionOfClasses ignoreCase:ignoreCase match:true. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2286 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2287 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2288 |
list2 size == 0 ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2289 |
self showNoneFound:title. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2290 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2291 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2292 |
rs := self classResources. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2293 |
(Dialog confirm:((rs string:title) , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2294 |
(rs string:'...\\... none found.') , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2295 |
(rs string:'\\But I found %1 sends of the "%2" message (with colon).\\Browse those ?' |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2296 |
with:list2 size |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2297 |
with:selWithColon allBold)) withCRs) ifFalse:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2298 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2299 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2300 |
list := list2. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2301 |
title := title , ':'. |
4200 | 2302 |
]. |
2303 |
||
2304 |
browser := self browseMethods:list title:title. |
|
52 | 2305 |
browser notNil ifTrue:[ |
648
6ec086b7972c
Move method's literals form literalArray to indexed instvars.
Stefan Vogel <sv@exept.de>
parents:
634
diff
changeset
|
2306 |
|s| |
52 | 2307 |
|
8139
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2308 |
"/ " |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2309 |
"/ kludge for now, if its a multipart selector, |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2310 |
"/ no easy search is (as yet) possible |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2311 |
"/ " |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2312 |
"/ s := aSelectorString. |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2313 |
"/ (s includes:$:) ifTrue:[ |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2314 |
"/ s := s copyTo:(s indexOf:$:) |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2315 |
"/ ]. |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2316 |
"/ browser autoSearch:s |
acdaec7c63a0
auto-search for selector (not string) when searching senders.
Claus Gittinger <cg@exept.de>
parents:
8129
diff
changeset
|
2317 |
browser autoSearchSelector:aSelectorString ignoreCase:ignoreCase doMatch:true. |
52 | 2318 |
]. |
2319 |
^ browser |
|
648
6ec086b7972c
Move method's literals form literalArray to indexed instvars.
Stefan Vogel <sv@exept.de>
parents:
634
diff
changeset
|
2320 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2321 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2322 |
SystemBrowser |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2323 |
browseAllCallsOn:#+ |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2324 |
in:(Number withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2325 |
title:'just a test' |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2326 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2327 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2328 |
"Modified: 24.1.1997 / 19:48:54 / cg" |
52 | 2329 |
! |
2330 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2331 |
browseAllCallsOn:aSelectorString in:aCollectionOfClasses title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2332 |
"launch a browser for all senders of aSelector in aCollectionOfClasses" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2333 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2334 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2335 |
browseAllCallsOn:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2336 |
in:aCollectionOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2337 |
ignoreCase:false |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2338 |
title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2339 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2340 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2341 |
SystemBrowser |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2342 |
browseAllCallsOn:#+ |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2343 |
in:(Number withAllSubclasses) |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2344 |
title:'just a test' |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2345 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2346 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2347 |
"Modified: 24.1.1997 / 19:48:54 / cg" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2348 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2349 |
|
203 | 2350 |
browseCallsOn:aSelectorString under:aClass |
2351 |
"launch a browser for all senders of aSelector in aClass and subclasses" |
|
2352 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2353 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2354 |
browseAllCallsOn:aSelectorString |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2355 |
in:(aClass withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2356 |
title:(self classResources |
6476 | 2357 |
string:'Senders of: %1 (in and below %2)' |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2358 |
with:aSelectorString |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2359 |
with:aClass name) |
203 | 2360 |
|
2361 |
" |
|
256 | 2362 |
SystemBrowser browseCallsOn:#+ under:Number |
203 | 2363 |
" |
256 | 2364 |
|
2365 |
"Created: 9.12.1995 / 17:59:57 / cg" |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
2366 |
"Modified: 24.1.1997 / 19:50:33 / cg" |
203 | 2367 |
! |
2368 |
||
2369 |
browseClassRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
|
2370 |
"launch a browser for all methods in aClass where the classVar named |
|
2371 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
2372 |
classvar is modified" |
|
2373 |
||
2374 |
^ self browseRefsTo:aString classVars:true in:aCollectionOfClasses modificationsOnly:modsOnly |
|
2375 |
! |
|
2376 |
||
2377 |
browseClassRefsTo:varName in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
|
2378 |
"launch a browser for all methods in aCollectionOfClasses, |
|
2379 |
where the classVar named aString is referenced; |
|
2380 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
2381 |
||
2382 |
^ self browseRefsTo:varName classVars:true in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
|
2383 |
! |
|
2384 |
||
2385 |
browseClassRefsTo:aString under:aClass modificationsOnly:modsOnly |
|
2386 |
"launch a browser for all methods in aClass and subclasses |
|
2387 |
where the classVar named aString is referenced; |
|
2388 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
2389 |
||
2390 |
^ self browseClassRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
|
2391 |
||
2392 |
! |
|
2393 |
||
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2394 |
browseForResource:aResourceSymbol containing:item in:aCollectionOfClasses title:title |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2395 |
"launch a browser for all methods which have a particular (or any, ifNil) |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2396 |
resource in aCollectionOfClasses. |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2397 |
If aKey is nonNil, only methods which have aKey in the (any) resourceSpec |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2398 |
are parsed. |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2399 |
I.e. to find all methods, which access the styleSheets, use: |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2400 |
browseForResource:#style containing:nil in:... title:... |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2401 |
to find methods which access the 'arrowButtonDownForm' styleSheet entry, use: |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2402 |
browseForResource:#style containing:'arrowButtonDownForm' in:... title:..." |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2403 |
|
742
2ef5e22d8983
code cleanup (unused vars eliminated)
Claus Gittinger <cg@exept.de>
parents:
675
diff
changeset
|
2404 |
|browser searchBlock| |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2405 |
|
1356 | 2406 |
"/ search for any resource can be done without looking |
2407 |
"/ at the source ... |
|
2408 |
(aResourceSymbol isNil and:[item isNil]) ifTrue:[ |
|
2409 |
searchBlock := [:class :method :s | method hasResource] |
|
2410 |
] ifFalse:[ |
|
2411 |
searchBlock := [:class :method :s | |
|
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2412 |
|rsrc val found| |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2413 |
|
1356 | 2414 |
found := false. |
2415 |
method hasResource ifTrue:[ |
|
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2416 |
rsrc := method resources. |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2417 |
rsrc notNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2418 |
aResourceSymbol isNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2419 |
item isNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2420 |
found := true |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2421 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2422 |
rsrc isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2423 |
rsrc keysAndValuesDo:[:rsrc :val | |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2424 |
val isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2425 |
val do:[:v | |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2426 |
found := item match:v printString |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2427 |
] |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2428 |
] ifFalse:[ |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2429 |
found := item match:val printString |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2430 |
] |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2431 |
] |
1356 | 2432 |
] ifFalse:[ |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2433 |
found := item match:rsrc printString |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2434 |
] |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2435 |
] |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2436 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2437 |
(rsrc includesKey:aResourceSymbol) ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2438 |
item isNil ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2439 |
found := true |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2440 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2441 |
rsrc isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2442 |
val := rsrc at:aResourceSymbol. |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2443 |
val isCollection ifTrue:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2444 |
val do:[:v | |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2445 |
found := item match:v printString |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2446 |
] |
1356 | 2447 |
] ifFalse:[ |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2448 |
found := item match:val printString |
1356 | 2449 |
] |
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2450 |
] ifFalse:[ |
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2451 |
found := item match:rsrc printString |
1356 | 2452 |
] |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2453 |
] |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2454 |
] |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2455 |
] |
1356 | 2456 |
]. |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2457 |
]. |
1356 | 2458 |
found |
2459 |
]. |
|
2460 |
]. |
|
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2461 |
|
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2462 |
browser := self browseMethodsIn:aCollectionOfClasses |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2463 |
where:searchBlock |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2464 |
title:title. |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2465 |
browser notNil ifTrue:[ |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2466 |
browser autoSearch:'resource:' |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2467 |
]. |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2468 |
^ browser |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2469 |
|
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2470 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2471 |
SystemBrowser |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2472 |
browseForResource:nil |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2473 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2474 |
title:'methods with a resource' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2475 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2476 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2477 |
SystemBrowser |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2478 |
browseForResource:#style |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2479 |
containing:nil |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2480 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2481 |
title:'methods with a #style resource' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2482 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2483 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2484 |
SystemBrowser |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2485 |
browseForResource:#style |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2486 |
containing:'arrowButton*' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2487 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2488 |
title:'methods with a #style resource' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2489 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2490 |
|
1573
4b6ce12dff2b
dont duplicate the code in method>>resources
Claus Gittinger <cg@exept.de>
parents:
1561
diff
changeset
|
2491 |
"Modified: / 22.4.1998 / 10:29:20 / cg" |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2492 |
! |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2493 |
|
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2494 |
browseForResource:aResourceSymbol in:aCollectionOfClasses title:title |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2495 |
"launch a browser for all methods which have a particular (or any, ifNil) |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2496 |
resource in aCollectionOfClasses" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2497 |
|
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2498 |
^ self |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2499 |
browseForResource:aResourceSymbol |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2500 |
containing:nil |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2501 |
in:aCollectionOfClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2502 |
title:title |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2503 |
|
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2504 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2505 |
SystemBrowser |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2506 |
browseForResource:#style |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2507 |
in:Smalltalk allClasses |
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2508 |
title:'methods accessing styleSheet values' |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2509 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2510 |
" |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2511 |
SystemBrowser |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2512 |
browseForResource:#keyboard |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2513 |
in:Smalltalk allClasses |
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2514 |
title:'methods handling keyboard events' |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2515 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2516 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2517 |
SystemBrowser |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2518 |
browseForResource:nil |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2519 |
in:Smalltalk allClasses |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2520 |
title:'methods with a resource' |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2521 |
" |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2522 |
|
929
a2275f1b4c94
enhanced resource search, to search for a particular
Claus Gittinger <cg@exept.de>
parents:
825
diff
changeset
|
2523 |
"Modified: 9.1.1997 / 12:44:38 / cg" |
573
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2524 |
! |
e32bd3e46a72
added startup for searching resourceSpecs
Claus Gittinger <cg@exept.de>
parents:
553
diff
changeset
|
2525 |
|
203 | 2526 |
browseForString:aString |
2527 |
"launch a browser for all methods containing a string in their source. |
|
2528 |
This may be slow, since source-code has to be scanned." |
|
2529 |
||
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2530 |
^ self browseForString:aString in:(Smalltalk allClasses) ignoreCase:false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2531 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2532 |
"Modified: / 18.6.1998 / 16:42:39 / cg" |
203 | 2533 |
! |
2534 |
||
2535 |
browseForString:aString in:aCollectionOfClasses |
|
2536 |
"launch a browser for all methods in aCollectionOfClasses |
|
2537 |
containing a string in their source. |
|
2538 |
This may be slow, since source-code has to be scanned." |
|
2539 |
||
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2540 |
^ self |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2541 |
browseForString:aString |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2542 |
in:aCollectionOfClasses |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2543 |
ignoreCase:false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2544 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2545 |
" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2546 |
SystemBrowser browseForString:'all' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2547 |
SystemBrowser browseForString:'should' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2548 |
SystemBrowser browseForString:'[eE]rror' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2549 |
" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2550 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2551 |
"Created: / 9.12.1995 / 18:03:12 / cg" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2552 |
"Modified: / 18.6.1998 / 16:43:27 / cg" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2553 |
! |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2554 |
|
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2555 |
browseForString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2556 |
"launch a browser for all methods in aCollectionOfClasses |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2557 |
containing a string in their source. |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2558 |
This may be slow, since source-code has to be scanned." |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2559 |
|
203 | 2560 |
|browser searchBlock title s| |
2561 |
||
6476 | 2562 |
title := self classResources string:'Methods containing: %1' with:aString displayString. |
203 | 2563 |
|
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2564 |
(aString includesMatchCharacters |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2565 |
or:[ignoreCase]) ifTrue:[ |
256 | 2566 |
s := '*' , aString , '*'. |
2567 |
"a matchString" |
|
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2568 |
searchBlock := [:c :m :sel | |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2569 |
|src| |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2570 |
src := m source. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2571 |
src isNil ifTrue:[ |
2208
e077aa992f7a
check for nil source in #allCallsOn: (for methods where src in not available)
Claus Gittinger <cg@exept.de>
parents:
1937
diff
changeset
|
2572 |
('Browser [info]: no source for ' , m printString) infoPrintCR. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2573 |
false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2574 |
] ifFalse:[ |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2575 |
s match:src ignoreCase:ignoreCase |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2576 |
] |
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2577 |
] |
203 | 2578 |
] ifFalse:[ |
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2579 |
searchBlock := [:c :m :sel | |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2580 |
|src| |
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2581 |
|
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2582 |
src := m source. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2583 |
src isNil ifTrue:[ |
2208
e077aa992f7a
check for nil source in #allCallsOn: (for methods where src in not available)
Claus Gittinger <cg@exept.de>
parents:
1937
diff
changeset
|
2584 |
('Browser [info]: no source for ' , m printString) infoPrintCR. |
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2585 |
false |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2586 |
] ifFalse:[ |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2587 |
(src findString:aString) ~~ 0 |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2588 |
] |
475
b14b3ab39af6
dont crash if searching a string in a method which has no accessable source
Claus Gittinger <cg@exept.de>
parents:
436
diff
changeset
|
2589 |
] |
203 | 2590 |
]. |
2591 |
browser := self browseMethodsIn:aCollectionOfClasses where:searchBlock title:title. |
|
2592 |
||
2593 |
browser notNil ifTrue:[ |
|
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2594 |
browser autoSearch:aString ignoreCase:ignoreCase |
203 | 2595 |
]. |
2596 |
^ browser |
|
2597 |
||
2598 |
" |
|
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2599 |
SystemBrowser browseForString:'all' in:(Array with:Object) |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2600 |
SystemBrowser browseForString:'should' in:(Array with:Object) |
203 | 2601 |
SystemBrowser browseForString:'[eE]rror' in:(Array with:Object) |
2602 |
" |
|
2603 |
||
1703
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2604 |
"Created: / 18.6.1998 / 16:42:50 / cg" |
ea66390f879b
added ignoreCase option to string-search.
Claus Gittinger <cg@exept.de>
parents:
1681
diff
changeset
|
2605 |
"Modified: / 18.6.1998 / 16:51:25 / cg" |
203 | 2606 |
! |
2607 |
||
2608 |
browseForSymbol:aSymbol |
|
2609 |
"launch a browser for all methods referencing aSymbol" |
|
2610 |
||
666 | 2611 |
^ self |
2612 |
browseForSymbol:aSymbol |
|
6476 | 2613 |
title:(self classResources string:'Users of: %1' with:aSymbol) |
666 | 2614 |
warnIfNone:true |
256 | 2615 |
|
2616 |
"Created: 9.12.1995 / 18:04:34 / cg" |
|
666 | 2617 |
"Modified: 10.7.1996 / 10:35:34 / cg" |
2618 |
! |
|
2619 |
||
2620 |
browseForSymbol:aSymbol in:aSetOfClasses title:title warnIfNone:doWarn |
|
2621 |
"launch a browser for all methods referencing aSymbol" |
|
2622 |
||
7914 | 2623 |
^ self |
2624 |
browseForSymbol:aSymbol |
|
2625 |
in:aSetOfClasses |
|
2626 |
title:title |
|
2627 |
warnIfNone:doWarn |
|
2628 |
searchFor:aSymbol |
|
203 | 2629 |
! |
2630 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2631 |
browseForSymbol:aSymbol in:aSetOfClasses title:title warnIfNone:doWarn searchFor:searchString |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2632 |
"launch a browser for all methods referencing aSymbol" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2633 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2634 |
|browser searchBlock sym| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2635 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2636 |
(aSymbol includesMatchCharacters) ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2637 |
"a matchString" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2638 |
searchBlock := [:c :m :s | |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2639 |
(m literalsDetect:[:aLiteral| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2640 |
(aLiteral isMemberOf:Symbol) |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2641 |
and:[aSymbol match:aLiteral] |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2642 |
] ifNone:nil) notNil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2643 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2644 |
] ifFalse:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2645 |
" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2646 |
can do a faster search |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2647 |
" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2648 |
sym := aSymbol asSymbolIfInterned. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2649 |
sym isNil ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2650 |
self showNoneFound:title. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2651 |
^ nil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2652 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2653 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2654 |
searchBlock := [:c :m :s | |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2655 |
(m literalsDetect:[:aLiteral| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2656 |
(sym == aLiteral) |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2657 |
] ifNone:nil) notNil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2658 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2659 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2660 |
doWarn ifFalse:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2661 |
WarningSignal ignoreIn:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2662 |
browser := self browseMethodsIn:aSetOfClasses where:searchBlock title:title. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2663 |
] |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2664 |
] ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2665 |
browser := self browseMethodsIn:aSetOfClasses where:searchBlock title:title. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2666 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2667 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2668 |
(browser notNil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2669 |
and:[searchString notNil]) ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2670 |
browser autoSearch:searchString |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2671 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2672 |
^ browser |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2673 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2674 |
"Modified: 24.6.1996 / 14:39:07 / stefan" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2675 |
"Modified: 30.6.1996 / 16:45:25 / cg" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2676 |
"Created: 31.10.1996 / 14:57:30 / cg" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2677 |
! |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2678 |
|
2409 | 2679 |
browseForSymbol:aSymbol title:title ifNone:actionIfNoneFound searchFor:searchString |
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2680 |
"launch a browser for all methods referencing aSymbol" |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2681 |
|
203 | 2682 |
|browser searchBlock sym| |
2683 |
||
2684 |
(aSymbol includesMatchCharacters) ifTrue:[ |
|
375 | 2685 |
"a matchString" |
2686 |
searchBlock := [:c :m :s | |
|
2439 | 2687 |
m referencesGlobalMatching:aSymbol |
2688 |
"/ (m literalsDetect:[:aLiteral| |
|
2689 |
"/ (aLiteral isMemberOf:Symbol) |
|
2690 |
"/ and:[aSymbol match:aLiteral] |
|
2691 |
"/ ] ifNone:nil) notNil |
|
375 | 2692 |
]. |
203 | 2693 |
] ifFalse:[ |
375 | 2694 |
" |
2695 |
can do a faster search |
|
2696 |
" |
|
2697 |
sym := aSymbol asSymbolIfInterned. |
|
2698 |
sym isNil ifTrue:[ |
|
2409 | 2699 |
actionIfNoneFound value. |
375 | 2700 |
^ nil |
2701 |
]. |
|
203 | 2702 |
|
375 | 2703 |
searchBlock := [:c :m :s | |
2439 | 2704 |
m referencesGlobal:sym |
2705 |
"/ (m literalsDetect:[:aLiteral| |
|
2706 |
"/ (sym == aLiteral) |
|
2707 |
"/ ] ifNone:nil) notNil |
|
375 | 2708 |
]. |
203 | 2709 |
]. |
2409 | 2710 |
|
2711 |
WarningSignal ignoreIn:[ |
|
2712 |
InformationSignal ignoreIn:[ |
|
375 | 2713 |
browser := self browseMethodsWhere:searchBlock title:title. |
2714 |
] |
|
2409 | 2715 |
]. |
2716 |
browser isNil ifTrue:[ |
|
2717 |
actionIfNoneFound value |
|
215
244f3a9b2a60
check for existing class in rename; avoid warnbox if no refs are found after rename
Claus Gittinger <cg@exept.de>
parents:
204
diff
changeset
|
2718 |
]. |
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2719 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2720 |
(browser notNil |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2721 |
and:[searchString notNil]) ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
2722 |
browser autoSearch:searchString |
203 | 2723 |
]. |
2724 |
^ browser |
|
375 | 2725 |
|
2439 | 2726 |
"Modified: / 24.6.1996 / 14:39:07 / stefan" |
2727 |
"Created: / 31.10.1996 / 14:45:08 / cg" |
|
2728 |
"Modified: / 9.11.1999 / 17:04:30 / cg" |
|
203 | 2729 |
! |
2730 |
||
2409 | 2731 |
browseForSymbol:aSymbol title:title warnIfNone:doWarn |
2732 |
"launch a browser for all methods referencing aSymbol" |
|
2733 |
||
2734 |
^ self |
|
2735 |
browseForSymbol:aSymbol |
|
2736 |
title:title |
|
2737 |
warnIfNone:doWarn |
|
2738 |
searchFor:aSymbol |
|
2739 |
||
2740 |
"Modified: 31.10.1996 / 14:45:38 / cg" |
|
2741 |
! |
|
2742 |
||
2743 |
browseForSymbol:aSymbol title:title warnIfNone:doWarn searchFor:searchString |
|
2744 |
"launch a browser for all methods referencing aSymbol" |
|
2745 |
||
2414 | 2746 |
|b| |
2747 |
||
2748 |
doWarn ifTrue: [ |
|
4158 | 2749 |
b := [self showNoneFound:title] |
2414 | 2750 |
]. |
2409 | 2751 |
^ self |
2752 |
browseForSymbol:aSymbol |
|
2753 |
title:title |
|
2414 | 2754 |
ifNone:b |
2409 | 2755 |
searchFor:searchString |
2756 |
! |
|
2757 |
||
4158 | 2758 |
browseImplementorsMatching:aSelectorString |
2759 |
"launch a browser for all implementors of aSelector" |
|
2760 |
||
2761 |
^ self |
|
2762 |
browseImplementorsMatching:aSelectorString |
|
2763 |
in:(Smalltalk allClasses) |
|
2764 |
||
2765 |
" |
|
2766 |
SystemBrowser browseImplementorsOf:#+ |
|
2767 |
NewSystemBrowser browseImplementorsOf:#+ |
|
2768 |
" |
|
2769 |
||
2770 |
"Created: / 9.12.1995 / 18:01:18 / cg" |
|
2771 |
"Modified: / 5.11.2001 / 17:31:11 / cg" |
|
2772 |
! |
|
2773 |
||
2774 |
browseImplementorsMatching:aSelectorString in:aSetOfClasses |
|
2775 |
"launch a browser for all implementors of aSelector" |
|
2776 |
||
2777 |
^ self |
|
2778 |
browseImplementorsMatching:aSelectorString |
|
2779 |
in:aSetOfClasses |
|
2780 |
title:(self classResources string:'implementors of: %1' with:aSelectorString) |
|
2781 |
||
2782 |
" |
|
2783 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
2784 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
2785 |
" |
|
2786 |
||
2787 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
|
2788 |
"Modified: / 5.11.2001 / 17:30:57 / cg" |
|
2789 |
! |
|
2790 |
||
2791 |
browseImplementorsMatching:aSelectorString in:aSetOfClasses ignoreCase:ignoreCase |
|
2792 |
"launch a browser for all implementors of aSelector" |
|
2793 |
||
2794 |
^ self |
|
2795 |
browseImplementorsMatching:aSelectorString |
|
2796 |
in:aSetOfClasses |
|
2797 |
ignoreCase:ignoreCase |
|
2798 |
title:(self classResources string:'implementors of: %1' with:aSelectorString) |
|
2799 |
||
2800 |
" |
|
2801 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
2802 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
2803 |
" |
|
2804 |
||
2805 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
|
2806 |
"Modified: / 5.11.2001 / 17:30:43 / cg" |
|
2807 |
! |
|
2808 |
||
2809 |
browseImplementorsMatching:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:title |
|
2810 |
"launch a browser for all implementors of aSelector in |
|
2811 |
the classes contained in aCollectionOfClasses and its metaclasses" |
|
2812 |
||
2813 |
|list| |
|
2814 |
||
2815 |
list := self |
|
2816 |
findImplementorsMatching:aSelectorString |
|
2817 |
in:aCollectionOfClasses |
|
2818 |
ignoreCase:ignoreCase. |
|
2819 |
||
2820 |
list size == 0 ifTrue:[ |
|
2821 |
self showNoneFound:title. |
|
2822 |
^ nil |
|
2823 |
]. |
|
2824 |
||
2825 |
^ self browseMethods:list asOrderedCollection title:title |
|
2826 |
||
2827 |
" |
|
2828 |
SystemBrowser browseImplementorsOf:#+ |
|
2829 |
in:(Array with:Number |
|
2830 |
with:Float |
|
2831 |
with:SmallInteger) |
|
2832 |
title:'some implementors of +' |
|
2833 |
||
2834 |
NewSystemBrowser browseImplementorsOf:#+ |
|
2835 |
in:(Array with:Number |
|
2836 |
with:Float |
|
2837 |
with:SmallInteger) |
|
2838 |
title:'some implementors of +' |
|
2839 |
" |
|
2840 |
||
2841 |
"Modified: / 4.9.1995 / 17:33:39 / claus" |
|
2842 |
"Modified: / 19.6.1996 / 14:19:02 / stefan" |
|
2843 |
"Modified: / 5.11.2001 / 17:30:38 / cg" |
|
2844 |
! |
|
2845 |
||
2846 |
browseImplementorsMatching:aSelectorString in:aCollectionOfClasses title:title |
|
2847 |
"launch a browser for all implementors of aSelector in |
|
2848 |
the classes contained in aCollectionOfClasses and its metaclasses" |
|
2849 |
||
2850 |
^ self |
|
2851 |
browseImplementorsMatching:aSelectorString |
|
2852 |
in:aCollectionOfClasses |
|
2853 |
ignoreCase:false |
|
2854 |
title:title |
|
2855 |
! |
|
2856 |
||
2857 |
browseImplementorsMatching:aSelectorString under:aClass |
|
2858 |
"launch a browser for all implementors of aSelector in aClass |
|
2859 |
and its subclasses" |
|
2860 |
||
2861 |
^ self |
|
2862 |
browseImplementorsMatching:aSelectorString |
|
2863 |
in:(aClass withAllSubclasses) |
|
2864 |
title:(self classResources |
|
2865 |
string:'implementors of: %1 (in and below %2)' |
|
2866 |
with:aSelectorString |
|
2867 |
with:aClass name) |
|
2868 |
||
2869 |
" |
|
2870 |
SystemBrowser browseImplementorsOf:#+ under:Integer |
|
2871 |
NewSystemBrowser browseImplementorsOf:#+ under:Integer |
|
2872 |
" |
|
2873 |
||
2874 |
"Created: / 9.12.1995 / 18:06:09 / cg" |
|
2875 |
"Modified: / 5.11.2001 / 17:30:15 / cg" |
|
2876 |
! |
|
2877 |
||
52 | 2878 |
browseImplementorsOf:aSelectorString |
2879 |
"launch a browser for all implementors of aSelector" |
|
2880 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2881 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2882 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2883 |
in:(Smalltalk allClasses) |
52 | 2884 |
|
2885 |
" |
|
2886 |
SystemBrowser browseImplementorsOf:#+ |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2887 |
NewSystemBrowser browseImplementorsOf:#+ |
52 | 2888 |
" |
256 | 2889 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2890 |
"Created: / 9.12.1995 / 18:01:18 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2891 |
"Modified: / 5.11.2001 / 17:31:11 / cg" |
666 | 2892 |
! |
2893 |
||
2894 |
browseImplementorsOf:aSelectorString in:aSetOfClasses |
|
2895 |
"launch a browser for all implementors of aSelector" |
|
2896 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2897 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2898 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2899 |
in:aSetOfClasses |
8704 | 2900 |
title:(self classResources string:'Implementors of: %1' with:aSelectorString allBold) |
666 | 2901 |
|
2902 |
" |
|
2903 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2904 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
666 | 2905 |
" |
2906 |
||
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2907 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2908 |
"Modified: / 5.11.2001 / 17:30:57 / cg" |
52 | 2909 |
! |
2910 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2911 |
browseImplementorsOf:aSelectorString in:aSetOfClasses ignoreCase:ignoreCase |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2912 |
"launch a browser for all implementors of aSelector" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2913 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2914 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2915 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2916 |
in:aSetOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2917 |
ignoreCase:ignoreCase |
6476 | 2918 |
title:(self classResources string:'Implementors of: %1' with:aSelectorString) |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2919 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2920 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2921 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2922 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2923 |
" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2924 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2925 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
2926 |
"Modified: / 5.11.2001 / 17:30:43 / cg" |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2927 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2928 |
|
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2929 |
browseImplementorsOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase title:titleArg |
36 | 2930 |
"launch a browser for all implementors of aSelector in |
2931 |
the classes contained in aCollectionOfClasses and its metaclasses" |
|
2932 |
||
8688 | 2933 |
|list list2 rs selWithColon title top20 allSelectors choice| |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2934 |
|
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2935 |
title := titleArg. |
2642 | 2936 |
list := self |
4158 | 2937 |
findImplementorsOf:aSelectorString |
2642 | 2938 |
in:aCollectionOfClasses |
2939 |
ignoreCase:ignoreCase. |
|
45 | 2940 |
|
2642 | 2941 |
list size == 0 ifTrue:[ |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2942 |
aSelectorString numArgs == 0 ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2943 |
selWithColon := aSelectorString , ':'. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2944 |
selWithColon knownAsSymbol ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2945 |
list2 := self findImplementorsOf:selWithColon in:aCollectionOfClasses ignoreCase:ignoreCase. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2946 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2947 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2948 |
list2 size == 0 ifTrue:[ |
8678 | 2949 |
"/ self showNoneFound:title. |
2950 |
"/ ^ self |
|
8688 | 2951 |
allSelectors := Set new. |
8678 | 2952 |
top20 := SortedCollection new. |
2953 |
top20 sortBlock:[:a :b | (a spellAgainst:aSelectorString) > (b spellAgainst:aSelectorString)]. |
|
8759 | 2954 |
Smalltalk allMethodsWithSelectorDo:[:eachMethod :eachSelector | |
2955 |
(eachSelector spellAgainst:aSelectorString) > 50 ifTrue:[ |
|
2956 |
(allSelectors includes:eachSelector) ifFalse:[ |
|
2957 |
allSelectors add:eachSelector. |
|
2958 |
top20 add:eachSelector. |
|
2959 |
top20 size > 20 ifTrue:[ top20 removeLast. allSelectors := top20 asSet ]. |
|
2960 |
] |
|
8678 | 2961 |
] |
2962 |
]. |
|
9685
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2963 |
top20 isEmpty ifTrue:[ |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2964 |
|lcSelector| |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2965 |
|
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2966 |
lcSelector := aSelectorString asLowercase. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2967 |
Smalltalk allMethodsWithSelectorDo:[:eachMethod :eachSelector | |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2968 |
(eachSelector asLowercase spellAgainst:lcSelector) > 50 ifTrue:[ |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2969 |
(allSelectors includes:eachSelector) ifFalse:[ |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2970 |
allSelectors add:eachSelector. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2971 |
top20 add:eachSelector. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2972 |
top20 size > 20 ifTrue:[ top20 removeLast. allSelectors := top20 asSet ]. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2973 |
] |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2974 |
] |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2975 |
]. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2976 |
]. |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
2977 |
|
8678 | 2978 |
choice := Dialog |
8704 | 2979 |
choose:(title,' - none found.\\Browse implementors of a similar selector or cancel:' withCRs) |
8678 | 2980 |
fromList:top20 |
2981 |
lines:10. |
|
2982 |
choice notEmptyOrNil ifTrue:[ |
|
2983 |
self browseImplementorsOf:choice in:aCollectionOfClasses ignoreCase:ignoreCase title:'Implementors of ',choice. |
|
2984 |
]. |
|
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2985 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2986 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2987 |
rs := self classResources. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2988 |
(Dialog confirm:((rs string:title) , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2989 |
(rs string:'...\\... none found.') , |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2990 |
(rs string:'\\But I found %1 implementor(s) of the "%2" message (with colon).\\Browse those ?' |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2991 |
with:list2 size |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2992 |
with:selWithColon allBold)) withCRs) ifFalse:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2993 |
^ nil |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2994 |
]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2995 |
list := list2. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2996 |
title := title , ':'. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
2997 |
|
36 | 2998 |
]. |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
2999 |
|
270 | 3000 |
^ self browseMethods:list asOrderedCollection title:title |
36 | 3001 |
|
3002 |
" |
|
3003 |
SystemBrowser browseImplementorsOf:#+ |
|
270 | 3004 |
in:(Array with:Number |
3005 |
with:Float |
|
3006 |
with:SmallInteger) |
|
3007 |
title:'some implementors of +' |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3008 |
|
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3009 |
NewSystemBrowser browseImplementorsOf:#+ |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3010 |
in:(Array with:Number |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3011 |
with:Float |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3012 |
with:SmallInteger) |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3013 |
title:'some implementors of +' |
36 | 3014 |
" |
132 | 3015 |
|
9685
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3016 |
"Modified: / 04-09-1995 / 17:33:39 / claus" |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3017 |
"Modified: / 19-06-1996 / 14:19:02 / stefan" |
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
3018 |
"Modified: / 15-01-2011 / 14:35:56 / cg" |
36 | 3019 |
! |
3020 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3021 |
browseImplementorsOf:aSelectorString in:aCollectionOfClasses title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3022 |
"launch a browser for all implementors of aSelector in |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3023 |
the classes contained in aCollectionOfClasses and its metaclasses" |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3024 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3025 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3026 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3027 |
in:aCollectionOfClasses |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3028 |
ignoreCase:false |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3029 |
title:title |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3030 |
|
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3031 |
! |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3032 |
|
52 | 3033 |
browseImplementorsOf:aSelectorString under:aClass |
3034 |
"launch a browser for all implementors of aSelector in aClass |
|
3035 |
and its subclasses" |
|
3036 |
||
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3037 |
^ self |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3038 |
browseImplementorsOf:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3039 |
in:(aClass withAllSubclasses) |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3040 |
title:(self classResources |
6476 | 3041 |
string:'Implementors of: %1 (in and below %2)' |
2623
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3042 |
with:aSelectorString |
9e488daf53da
allow for senders/implementors to be searched with caseIgnore
Claus Gittinger <cg@exept.de>
parents:
2551
diff
changeset
|
3043 |
with:aClass name) |
52 | 3044 |
|
3045 |
" |
|
3046 |
SystemBrowser browseImplementorsOf:#+ under:Integer |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3047 |
NewSystemBrowser browseImplementorsOf:#+ under:Integer |
52 | 3048 |
" |
256 | 3049 |
|
3360
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3050 |
"Created: / 9.12.1995 / 18:06:09 / cg" |
2eab40d1a498
isMeta/soleInstance -> theNonMetaclass
Claus Gittinger <cg@exept.de>
parents:
3354
diff
changeset
|
3051 |
"Modified: / 5.11.2001 / 17:30:15 / cg" |
52 | 3052 |
! |
3053 |
||
3663 | 3054 |
browseImplementorsOfAny:setOfSelectors |
3055 |
"launch a browser for all implementors of aSelector" |
|
3056 |
||
3057 |
^ self |
|
3058 |
browseImplementorsOfAny:setOfSelectors |
|
3059 |
in:(Smalltalk allClasses) |
|
3060 |
||
3061 |
" |
|
3062 |
SystemBrowser browseImplementorsOfAny:#( #+ #- ) |
|
3063 |
NewSystemBrowser browseImplementorsOfAny:#( #+ #- ) |
|
3064 |
" |
|
3065 |
||
3066 |
"Created: / 9.12.1995 / 18:01:18 / cg" |
|
3067 |
"Modified: / 5.11.2001 / 17:31:11 / cg" |
|
3068 |
! |
|
3069 |
||
3070 |
browseImplementorsOfAny:setOfSelectors in:aSetOfClasses |
|
3071 |
"launch a browser for all implementors of aSelector" |
|
3072 |
||
8047
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3073 |
|title| |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3074 |
|
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3075 |
setOfSelectors size == 1 ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3076 |
title := self classResources |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3077 |
string:'Implementors of %1' |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3078 |
with:(setOfSelectors asOrderedCollection first). |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3079 |
] ifFalse:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3080 |
setOfSelectors size == 2 ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3081 |
title := self classResources |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3082 |
string:'Implementors of %1 or %2' |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3083 |
with:(setOfSelectors asOrderedCollection first) |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3084 |
with:(setOfSelectors asOrderedCollection second). |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3085 |
] ifFalse:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3086 |
title := self classResources string:'Implementors of some'. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3087 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3088 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3089 |
|
3663 | 3090 |
^ self |
3091 |
browseImplementorsOfAny:setOfSelectors |
|
3092 |
in:aSetOfClasses |
|
8047
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
3093 |
title:title |
3663 | 3094 |
|
3095 |
" |
|
3096 |
SystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3097 |
NewSystemBrowser browseImplementorsOf:#+ in:(Number withAllSubclasses) |
|
3098 |
" |
|
3099 |
||
3100 |
"Created: / 10.7.1996 / 10:20:59 / cg" |
|
3101 |
"Modified: / 5.11.2001 / 17:30:57 / cg" |
|
3102 |
! |
|
3103 |
||
3104 |
browseImplementorsOfAny:setOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase title:title |
|
3105 |
"launch a browser for all implementors of aSelector in |
|
3106 |
the classes contained in aCollectionOfClasses and its metaclasses" |
|
3107 |
||
3108 |
|list| |
|
3109 |
||
3110 |
list := self |
|
3111 |
findImplementorsOfAny:setOfSelectors |
|
3112 |
in:aCollectionOfClasses |
|
3113 |
ignoreCase:ignoreCase. |
|
3114 |
||
3115 |
list size == 0 ifTrue:[ |
|
3116 |
self showNoneFound:title. |
|
3117 |
^ nil |
|
3118 |
]. |
|
3119 |
||
3120 |
^ self browseMethods:list asOrderedCollection title:title |
|
3121 |
||
3122 |
" |
|
3123 |
SystemBrowser browseImplementorsOf:#+ |
|
3124 |
in:(Array with:Number |
|
3125 |
with:Float |
|
3126 |
with:SmallInteger) |
|
3127 |
title:'some implementors of +' |
|
3128 |
||
3129 |
NewSystemBrowser browseImplementorsOf:#+ |
|
3130 |
in:(Array with:Number |
|
3131 |
with:Float |
|
3132 |
with:SmallInteger) |
|
3133 |
title:'some implementors of +' |
|
3134 |
" |
|
3135 |
||
3136 |
"Modified: / 4.9.1995 / 17:33:39 / claus" |
|
3137 |
"Modified: / 19.6.1996 / 14:19:02 / stefan" |
|
3138 |
"Modified: / 5.11.2001 / 17:30:38 / cg" |
|
3139 |
! |
|
3140 |
||
3141 |
browseImplementorsOfAny:setOfSelectors in:aCollectionOfClasses title:title |
|
3142 |
"launch a browser for all implementors of aSelector in |
|
3143 |
the classes contained in aCollectionOfClasses and its metaclasses" |
|
3144 |
||
3145 |
^ self |
|
3146 |
browseImplementorsOfAny:setOfSelectors |
|
3147 |
in:aCollectionOfClasses |
|
3148 |
ignoreCase:false |
|
3149 |
title:title |
|
3150 |
! |
|
3151 |
||
203 | 3152 |
browseInstRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
3153 |
"launch a browser for all methods in aClass where the instVar named |
|
3154 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
3155 |
instvar is modified" |
|
45 | 3156 |
|
203 | 3157 |
^ self browseRefsTo:aString classVars:false in:aCollectionOfClasses modificationsOnly:modsOnly |
36 | 3158 |
! |
3159 |
||
203 | 3160 |
browseInstRefsTo:varName in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
3161 |
"launch a browser for all methods in aClass where the instVar named |
|
3162 |
varName is referenced; if modsOnly is true, browse only methods where the |
|
3163 |
instvar is modified" |
|
52 | 3164 |
|
203 | 3165 |
^ self browseRefsTo:varName classVars:false in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
52 | 3166 |
! |
3167 |
||
203 | 3168 |
browseInstRefsTo:aString under:aClass modificationsOnly:modsOnly |
3169 |
"launch a browser for all methods in aClass and subclasses |
|
3170 |
where the instVar named aString is referenced; |
|
3171 |
if modsOnly is true, browse only methods where the instvar is modified" |
|
36 | 3172 |
|
203 | 3173 |
^ self browseInstRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
36 | 3174 |
! |
3175 |
||
3176 |
browseReferendsOf:aGlobalName |
|
3177 |
"launch a browser for all methods referencing a global |
|
1367 | 3178 |
named aGlobalName. The argument may be a symbol, a string or |
3179 |
a matchPattern. |
|
36 | 3180 |
" |
3181 |
||
3182 |
^ self browseReferendsOf:aGlobalName warnIfNone:true |
|
3183 |
||
3184 |
" |
|
3185 |
Browser browseReferendsOf:#Transcript |
|
1367 | 3186 |
Browser browseReferendsOf:'Tr*' |
36 | 3187 |
" |
75 | 3188 |
|
1367 | 3189 |
"Modified: / 30.10.1997 / 23:45:52 / cg" |
36 | 3190 |
! |
3191 |
||
2409 | 3192 |
browseReferendsOf:aGlobalName ifNone:actionIfNone |
3193 |
"launch a browser for all methods referencing a global |
|
3194 |
named aGlobalName. |
|
3195 |
" |
|
3196 |
||
3197 |
^ self |
|
3198 |
browseReferendsOf:aGlobalName |
|
6476 | 3199 |
title:(self classResources string:'Users of: %1' with:aGlobalName) |
2409 | 3200 |
ifNone:actionIfNone |
3201 |
||
3202 |
"Modified: / 31.10.1997 / 15:42:05 / cg" |
|
3203 |
! |
|
3204 |
||
666 | 3205 |
browseReferendsOf:aGlobalName in:aSetOfClasses |
3206 |
"launch a browser for all methods referencing a global |
|
3207 |
named aGlobalName. |
|
3208 |
" |
|
3209 |
||
3210 |
^ self browseReferendsOf:aGlobalName in:aSetOfClasses warnIfNone:true |
|
3211 |
||
3212 |
" |
|
3213 |
Browser browseReferendsOf:#Transcript |
|
3214 |
" |
|
3215 |
||
3216 |
"Created: 10.7.1996 / 10:37:30 / cg" |
|
3217 |
! |
|
3218 |
||
3219 |
browseReferendsOf:aGlobalName in:aSetOfClasses warnIfNone:doWarn |
|
3220 |
"launch a browser for all methods referencing a global |
|
3221 |
named aGlobalName. |
|
3222 |
" |
|
3223 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3224 |
|globalsPlainName idx| |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3225 |
|
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3226 |
globalsPlainName := aGlobalName. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3227 |
(idx := globalsPlainName lastIndexOf:$:) ~~ 0 ifTrue:[ |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3228 |
globalsPlainName := globalsPlainName copyFrom:idx+1 |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3229 |
]. |
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3230 |
|
666 | 3231 |
^ self browseForSymbol:aGlobalName |
3232 |
in:aSetOfClasses |
|
6476 | 3233 |
title:(self classResources string:'Users of: %1' with:aGlobalName) |
666 | 3234 |
warnIfNone:doWarn |
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3235 |
searchFor:globalsPlainName |
666 | 3236 |
|
3237 |
"Created: 10.7.1996 / 10:37:02 / cg" |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
3238 |
"Modified: 31.10.1996 / 14:56:38 / cg" |
666 | 3239 |
! |
3240 |
||
2409 | 3241 |
browseReferendsOf:aGlobalName title:title ifNone:actionIfNone |
9002 | 3242 |
"launch a browser for all methods referencing a global named aGlobalName." |
3243 |
||
3244 |
|searchBlock browser| |
|
3245 |
||
3246 |
searchBlock := self searchBlockForReferendsOf:aGlobalName. |
|
3247 |
browser := self |
|
3248 |
browseMethodsWhere:searchBlock |
|
3249 |
title:title |
|
3250 |
ifNone:[ |
|
3251 |
actionIfNone value. |
|
3252 |
^ nil |
|
3253 |
]. |
|
3254 |
||
2828 | 3255 |
browser isNil ifTrue:[ |
3256 |
actionIfNone value |
|
3257 |
] ifFalse:[ |
|
9010
fa5c1fef4aef
changed: #browseReferendsOf:title:ifNone:
Claus Gittinger <cg@exept.de>
parents:
9007
diff
changeset
|
3258 |
browser autoSearchVariable:aGlobalName. |
2828 | 3259 |
]. |
3260 |
^ browser |
|
9002 | 3261 |
|
3262 |
" |
|
3263 |
Tools::NewSystemBrowser browseReferendsOf:'SortedCollection' title:'foo' ifNone:[ self halt ] |
|
3264 |
" |
|
2409 | 3265 |
! |
3266 |
||
3267 |
browseReferendsOf:aGlobalName title:title warnIfNone:doWarn |
|
3268 |
"launch a browser for all methods referencing a global |
|
3269 |
named aGlobalName. |
|
3270 |
" |
|
3271 |
||
2414 | 3272 |
|b| |
3273 |
||
3274 |
doWarn ifTrue: [ |
|
4158 | 3275 |
b := [self showNoneFound:title] |
2414 | 3276 |
]. |
3277 |
||
2409 | 3278 |
^ self |
3279 |
browseReferendsOf:aGlobalName |
|
3280 |
title:title |
|
2414 | 3281 |
ifNone:b |
2409 | 3282 |
|
1367 | 3283 |
! |
3284 |
||
3285 |
browseReferendsOf:aGlobalName warnIfNone:doWarn |
|
3286 |
"launch a browser for all methods referencing a global |
|
3287 |
named aGlobalName. |
|
3288 |
" |
|
3289 |
||
3290 |
^ self |
|
3291 |
browseReferendsOf:aGlobalName |
|
6476 | 3292 |
title:(self classResources string:'Users of: %1' with:aGlobalName) |
1367 | 3293 |
warnIfNone:doWarn |
3294 |
||
3295 |
"Modified: / 31.10.1997 / 15:42:05 / cg" |
|
203 | 3296 |
! |
3297 |
||
4198
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3298 |
browseReferendsOfUnboundGlobalsWithTitle:title ifNone:actionIfNone |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3299 |
"launch a browser for all methods referencing an unbound global. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3300 |
" |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3301 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3302 |
|globalsPlainName searchBlock browser| |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3303 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3304 |
searchBlock := [:cls :mthd :sel | |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3305 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3306 |
|mSource globals potentialNames| |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3307 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3308 |
"/ kludge: Lazy methods do not include symbols in the literal array - sigh |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3309 |
mthd isLazyMethod ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3310 |
mSource := mthd source. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3311 |
mSource notNil ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3312 |
globals := mthd usedGlobals. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3313 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3314 |
] ifFalse:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3315 |
"/ try hard to avoid the usedGlobals - its expensive |
6640 | 3316 |
potentialNames := mthd literals select:[:lit | lit isSymbol and:[lit size > 0 and:[lit isUppercaseFirst]]]. |
4198
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3317 |
potentialNames notEmpty ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3318 |
potentialNames := potentialNames select:[:lit | (Smalltalk at:lit) isNil]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3319 |
potentialNames notEmpty ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3320 |
globals := mthd usedGlobals. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3321 |
] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3322 |
] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3323 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3324 |
globals notNil ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3325 |
globals contains:[:aGlobalKey | (Smalltalk at:aGlobalKey asSymbol) isNil]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3326 |
] ifFalse:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3327 |
false |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3328 |
] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3329 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3330 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3331 |
browser := self browseMethodsWhere:searchBlock title:title ifNone:[actionIfNone value. ^ nil]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3332 |
browser isNil ifTrue:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3333 |
actionIfNone value |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3334 |
] ifFalse:[ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3335 |
browser autoSearch:globalsPlainName |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3336 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3337 |
^ browser |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3338 |
! |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3339 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3340 |
browseReferendsOfUnboundGlobalsWithTitle:title warnIfNone:doWarn |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3341 |
"launch a browser for all methods referencing an unbound global. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3342 |
" |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3343 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3344 |
|b| |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3345 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3346 |
doWarn ifTrue: [ |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3347 |
b := [self showNoneFound:title] |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3348 |
]. |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3349 |
|
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3350 |
^ self |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3351 |
browseReferendsOfUnboundGlobalsWithTitle:title |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3352 |
ifNone:b |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3353 |
! |
de8b73b42e1e
added browse refs to unbound globals.
Claus Gittinger <cg@exept.de>
parents:
4167
diff
changeset
|
3354 |
|
203 | 3355 |
browseRefsTo:aString classVars:classVars in:aCollectionOfClasses modificationsOnly:modsOnly |
3356 |
"launch a browser for all methods in aClass where the instVar/classVar named |
|
3357 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
3358 |
instvar is modified" |
|
3359 |
||
3360 |
|title| |
|
3361 |
||
3362 |
modsOnly ifTrue:[ |
|
6476 | 3363 |
title := 'Modifications of: %1' |
203 | 3364 |
] ifFalse:[ |
6476 | 3365 |
title := 'References to: %1 ' |
203 | 3366 |
]. |
3367 |
^ self |
|
256 | 3368 |
browseRefsTo:aString |
3369 |
classVars:classVars |
|
3370 |
in:aCollectionOfClasses |
|
3371 |
modificationsOnly:modsOnly |
|
3372 |
title:(self classResources string:title with:aString) |
|
3373 |
||
3374 |
"Created: 9.12.1995 / 18:07:05 / cg" |
|
3375 |
"Modified: 9.12.1995 / 18:11:49 / cg" |
|
203 | 3376 |
! |
3377 |
||
3378 |
browseRefsTo:varName classVars:classVars in:aCollectionOfClasses modificationsOnly:modsOnly title:title |
|
3379 |
"launch a browser for all methods in aClass where the instVar/classVar named |
|
3380 |
varName is referenced; if modsOnly is true, browse only methods where the |
|
3381 |
instvar is modified" |
|
3382 |
||
3383 |
|filter browser pattern| |
|
3384 |
||
3385 |
filter := self filterToSearchRefsTo:varName classVars:classVars modificationsOnly:modsOnly. |
|
2677 | 3386 |
browser := self browseMethodsIn:aCollectionOfClasses inst:true class:classVars where:filter title:title. |
203 | 3387 |
|
3388 |
browser notNil ifTrue:[ |
|
2677 | 3389 |
modsOnly ifTrue:[ |
3390 |
pattern := varName , ' :=' |
|
3391 |
] ifFalse:[ |
|
3392 |
pattern := varName |
|
3393 |
]. |
|
3394 |
browser autoSearch:pattern |
|
203 | 3395 |
]. |
3396 |
^ browser |
|
3397 |
! |
|
3398 |
||
3407 | 3399 |
browseSendersOf:aSelectorString |
3400 |
"launch a browser for all senders of aSelector" |
|
3401 |
||
3402 |
^ self browseAllCallsOn:aSelectorString |
|
3403 |
||
3404 |
" |
|
3405 |
SystemBrowser browseSendersOf:#+ |
|
7914 | 3406 |
UserPreferences current systemBrowserClass browseSendersOf:#+ |
3407 | 3407 |
" |
3408 |
||
3409 |
"Modified: / 10.7.1996 / 10:26:15 / cg" |
|
3410 |
"Created: / 13.11.2001 / 13:52:12 / cg" |
|
3411 |
! |
|
3412 |
||
256 | 3413 |
browseSuperCallsIn:aCollectionOfClasses title:title |
3414 |
"launch a browser for all super sends in aCollectionOfClasses" |
|
3415 |
||
742
2ef5e22d8983
code cleanup (unused vars eliminated)
Claus Gittinger <cg@exept.de>
parents:
675
diff
changeset
|
3416 |
|browser searchBlock| |
256 | 3417 |
|
3418 |
searchBlock := [:class :method :s | |
|
504 | 3419 |
|src parser| |
256 | 3420 |
|
504 | 3421 |
src := method source. |
2208
e077aa992f7a
check for nil source in #allCallsOn: (for methods where src in not available)
Claus Gittinger <cg@exept.de>
parents:
1937
diff
changeset
|
3422 |
(src notNil and:[src findString:'super']) ~~ 0 ifTrue:[ |
504 | 3423 |
parser := Parser |
2208
e077aa992f7a
check for nil source in #allCallsOn: (for methods where src in not available)
Claus Gittinger <cg@exept.de>
parents:
1937
diff
changeset
|
3424 |
parseMethod:src |
504 | 3425 |
in:class |
3426 |
ignoreErrors:true |
|
3427 |
ignoreWarnings:true. |
|
3428 |
||
7711 | 3429 |
(parser notNil and:[parser ~~ #Error and:[parser usesSuper]]) |
504 | 3430 |
] ifFalse:[ |
3431 |
false |
|
3432 |
] |
|
256 | 3433 |
]. |
3434 |
||
3435 |
browser := self browseMethodsIn:aCollectionOfClasses |
|
504 | 3436 |
where:searchBlock |
3437 |
title:title. |
|
256 | 3438 |
|
3439 |
browser notNil ifTrue:[ |
|
504 | 3440 |
browser autoSearch:'super' |
256 | 3441 |
]. |
3442 |
^ browser |
|
3443 |
||
504 | 3444 |
" |
3445 |
SystemBrowser |
|
3446 |
browseSuperCallsIn:(Array with:SortedCollection) |
|
3447 |
title:'superSends in SortedCollection' |
|
3448 |
" |
|
3449 |
||
7711 | 3450 |
"Created: / 23-11-1995 / 14:08:55 / cg" |
3451 |
"Modified: / 06-03-2007 / 14:00:12 / cg" |
|
256 | 3452 |
! |
3453 |
||
3454 |
browseSuperCallsUnder:aClass |
|
3455 |
"launch a browser for all supersends in aClass and subclasses" |
|
3456 |
||
3457 |
^ self browseSuperCallsIn:(aClass withAllSubclasses) |
|
6476 | 3458 |
title:(self classResources string:'Supersends (in and below %1)' with:aClass name) |
256 | 3459 |
|
3460 |
" |
|
3461 |
SystemBrowser browseSuperCallsUnder:Number |
|
3462 |
" |
|
3463 |
||
3464 |
"Created: 23.11.1995 / 12:06:06 / cg" |
|
3465 |
"Modified: 9.12.1995 / 18:11:59 / cg" |
|
3466 |
! |
|
3467 |
||
52 | 3468 |
browseUsesOf:aClass |
3469 |
|dict owners offsets |
|
3470 |
sz "{ Class: SmallInteger }" |
|
3471 |
n "{ Class: SmallInteger }" |
|
3472 |
removeSet newDict| |
|
3473 |
||
3474 |
owners := ObjectMemory whoReferencesInstancesOf:aClass. |
|
3475 |
||
3476 |
" |
|
3477 |
collect set of offsets in dict; key is class |
|
3478 |
" |
|
3479 |
dict := IdentityDictionary new. |
|
3480 |
owners do:[:someObject | |
|
4158 | 3481 |
|cls create| |
3482 |
||
3483 |
someObject isContext ifFalse:[ |
|
3484 |
" |
|
3485 |
someObject refers to an instance of aClass; |
|
3486 |
find out, which instVar(s) |
|
3487 |
" |
|
3488 |
cls := someObject class. |
|
3489 |
cls ~~ Array ifTrue:[ |
|
3490 |
n := cls instSize. |
|
3491 |
create := [|s| s := Set new. dict at:cls put:s. s]. |
|
3492 |
||
3493 |
1 to:n do:[:i | |
|
3494 |
|ref| |
|
3495 |
||
3496 |
ref := someObject instVarAt:i. |
|
3497 |
(ref isMemberOf:aClass) ifTrue:[ |
|
3498 |
offsets := dict at:cls ifAbsent:create. |
|
3499 |
offsets add:i. |
|
3500 |
] |
|
3501 |
]. |
|
3502 |
cls isVariable ifTrue:[ |
|
3503 |
cls isPointers ifTrue:[ |
|
3504 |
| idx "{ Class: SmallInteger }" | |
|
3505 |
||
3506 |
sz := someObject basicSize. |
|
3507 |
idx := 1. |
|
3508 |
[idx <= sz] whileTrue:[ |
|
3509 |
|ref| |
|
3510 |
||
3511 |
ref := someObject basicAt:idx. |
|
3512 |
(ref isMemberOf:aClass) ifTrue:[ |
|
3513 |
offsets := dict at:cls ifAbsent:create. |
|
3514 |
offsets add:0. |
|
3515 |
idx := sz |
|
3516 |
]. |
|
3517 |
idx := idx + 1 |
|
3518 |
] |
|
3519 |
] |
|
3520 |
] |
|
3521 |
] |
|
3522 |
] |
|
52 | 3523 |
]. |
3524 |
||
3525 |
" |
|
3526 |
merge with superclass refs |
|
3527 |
" |
|
3528 |
dict keysAndValuesDo:[:cls :set | |
|
4158 | 3529 |
cls allSuperclasses do:[:aSuperclass | |
3530 |
|superSet| |
|
3531 |
||
3532 |
superSet := dict at:aSuperclass ifAbsent:[]. |
|
3533 |
superSet notNil ifTrue:[ |
|
3534 |
|removeSet| |
|
3535 |
||
3536 |
superSet := dict at:aSuperclass. |
|
3537 |
removeSet := Set new. |
|
3538 |
set do:[:offset | |
|
3539 |
(superSet includes:offset) ifTrue:[ |
|
3540 |
removeSet add:offset |
|
3541 |
] |
|
3542 |
]. |
|
3543 |
set removeAll:removeSet |
|
3544 |
] |
|
3545 |
] |
|
52 | 3546 |
]. |
3547 |
||
3548 |
" |
|
3549 |
remove empty ones |
|
3550 |
" |
|
3551 |
removeSet := Set new. |
|
3552 |
dict keysAndValuesDo:[:cls :set | |
|
4158 | 3553 |
set isEmpty ifTrue:[ |
3554 |
removeSet add:cls |
|
3555 |
] |
|
52 | 3556 |
]. |
9334 | 3557 |
dict removeAllKeys:removeSet. |
52 | 3558 |
|
3559 |
" |
|
3560 |
replace the indices by real names |
|
3561 |
" |
|
3562 |
newDict := IdentityDictionary new. |
|
3563 |
dict keysAndValuesDo:[:cls :set | |
|
4158 | 3564 |
|newSet names| |
3565 |
||
3566 |
names := cls allInstVarNames. |
|
3567 |
newSet := set collect:[:index | |
|
3568 |
index == 0 ifTrue:['*indexed*'] ifFalse:[names at:index]. |
|
3569 |
]. |
|
3570 |
newDict at:cls put:newSet |
|
52 | 3571 |
]. |
3572 |
||
3573 |
newDict inspect |
|
3574 |
! |
|
3575 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3576 |
filterToSearchRefsTo:varName classVars:classVars access:accessType |
7914 | 3577 |
"return a searchblock for variable references (obsolete)" |
3578 |
||
3579 |
^ self |
|
3580 |
filterToSearchRefsTo:varName |
|
3581 |
instVars:(classVars not) |
|
3582 |
classVars:classVars |
|
3583 |
globals:false |
|
3584 |
access:accessType |
|
3585 |
! |
|
3586 |
||
3587 |
filterToSearchRefsTo:varName classVars:classVars modificationsOnly:modsOnly |
|
3588 |
"return a searchblock for variable references" |
|
3589 |
||
3590 |
^ self |
|
3591 |
filterToSearchRefsTo:varName |
|
3592 |
classVars:classVars |
|
3593 |
access:(modsOnly ifTrue:#write ifFalse:#readWrite) |
|
3594 |
! |
|
3595 |
||
3596 |
filterToSearchRefsTo:varName instVars:doInstVars classVars:doClassVars globals:doGlobals access:accessType |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3597 |
"return a searchblock for variable references" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3598 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3599 |
|searchBlock| |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3600 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3601 |
searchBlock := [:c :m :s | |
7914 | 3602 |
|src result parser vars instVars classVars globals needMatch| |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3603 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3604 |
needMatch := varName includesMatchCharacters. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3605 |
|
7914 | 3606 |
result := false. |
3607 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3608 |
src := m source. |
7914 | 3609 |
src notNil ifTrue:[ |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3610 |
needMatch ifFalse:[ |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3611 |
" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3612 |
before doing a slow parse, quickly scan the |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3613 |
methods source for the variables name ... |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3614 |
" |
7914 | 3615 |
(varName includes:$:) ifTrue:[ |
3616 |
result := (src findString:(varName copyFrom:(varName lastIndexOf:$:)+1)) ~~ 0. |
|
3617 |
] ifFalse:[ |
|
3618 |
result := (src findString:varName) ~~ 0. |
|
3619 |
]. |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3620 |
] ifTrue:[ |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3621 |
result := true. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3622 |
]. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3623 |
result ifTrue:[ |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3624 |
result := false. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3625 |
parser := Parser |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3626 |
parseMethod:src |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3627 |
in:c |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3628 |
ignoreErrors:true |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3629 |
ignoreWarnings:true. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3630 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3631 |
(parser notNil and:[parser ~~ #Error]) ifTrue:[ |
7914 | 3632 |
vars := Set new. |
3633 |
doInstVars ifTrue:[ |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3634 |
accessType == #read ifTrue:[ |
7914 | 3635 |
instVars := parser readInstVars |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3636 |
] ifFalse:[ |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3637 |
accessType == #write ifTrue:[ |
7914 | 3638 |
instVars := parser modifiedInstVars |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3639 |
] ifFalse:[ |
7914 | 3640 |
instVars := parser usedInstVars |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3641 |
] |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3642 |
]. |
7914 | 3643 |
vars addAll:instVars. |
3644 |
]. |
|
3645 |
doClassVars ifTrue:[ |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3646 |
accessType == #read ifTrue:[ |
7914 | 3647 |
classVars := parser readClassVars |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3648 |
] ifFalse:[ |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3649 |
accessType == #write ifTrue:[ |
7914 | 3650 |
classVars := parser modifiedClassVars |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3651 |
] ifFalse:[ |
7914 | 3652 |
classVars := parser usedClassVars |
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3653 |
] |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3654 |
]. |
7914 | 3655 |
vars addAll:classVars. |
3656 |
]. |
|
3657 |
doGlobals ifTrue:[ |
|
3658 |
accessType == #read ifTrue:[ |
|
3659 |
globals := parser readGlobals |
|
3660 |
] ifFalse:[ |
|
3661 |
accessType == #write ifTrue:[ |
|
3662 |
globals := parser modifiedGlobals |
|
3663 |
] ifFalse:[ |
|
3664 |
globals := parser usedGlobals |
|
3665 |
] |
|
3666 |
]. |
|
3667 |
vars addAll:globals. |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3668 |
]. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3669 |
vars size > 0 ifTrue:[ |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3670 |
needMatch ifTrue:[ |
7914 | 3671 |
result := vars contains:[:cv | (varName match:cv)] |
504 | 3672 |
] ifFalse:[ |
3673 |
result := vars includes:varName |
|
3674 |
] |
|
3675 |
] |
|
3676 |
]. |
|
3677 |
]. |
|
3678 |
]. |
|
3679 |
Processor yield. |
|
3680 |
result |
|
36 | 3681 |
]. |
203 | 3682 |
^ searchBlock |
504 | 3683 |
|
1190 | 3684 |
"Modified: 19.6.1997 / 18:27:57 / cg" |
2642 | 3685 |
! |
3686 |
||
2743
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3687 |
findAnyResourceIn:aCollectionOfClasses |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3688 |
"return a collection of all methods in aCollectionOfClasses containing any resource." |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3689 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3690 |
^ self findMethodsIn:aCollectionOfClasses where:[:c :m :sel | m hasResource ]. |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3691 |
|
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3692 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3693 |
SystemBrowser findAnyResourceIn:(ApplicationModel withAllSubclasses) |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3694 |
" |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3695 |
! |
4fa5e36bef74
code cleanup: moved iconMethods from BrowserView to SystemBrowser
Claus Gittinger <cg@exept.de>
parents:
2741
diff
changeset
|
3696 |
|
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3697 |
findClassRefsTo:aString in:aCollectionOfClasses access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3698 |
"return all methods in aCollectionOfClasses where the classVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3699 |
aString is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3700 |
if modsOnly is true, browse only methods where the classvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3701 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3702 |
^ self findRefsTo:aString classVars:true in:aCollectionOfClasses access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3703 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3704 |
|
2677 | 3705 |
findClassRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
2728 | 3706 |
"return all methods in aCollectionOfClasses where the classVar named |
2677 | 3707 |
aString is referenced; |
3708 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
3709 |
||
3710 |
^ self findRefsTo:aString classVars:true in:aCollectionOfClasses modificationsOnly:modsOnly |
|
3711 |
! |
|
3712 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3713 |
findClassRefsTo:aString inClass:aClass access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3714 |
"return all methods in aClass where the classVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3715 |
aString is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3716 |
if modsOnly is true, browse only methods where the classvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3717 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3718 |
^ self findRefsTo:aString classVars:true in:(Array with:aClass) access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3719 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3720 |
|
2728 | 3721 |
findClassRefsTo:aString inClass:aClass modificationsOnly:modsOnly |
3722 |
"return all methods in aClass where the classVar named |
|
3723 |
aString is referenced; |
|
3724 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
3725 |
||
3726 |
^ self findRefsTo:aString classVars:true in:(Array with:aClass) modificationsOnly:modsOnly |
|
3727 |
! |
|
3728 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3729 |
findClassRefsTo:aString under:aClass access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3730 |
"return all methods in aClass and subclasses |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3731 |
where the classVar named aString is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3732 |
if modsOnly is true, browse only methods where the classvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3733 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3734 |
^ self findClassRefsTo:aString in:(aClass withAllSubclasses) access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3735 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
3736 |
|
2677 | 3737 |
findClassRefsTo:aString under:aClass modificationsOnly:modsOnly |
3738 |
"return all methods in aClass and subclasses |
|
3739 |
where the classVar named aString is referenced; |
|
3740 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
3741 |
||
3742 |
^ self findClassRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
|
3743 |
||
3744 |
! |
|
3745 |
||
5094 | 3746 |
findCode:aCodeString in:aCollectionOfClasses isMethod:isMethod |
5243 | 3747 |
"return a collection of all methods in aCollectionOfClasses |
5094 | 3748 |
containing a matching piece of code. |
3749 |
This may be slow, since source-code has to be scanned." |
|
3750 |
||
3751 |
|searchBlock| |
|
3752 |
||
3753 |
searchBlock := self searchBlockForCode:aCodeString isMethod:isMethod. |
|
5226 | 3754 |
searchBlock isNil ifTrue:[ ^ nil]. |
5094 | 3755 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
3756 |
! |
|
3757 |
||
5243 | 3758 |
findCode:aCodeString inMethods:aCollectionOfMethods isMethod:isMethod |
3759 |
"return a collection of all methods in aCollectionOfMethods |
|
3760 |
containing a matching piece of code." |
|
3761 |
||
3762 |
|searchBlock| |
|
3763 |
||
3764 |
searchBlock := self searchBlockForCode:aCodeString isMethod:isMethod. |
|
3765 |
searchBlock isNil ifTrue:[ ^ nil]. |
|
3766 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
|
3767 |
! |
|
3768 |
||
9482 | 3769 |
findExceptionHandlersIn:aCollectionOfClasses |
3770 |
"return a collection of all methods in aCollectionOfClasses |
|
3771 |
containing an exception raiser. |
|
3772 |
This may be slow, since source-code has to be scanned." |
|
3773 |
||
3774 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher handlesException) in:aCollectionOfClasses |
|
3775 |
||
3776 |
"Modified: / 11-05-2010 / 16:18:55 / cg" |
|
3777 |
! |
|
3778 |
||
3779 |
findExceptionHandlersInMethods:aCollectionOfMethods |
|
3780 |
"return a collection of all methods in aCollectionOfClasses |
|
3781 |
containing an exception raiser. |
|
3782 |
This may be slow, since source-code has to be scanned." |
|
3783 |
||
3784 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher handlesException) inMethods:aCollectionOfMethods |
|
3785 |
||
3786 |
"Created: / 11-05-2010 / 16:20:48 / cg" |
|
3787 |
! |
|
3788 |
||
3789 |
findExceptionRaisersIn:aCollectionOfClasses |
|
3790 |
"return a collection of all methods in aCollectionOfClasses |
|
3791 |
containing an exception raiser. |
|
3792 |
This may be slow, since source-code has to be scanned." |
|
3793 |
||
3794 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher raisesException) in:aCollectionOfClasses |
|
3795 |
||
3796 |
"Modified: / 11-05-2010 / 16:18:48 / cg" |
|
3797 |
! |
|
3798 |
||
3799 |
findExceptionRaisersInMethods:aCollectionOfMethods |
|
3800 |
"return a collection of all methods in aCollectionOfClasses |
|
3801 |
containing an exception raiser. |
|
3802 |
This may be slow, since source-code has to be scanned." |
|
3803 |
||
3804 |
^ self findUsingParseTreeSearcher:(ParseTreeSearcher raisesException) inMethods:aCollectionOfMethods |
|
3805 |
||
3806 |
"Created: / 11-05-2010 / 16:20:36 / cg" |
|
3807 |
! |
|
3808 |
||
8129 | 3809 |
findHelpSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
3314 | 3810 |
"return a collection of all help-spec methods in aCollectionOfClasses |
3811 |
containing a string in their source. |
|
3812 |
This may be slow, since source-code has to be scanned." |
|
8129 | 3813 |
|
3814 |
^ self |
|
3815 |
findSpecMethodsFor:#help |
|
3816 |
withString:aString |
|
3817 |
in:aCollectionOfClasses |
|
3818 |
ignoreCase:ignoreCase |
|
3819 |
! |
|
3820 |
||
3821 |
findHelpSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
3822 |
"return a collection of all help-spec methods in aCollectionOfClasses |
|
3823 |
containing a string in their source. |
|
3824 |
This may be slow, since source-code has to be scanned." |
|
3825 |
||
3826 |
^ self |
|
3827 |
findSpecMethodsFor:#help |
|
3828 |
withString:aString |
|
3829 |
in:aCollectionOfClasses |
|
3830 |
ignoreCase:ignoreCase |
|
3831 |
match:doMatch |
|
3314 | 3832 |
! |
3833 |
||
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3834 |
findImplementors:aSelectorMatchString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
3675 | 3835 |
"search for all implementors of aSelector in |
3836 |
the classes contained in aCollectionOfClasses and its metaclasses. |
|
3837 |
Return a collection of methods" |
|
3838 |
||
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3839 |
|list compare testST testJava lcSelector| |
3675 | 3840 |
|
3841 |
list := IdentitySet new. |
|
6051 | 3842 |
aSelectorMatchString size == 0 ifTrue:[ ^ list ]. |
3843 |
||
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3844 |
doMatch ifTrue:[ |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3845 |
compare := [:sel :search | sel match:search]. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3846 |
] ifFalse:[ |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3847 |
compare := [:sel :search | sel = search]. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3848 |
]. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3849 |
|
3675 | 3850 |
ignoreCase == true ifTrue:[ |
3851 |
lcSelector := aSelectorMatchString asLowercase. |
|
3852 |
||
7847 | 3853 |
testST := [:aSelector :aMethod | (compare value:lcSelector value:(aMethod name ? '') asLowercase) ]. |
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3854 |
testJava := [:aSelector :aMethod | (compare value:aSelector value:aMethod name asLowercase) ]. |
3675 | 3855 |
] ifFalse:[ |
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3856 |
testST := [:aSelector :aMethod | (compare value:aSelectorMatchString value:aSelector) ]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3857 |
testJava := [:aSelector :aMethod | (compare value:aSelectorMatchString value:aMethod name) ]. |
3675 | 3858 |
]. |
3859 |
||
3860 |
aCollectionOfClasses do:[:aClass | |
|
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3861 |
|testBlock srchBlock| |
3675 | 3862 |
|
3863 |
aClass isObsolete ifFalse:[ |
|
3864 |
aClass isJavaClass ifTrue:[ |
|
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3865 |
testBlock := testJava |
3675 | 3866 |
] ifFalse:[ |
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3867 |
testBlock := testST |
3675 | 3868 |
]. |
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3869 |
srchBlock := [:sel :mthd | (testBlock value:sel value:mthd) ifTrue:[ list add:mthd]]. |
3675 | 3870 |
aClass methodDictionary keysAndValuesDo:srchBlock. |
3871 |
aClass isMeta ifFalse:[ |
|
3872 |
aClass class methodDictionary keysAndValuesDo:srchBlock |
|
3873 |
] |
|
3874 |
] |
|
3875 |
]. |
|
3876 |
||
3877 |
^ list |
|
3878 |
||
3879 |
" |
|
3880 |
SystemBrowser findImplementorsOf:#+ |
|
3881 |
in:(Array with:Number |
|
3882 |
with:Float |
|
3883 |
with:SmallInteger) |
|
3884 |
" |
|
7847 | 3885 |
|
3886 |
"Modified: / 20-09-2007 / 16:02:10 / cg" |
|
3675 | 3887 |
! |
3888 |
||
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3889 |
findImplementors:aSelectorMatchString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3890 |
"search for all implementors of aSelector in |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3891 |
the classes contained in aCollectionOfClasses and its metaclasses. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3892 |
Return a collection of methods" |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3893 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3894 |
|list compare testST testJava lcSelector| |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3895 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3896 |
list := IdentitySet new. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3897 |
aSelectorMatchString size == 0 ifTrue:[ ^ list ]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3898 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3899 |
doMatch ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3900 |
compare := [:sel :search | sel match:search]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3901 |
] ifFalse:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3902 |
compare := [:sel :search | sel = search]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3903 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3904 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3905 |
ignoreCase == true ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3906 |
lcSelector := aSelectorMatchString asLowercase. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3907 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3908 |
testST := [:aSelector :aMethod | (compare value:lcSelector value:aMethod name asLowercase) ]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3909 |
testJava := [:aSelector :aMethod | (compare value:aSelector value:aMethod name asLowercase) ]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3910 |
] ifFalse:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3911 |
testST := [:aSelector :aMethod | (compare value:aSelectorMatchString value:aSelector) ]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3912 |
testJava := [:aSelector :aMethod | (compare value:aSelectorMatchString value:aMethod name) ]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3913 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3914 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3915 |
aCollectionOfMethods do:[:eachMethod | |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3916 |
|cls sel testBlock| |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3917 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3918 |
cls := eachMethod mclass. |
7066 | 3919 |
(cls isNil or:[cls isObsolete]) ifFalse:[ |
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3920 |
cls isJavaClass ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3921 |
testBlock := testJava |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3922 |
] ifFalse:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3923 |
testBlock := testST |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3924 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3925 |
sel := eachMethod selector. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3926 |
(testBlock value:sel value:eachMethod) ifTrue:[ |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3927 |
list add:eachMethod |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3928 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3929 |
] |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3930 |
]. |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3931 |
|
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3932 |
^ list |
7066 | 3933 |
|
3934 |
"Modified: / 29-08-2006 / 14:33:42 / cg" |
|
6776
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3935 |
! |
5f5fd533b1f4
implementors of from implementors of-list
Claus Gittinger <cg@exept.de>
parents:
6705
diff
changeset
|
3936 |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3937 |
findImplementorsMatching:aSelectorMatchString in:aCollectionOfClasses ignoreCase:ignoreCase |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3938 |
"search for all implementors of aSelector in |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3939 |
the classes contained in aCollectionOfClasses and its metaclasses. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3940 |
Return a collection of methods" |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3941 |
|
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3942 |
^ self findImplementors:aSelectorMatchString in:aCollectionOfClasses ignoreCase:ignoreCase match:true |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3943 |
|
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3944 |
" |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3945 |
SystemBrowser findImplementorsOf:#+ |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3946 |
in:(Array with:Number |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3947 |
with:Float |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3948 |
with:SmallInteger) |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3949 |
" |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3950 |
! |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3951 |
|
3675 | 3952 |
findImplementorsMatchingAny:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
3953 |
"search for all implementors of any in aCollectionOfSelectors in |
|
3954 |
the classes contained in aCollectionOfClasses and its metaclasses. |
|
3955 |
Return a collection of methods. |
|
3956 |
CAVEAT: searches multiple times (could be tuned alot if heavily used)" |
|
3957 |
||
6052 | 3958 |
^ aCollectionOfSelectors |
3959 |
collectAll:[:eachSelector | |
|
3960 |
self findImplementorsMatching:eachSelector |
|
3961 |
in:aCollectionOfClasses |
|
3962 |
ignoreCase:ignoreCase. |
|
3963 |
]. |
|
3964 |
||
3965 |
"/ |implementors| |
|
3966 |
"/ |
|
6051 | 3967 |
"/ implementors := IdentitySet new. |
3968 |
"/ aCollectionOfSelectors do:[:eachSelector | |
|
3969 |
"/ implementors addAll:(self findImplementorsMatching:eachSelector in:aCollectionOfClasses ignoreCase:ignoreCase). |
|
3970 |
"/ ]. |
|
6052 | 3971 |
"/ ^ implementors |
6051 | 3972 |
|
3973 |
" |
|
3974 |
self |
|
3975 |
findImplementorsMatchingAny:#( 'at*:' '*size') |
|
3976 |
in:(Smalltalk allClasses) |
|
3977 |
ignoreCase:true |
|
3978 |
" |
|
3675 | 3979 |
! |
3980 |
||
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3981 |
findImplementorsOf:aSelectorMatchString in:aCollectionOfClasses ignoreCase:ignoreCase |
2642 | 3982 |
"search for all implementors of aSelector in |
3983 |
the classes contained in aCollectionOfClasses and its metaclasses. |
|
3984 |
Return a collection of methods" |
|
3985 |
||
6480 | 3986 |
^ self |
3987 |
findImplementors:aSelectorMatchString |
|
3988 |
in:aCollectionOfClasses |
|
3989 |
ignoreCase:ignoreCase |
|
3990 |
match:false |
|
2642 | 3991 |
|
3992 |
" |
|
3993 |
SystemBrowser findImplementorsOf:#+ |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3994 |
in:(Array with:Number |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3995 |
with:Float |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
3996 |
with:SmallInteger) |
2642 | 3997 |
" |
3998 |
! |
|
3999 |
||
2811 | 4000 |
findImplementorsOfAny:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
4001 |
"search for all implementors of any in aCollectionOfSelectors in |
|
4002 |
the classes contained in aCollectionOfClasses and its metaclasses. |
|
4003 |
Return a collection of methods. |
|
4004 |
CAVEAT: searches multiple times (could be tuned alot if heavily used)" |
|
4005 |
||
6052 | 4006 |
^ aCollectionOfSelectors |
4007 |
collectAll:[:eachSelector | |
|
4008 |
self findImplementorsOf:eachSelector |
|
4009 |
in:aCollectionOfClasses |
|
4010 |
ignoreCase:ignoreCase. |
|
4011 |
]. |
|
4012 |
||
4013 |
"/ |implementors| |
|
4014 |
"/ |
|
4015 |
"/ implementors := IdentitySet new. |
|
4016 |
"/ aCollectionOfSelectors do:[:eachSelector | |
|
4017 |
"/ implementors addAll:(self findImplementorsOf:eachSelector in:aCollectionOfClasses ignoreCase:ignoreCase). |
|
4018 |
"/ ]. |
|
4019 |
"/ ^ implementors |
|
2811 | 4020 |
! |
4021 |
||
2741 | 4022 |
findInstRefsTo:aString in:aCollectionOfClasses access:accessType |
4023 |
"return all methods in aCollectionOfClasses where the instVar named |
|
4024 |
aString is referenced; |
|
4025 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
4026 |
||
4027 |
^ self findRefsTo:aString classVars:false in:aCollectionOfClasses access:accessType |
|
4028 |
! |
|
4029 |
||
2677 | 4030 |
findInstRefsTo:aString in:aCollectionOfClasses modificationsOnly:modsOnly |
2728 | 4031 |
"return all methods in aCollectionOfClasses where the instVar named |
2677 | 4032 |
aString is referenced; if modsOnly is true, browse only methods where the |
4033 |
instvar is modified" |
|
4034 |
||
4035 |
^ self findRefsTo:aString classVars:false in:aCollectionOfClasses modificationsOnly:modsOnly |
|
4036 |
! |
|
4037 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4038 |
findInstRefsTo:aString inClass:aClass access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4039 |
"return all methods in aClass where the instVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4040 |
aString is referenced; if modsOnly is true, browse only methods where the |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4041 |
instvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4042 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4043 |
^ self findRefsTo:aString classVars:false in:(Array with:aClass) access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4044 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4045 |
|
2728 | 4046 |
findInstRefsTo:aString inClass:aClass modificationsOnly:modsOnly |
4047 |
"return all methods in aClass where the instVar named |
|
4048 |
aString is referenced; if modsOnly is true, browse only methods where the |
|
4049 |
instvar is modified" |
|
4050 |
||
4051 |
^ self findRefsTo:aString classVars:false in:(Array with:aClass) modificationsOnly:modsOnly |
|
4052 |
! |
|
4053 |
||
2741 | 4054 |
findInstRefsTo:aString under:aClass access:accessType |
4055 |
"return all methods in aClass and subclasses |
|
4056 |
where the classVar named aString is referenced; |
|
4057 |
if modsOnly is true, browse only methods where the classvar is modified" |
|
4058 |
||
4059 |
^ self findInstRefsTo:aString in:(aClass withAllSubclasses) access:accessType |
|
4060 |
! |
|
4061 |
||
2677 | 4062 |
findInstRefsTo:aString under:aClass modificationsOnly:modsOnly |
4063 |
"return all methods in aClass and subclasses |
|
4064 |
where the instVar named aString is referenced; |
|
4065 |
if modsOnly is true, browse only methods where the instvar is modified" |
|
4066 |
||
4067 |
^ self findInstRefsTo:aString in:(aClass withAllSubclasses) modificationsOnly:modsOnly |
|
4068 |
! |
|
4069 |
||
8129 | 4070 |
findMenuSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
3314 | 4071 |
"return a collection of all menu-spec methods in aCollectionOfClasses |
4072 |
containing a string in their source. |
|
4073 |
This may be slow, since source-code has to be scanned." |
|
8129 | 4074 |
|
4075 |
^ self |
|
4076 |
findSpecMethodsFor:#menu |
|
4077 |
withString:aString |
|
4078 |
in:aCollectionOfClasses |
|
4079 |
ignoreCase:ignoreCase |
|
4080 |
! |
|
4081 |
||
4082 |
findMenuSpecMethodsWithString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
4083 |
"return a collection of all menu-spec methods in aCollectionOfClasses |
|
4084 |
containing a string in their source. |
|
4085 |
This may be slow, since source-code has to be scanned." |
|
4086 |
||
4087 |
^ self |
|
4088 |
findSpecMethodsFor:#menu |
|
4089 |
withString:aString |
|
4090 |
in:aCollectionOfClasses |
|
4091 |
ignoreCase:ignoreCase |
|
4092 |
match:doMatch |
|
3314 | 4093 |
! |
4094 |
||
2736
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4095 |
findRefsTo:varName classVars:classVars in:aCollectionOfClasses access:accessType |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4096 |
"return a list of all methods in aCollectionOfClasses where the instVar/classVar named |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4097 |
varName is referenced; |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4098 |
if modsOnly is true, browse only methods where the instvar is modified" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4099 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4100 |
|filter| |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4101 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4102 |
filter := self filterToSearchRefsTo:varName classVars:classVars access:accessType. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4103 |
^ self findMethodsIn:aCollectionOfClasses inst:true class:classVars where:filter. |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4104 |
|
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4105 |
" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4106 |
self |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4107 |
findRefsTo:'x' |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4108 |
classVars:false |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4109 |
in:(Array with:Point) |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4110 |
modificationsOnly:true |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4111 |
" |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4112 |
! |
5b585170e14a
added search to find readers of an isntVar
Claus Gittinger <cg@exept.de>
parents:
2729
diff
changeset
|
4113 |
|
2677 | 4114 |
findRefsTo:varName classVars:classVars in:aCollectionOfClasses modificationsOnly:modsOnly |
4115 |
"return a list of all methods in aCollectionOfClasses where the instVar/classVar named |
|
4116 |
varName is referenced; |
|
4117 |
if modsOnly is true, browse only methods where the instvar is modified" |
|
4118 |
||
4119 |
|filter| |
|
4120 |
||
4121 |
filter := self filterToSearchRefsTo:varName classVars:classVars modificationsOnly:modsOnly. |
|
4122 |
^ self findMethodsIn:aCollectionOfClasses inst:true class:classVars where:filter. |
|
4123 |
||
4124 |
" |
|
4125 |
self |
|
4126 |
findRefsTo:'x' |
|
4127 |
classVars:false |
|
4128 |
in:(Array with:Point) |
|
4129 |
modificationsOnly:true |
|
4130 |
" |
|
4131 |
! |
|
4132 |
||
2692 | 4133 |
findResource:aResourceSymbolOrCollectionOfSymbols in:aCollectionOfClasses |
4134 |
"return a collection of all methods in aCollectionOfClasses |
|
4135 |
containing a resource." |
|
4136 |
||
4137 |
|searchBlock| |
|
4138 |
||
4139 |
aResourceSymbolOrCollectionOfSymbols isSymbol ifTrue:[ |
|
4140 |
searchBlock := [:c :m :sel | |resources| |
|
4141 |
(resources := m resources) size > 0 |
|
4142 |
and:[resources includesKey:aResourceSymbolOrCollectionOfSymbols] |
|
4143 |
]. |
|
4144 |
] ifFalse:[ |
|
4145 |
searchBlock := [:c :m :sel | |resources| |
|
4146 |
(resources := m resources) size > 0 |
|
4147 |
and:[resources keys includesAny:aResourceSymbolOrCollectionOfSymbols] |
|
4148 |
]. |
|
4149 |
]. |
|
4150 |
||
4151 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
|
4152 |
||
4153 |
" |
|
4154 |
SystemBrowser findResource:#image in:(ApplicationModel withAllSubclasses) |
|
4155 |
SystemBrowser findResource:#menu in:(ApplicationModel withAllSubclasses) |
|
4156 |
SystemBrowser findResource:#(menu programMenu) in:(ApplicationModel withAllSubclasses) |
|
4157 |
" |
|
4158 |
! |
|
4159 |
||
2642 | 4160 |
findSendersOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase |
4161 |
"search for all senders of aSelector in |
|
4162 |
the classes contained in aCollectionOfClasses and its metaclasses. |
|
4163 |
Return a collection of methods" |
|
4164 |
||
4270 | 4165 |
^ self allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:true |
2642 | 4166 |
|
4167 |
" |
|
4168 |
SystemBrowser findSendersOf:#+ |
|
4169 |
in:(Array with:Number |
|
4170 |
with:Float |
|
4171 |
with:SmallInteger) |
|
4172 |
ignoreCase:false |
|
4173 |
" |
|
4270 | 4174 |
! |
4175 |
||
4176 |
findSendersOf:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
4177 |
"search for all senders of aSelector in |
|
4178 |
the classes contained in aCollectionOfClasses and its metaclasses. |
|
4179 |
Return a collection of methods" |
|
4180 |
||
4181 |
^ self allCallsOn:aSelectorString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
4182 |
||
4183 |
" |
|
4184 |
SystemBrowser findSendersOf:#+ |
|
4185 |
in:(Array with:Number |
|
4186 |
with:Float |
|
4187 |
with:SmallInteger) |
|
4188 |
ignoreCase:false |
|
4189 |
" |
|
2675 | 4190 |
! |
4191 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4192 |
findSendersOf:aSelectorString inMethods:aCollectionOfMethods ignoreCase:ignoreCase |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4193 |
"search for all senders of aSelector in aCollectionOfMethods. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4194 |
Return a collection of methods" |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4195 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4196 |
|searchBlock| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4197 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4198 |
searchBlock := self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase. |
9313
44795fcbf414
changed: #findSendersOf:inMethods:ignoreCase:
Claus Gittinger <cg@exept.de>
parents:
9312
diff
changeset
|
4199 |
searchBlock isNil ifTrue:[^ #() ]. |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4200 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4201 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4202 |
|
4350 | 4203 |
findSendersOf:aSelectorString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
4204 |
"search for all senders of aSelector in aCollectionOfMethods. |
|
4205 |
Return a collection of methods" |
|
4206 |
||
4207 |
|searchBlock| |
|
4208 |
||
4209 |
searchBlock := self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:doMatch. |
|
9312
71f84182390a
changed: #findSendersOf:inMethods:ignoreCase:match:
Claus Gittinger <cg@exept.de>
parents:
9189
diff
changeset
|
4210 |
searchBlock isNil ifTrue:[^ #() ]. |
4350 | 4211 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
4212 |
! |
|
4213 |
||
2811 | 4214 |
findSendersOfAny:aCollectionOfSelectors in:aCollectionOfClasses ignoreCase:ignoreCase |
4215 |
"search for all senders of any selector in aCollectionOfSelectors in |
|
4216 |
the classes contained in aCollectionOfClasses and its metaclasses. |
|
4217 |
Return a collection of methods. |
|
4218 |
CAVEAT: searches multiple times (could be tuned alot if heavily used)" |
|
4219 |
||
6052 | 4220 |
^ aCollectionOfSelectors |
4221 |
collectAll:[:eachSelector | |
|
6184 | 4222 |
(self allCallsOn:eachSelector |
6052 | 4223 |
in:aCollectionOfClasses |
4224 |
ignoreCase:ignoreCase |
|
6184 | 4225 |
match:false) asSet. |
6052 | 4226 |
]. |
4227 |
||
4228 |
"/ |allSenders| |
|
4229 |
"/ |
|
4230 |
"/ allSenders := IdentitySet new. |
|
4231 |
"/ aCollectionOfSelectors do:[:eachSelector | |
|
4232 |
"/ allSenders addAll:(self allCallsOn:eachSelector in:aCollectionOfClasses ignoreCase:ignoreCase match:true) |
|
4233 |
"/ ]. |
|
4234 |
"/ ^ allSenders |
|
2811 | 4235 |
|
4236 |
" |
|
4237 |
SystemBrowser findSendersOfAny:#(#'+' #'-') |
|
4238 |
in:(Array with:Number |
|
4239 |
with:Float |
|
4240 |
with:SmallInteger) |
|
4241 |
ignoreCase:false |
|
4242 |
" |
|
4243 |
! |
|
4244 |
||
3314 | 4245 |
findSpecMethodsFor:specSymbol withString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
4246 |
"return a collection of all specSymbol-spec methods in aCollectionOfClasses |
|
4247 |
containing a string in their source. |
|
4248 |
This may be slow, since source-code has to be scanned." |
|
4249 |
||
8129 | 4250 |
self |
4251 |
findSpecMethodsFor:specSymbol |
|
4252 |
withString:aString |
|
4253 |
in:aCollectionOfClasses |
|
4254 |
ignoreCase:ignoreCase |
|
4255 |
match:true |
|
4256 |
! |
|
4257 |
||
4258 |
findSpecMethodsFor:specSymbol withString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
|
4259 |
"return a collection of all specSymbol-spec methods in aCollectionOfClasses |
|
4260 |
containing a string in their source. |
|
4261 |
This may be slow, since source-code has to be scanned." |
|
4262 |
||
4263 |
|searchBlock innerSearchBlock| |
|
4264 |
||
4265 |
innerSearchBlock := self searchBlockForString:aString ignoreCase:ignoreCase match:doMatch. |
|
4266 |
||
4267 |
searchBlock := [:c :m :sel | |
|
4268 |
|resources| |
|
3314 | 4269 |
|
4270 |
((resources := m resources) size > 0 |
|
4271 |
and:[resources includesKey:specSymbol]) ifTrue:[ |
|
8129 | 4272 |
innerSearchBlock value:c value:m value:sel |
3314 | 4273 |
] |
8129 | 4274 |
]. |
4275 |
||
3314 | 4276 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
4277 |
! |
|
4278 |
||
8129 | 4279 |
findString:aString in:aCollectionOfClasses ignoreCase:ignoreCase |
5243 | 4280 |
"return a collection of all methods in aCollectionOfClasses |
2675 | 4281 |
containing a string in their source. |
4282 |
This may be slow, since source-code has to be scanned." |
|
8129 | 4283 |
|
4284 |
^ self |
|
4285 |
findString:aString |
|
4286 |
in:aCollectionOfClasses |
|
4287 |
ignoreCase:ignoreCase |
|
4288 |
match:true |
|
4289 |
||
4290 |
" |
|
4291 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4292 |
" |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4293 |
! |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4294 |
|
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4295 |
findString:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
5243 | 4296 |
"return a collection of all methods in aCollectionOfClasses |
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4297 |
containing a string in their source. |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4298 |
This may be slow, since source-code has to be scanned." |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4299 |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4300 |
|searchBlock| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4301 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4302 |
searchBlock := self searchBlockForString:aString ignoreCase:ignoreCase match:doMatch. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4303 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4304 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4305 |
" |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4306 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4307 |
" |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4308 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4309 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4310 |
findString:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
5243 | 4311 |
"return a collection of all methods in aCollectionOfClasses |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4312 |
containing a string in their source. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4313 |
This may be slow, since source-code has to be scanned." |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4314 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4315 |
|searchBlock| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4316 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4317 |
searchBlock := self searchBlockForString:aString ignoreCase:ignoreCase match:doMatch. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4318 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4319 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4320 |
|
5877 | 4321 |
findStringLiteral:aString in:aCollectionOfClasses ignoreCase:ignoreCase match:doMatch |
4322 |
"return a collection of all methods in aCollectionOfClasses |
|
4323 |
containing a string in any of their string-literals." |
|
4324 |
||
4325 |
|searchBlock| |
|
4326 |
||
4327 |
searchBlock := self searchBlockForStringLiteral:aString ignoreCase:ignoreCase match:doMatch. |
|
4328 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
|
4329 |
||
4330 |
" |
|
4331 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
4332 |
" |
|
4333 |
! |
|
4334 |
||
4335 |
findStringLiteral:aString inMethods:aCollectionOfMethods ignoreCase:ignoreCase match:doMatch |
|
4336 |
"return a collection of all methods in aCollectionOfClasses |
|
4337 |
containing a string in any of their string-literals." |
|
4338 |
||
4339 |
|searchBlock| |
|
4340 |
||
4341 |
searchBlock := self searchBlockForStringLiteral:aString ignoreCase:ignoreCase match:doMatch. |
|
4342 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
|
4343 |
! |
|
4344 |
||
9482 | 4345 |
findUsingParseTreeSearcher:searcher in:aCollectionOfClasses |
4346 |
"return a collection of all methods in aCollectionOfClasses |
|
4347 |
containing an exception raiser. |
|
4348 |
This may be slow, since source-code has to be scanned." |
|
4349 |
||
4350 |
|searchBlock| |
|
4351 |
||
4352 |
searchBlock := self searchBlockForParseTreeSearcher:searcher isMethod:false. |
|
4353 |
searchBlock isNil ifTrue:[ ^ nil]. |
|
4354 |
^ self findMethodsIn:aCollectionOfClasses where:searchBlock. |
|
4355 |
||
4356 |
"Created: / 11-05-2010 / 16:18:36 / cg" |
|
4357 |
! |
|
4358 |
||
4359 |
findUsingParseTreeSearcher:searcher inMethods:aCollectionOfMethods |
|
4360 |
"return a collection of all methods in aCollectionOfClasses |
|
4361 |
containing an exception raiser. |
|
4362 |
This may be slow, since source-code has to be scanned." |
|
4363 |
||
4364 |
|searchBlock| |
|
4365 |
||
4366 |
searchBlock := self searchBlockForParseTreeSearcher:searcher isMethod:false. |
|
4367 |
searchBlock isNil ifTrue:[ ^ nil]. |
|
4368 |
^ aCollectionOfMethods select:[:m | searchBlock value:m mclass value:m value:m selector]. |
|
4369 |
||
4370 |
"Created: / 11-05-2010 / 16:20:12 / cg" |
|
4371 |
! |
|
4372 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4373 |
searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase |
4270 | 4374 |
^ self searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:true |
4375 |
! |
|
4376 |
||
4377 |
searchBlockForAllCallsOn:aSelectorString ignoreCase:ignoreCase match:doMatch |
|
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4378 |
|sel searchBlock lcString quickMatch| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4379 |
|
4270 | 4380 |
(doMatch |
4381 |
and:[(aSelectorString ~= '*') |
|
4382 |
and:[(aSelectorString includesMatchCharacters or:[ignoreCase])]]) ifTrue:[ |
|
8685
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4383 |
"/ a matchString or ignoreCase - need string matching procedure |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4384 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4385 |
ignoreCase ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4386 |
lcString := aSelectorString asLowercase. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4387 |
] ifFalse:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4388 |
lcString := aSelectorString. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4389 |
]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4390 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4391 |
quickMatch := aSelectorString. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4392 |
(quickMatch startsWith:'*') ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4393 |
quickMatch := quickMatch copyFrom:2 |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4394 |
]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4395 |
(quickMatch endsWith:'*') ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4396 |
quickMatch := quickMatch copyWithoutLast:1 |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4397 |
]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4398 |
(quickMatch includes:$:) ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4399 |
quickMatch := quickMatch copyTo:(quickMatch indexOf:$:)-1. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4400 |
]. |
8685
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4401 |
|
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4402 |
(ignoreCase not and:[quickMatch includesMatchCharacters not]) ifTrue:[ |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4403 |
searchBlock := [:class :method :s | |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4404 |
|src inLiterals| |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4405 |
|
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4406 |
inLiterals := false. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4407 |
method isLazyMethod ifTrue:[ |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4408 |
src := method source. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4409 |
(src notNil and:[src includesString:quickMatch]) ifTrue:[ |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4410 |
method makeRealMethod. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4411 |
inLiterals := (method |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4412 |
literalsDetect:[:aLiteral| |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4413 |
(aLiteral isMemberOf:Symbol) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4414 |
and:[(lcString includesString:quickMatch) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4415 |
and:[(lcString match:aLiteral)]]] |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4416 |
ifNone:nil) notNil |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4417 |
] |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4418 |
] ifFalse:[ |
8685
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4419 |
inLiterals := (method |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4420 |
literalsDetect:[:aLiteral| |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4421 |
(aLiteral isMemberOf:Symbol) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4422 |
and:[(lcString includesString:quickMatch) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4423 |
and:[(lcString match:aLiteral)]]] |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4424 |
ifNone:nil) notNil |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4425 |
]. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4426 |
inLiterals |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4427 |
and:[ method messagesSent contains:[:anySelector | aSelectorString match:anySelector ignoreCase:ignoreCase] ] |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4428 |
]. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4429 |
] ifFalse:[ |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4430 |
searchBlock := [:class :method :s | |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4431 |
|src inLiterals| |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4432 |
|
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4433 |
"/ expensive search |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4434 |
inLiterals := false. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4435 |
method isLazyMethod ifTrue:[ |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4436 |
src := method source. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4437 |
(src notNil and:[src includesMatchString:aSelectorString]) ifTrue:[ |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4438 |
method makeRealMethod. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4439 |
inLiterals := (method |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4440 |
literalsDetect:[:aLiteral| |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4441 |
(aLiteral isMemberOf:Symbol) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4442 |
and:[(ignoreCase and:[lcString match:aLiteral asLowercase]) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4443 |
or:[ignoreCase not and:[lcString match:aLiteral]]]] |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4444 |
ifNone:nil) notNil |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4445 |
] |
8685
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4446 |
] ifFalse:[ |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4447 |
inLiterals := (method literalsDetect:[:aLiteral| |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4448 |
(aLiteral isMemberOf:Symbol) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4449 |
and:[(ignoreCase and:[lcString match:aLiteral asLowercase]) |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4450 |
or:[ignoreCase not and:[lcString match:aLiteral]]]] |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4451 |
ifNone:nil) notNil |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4452 |
]. |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4453 |
inLiterals |
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4454 |
and:[ method messagesSent contains:[:anySelector | aSelectorString match:anySelector ignoreCase:ignoreCase] ] |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4455 |
]. |
8685
b39dc53c40ae
dont be too lazy in senders-search (do not return all accesses to
Claus Gittinger <cg@exept.de>
parents:
8678
diff
changeset
|
4456 |
]. |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4457 |
] ifFalse:[ |
4270 | 4458 |
(doMatch and:[aSelectorString = '*']) ifTrue:[ |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4459 |
searchBlock := [:class :method :s | true]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4460 |
] ifFalse:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4461 |
"/ no matchString - can do it much faster |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4462 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4463 |
sel := aSelectorString asSymbolIfInterned. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4464 |
sel isNil ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4465 |
^ nil "/ none |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4466 |
]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4467 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4468 |
quickMatch := sel. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4469 |
(quickMatch includes:$:) ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4470 |
quickMatch := quickMatch copyTo:(quickMatch indexOf:$:)-1. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4471 |
]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4472 |
searchBlock := [:class :method :s | |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4473 |
|src| |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4474 |
|
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4475 |
method isLazyMethod ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4476 |
src := method source. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4477 |
(src notNil and:[src includesString:quickMatch]) ifTrue:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4478 |
method makeRealMethod. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4479 |
method sends:sel. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4480 |
] ifFalse:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4481 |
false |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4482 |
] |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4483 |
] ifFalse:[ |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4484 |
method sends:sel |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4485 |
] |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4486 |
]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4487 |
] |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4488 |
]. |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4489 |
^ searchBlock |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4490 |
! |
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4491 |
|
5094 | 4492 |
searchBlockForCode:aCodeString isMethod:isMethod |
7395 | 4493 |
"return a block to search for a piece of code (intelligent search)." |
5094 | 4494 |
|
6581 | 4495 |
|errAction searchTree searcher globalVariablesUsed usedSymbols |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4496 |
sentMessages searchBlock foundMatch numMethodArgs methodSelector| |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4497 |
|
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4498 |
"/self halt. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4499 |
"/rule := ParseTreeLintRule |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4500 |
"/ createParseTreeRule: (Array with: aCodeString) |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4501 |
"/ method: isMethod |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4502 |
"/ name: 'Search for: ' , aCodeString. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4503 |
"/self halt. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4504 |
"/ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4505 |
"/ searchBlock := [:c :m :sel | |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4506 |
"/ rslt := SmalllintChecker |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4507 |
"/ runRule:rule |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4508 |
"/ onEnvironment: (ClassEnvironment onEnvironment:(BrowserEnvironment new) classes:(Array with:c)). |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4509 |
"/ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4510 |
"/ self halt. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4511 |
"/ ]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4512 |
"/^ searchBlock. |
5226 | 4513 |
|
4514 |
errAction := [:str :pos | |
|
4515 |
Dialog warn:'Error during parse: ' , str , ' (position ' , pos printString , ')'. |
|
4516 |
^ nil |
|
4517 |
]. |
|
5094 | 4518 |
|
4519 |
isMethod ifTrue:[ |
|
4520 |
searchTree := RBParser |
|
4521 |
parseRewriteMethod:aCodeString |
|
5226 | 4522 |
onError: errAction. |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4523 |
numMethodArgs := searchTree arguments size. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4524 |
methodSelector := searchTree selector. |
5094 | 4525 |
] ifFalse:[ |
4526 |
searchTree := RBParser |
|
4527 |
parseRewriteExpression:aCodeString |
|
5226 | 4528 |
onError: errAction. |
5094 | 4529 |
]. |
4530 |
||
6368 | 4531 |
Error handle:[:ex | |
4532 |
] do:[ |
|
6549 | 4533 |
sentMessages := searchTree sentMessages. |
5135 | 4534 |
]. |
6581 | 4535 |
|
6549 | 4536 |
globalVariablesUsed := searchTree referencedVariables |
5251
847d633792ce
tuned code search if global vars are involved
Claus Gittinger <cg@exept.de>
parents:
5243
diff
changeset
|
4537 |
select:[:node | |
847d633792ce
tuned code search if global vars are involved
Claus Gittinger <cg@exept.de>
parents:
5243
diff
changeset
|
4538 |
node isPatternNode not |
847d633792ce
tuned code search if global vars are involved
Claus Gittinger <cg@exept.de>
parents:
5243
diff
changeset
|
4539 |
and:[ Smalltalk includesKey: node name asSymbol ] |
847d633792ce
tuned code search if global vars are involved
Claus Gittinger <cg@exept.de>
parents:
5243
diff
changeset
|
4540 |
] |
847d633792ce
tuned code search if global vars are involved
Claus Gittinger <cg@exept.de>
parents:
5243
diff
changeset
|
4541 |
thenCollect:[:node | node name asSymbol]. |
5135 | 4542 |
|
6581 | 4543 |
usedSymbols := searchTree usedSymbols. |
4544 |
||
7395 | 4545 |
"/ cannot use literals to speedup the search, because stc does not store |
4546 |
"/ constants in the literal-array. |
|
4547 |
"/ literalsUsed := searchTree usedLiterals. |
|
4548 |
"/ literalsUsed := literalsUsed select:[:lit | lit isString]. |
|
4549 |
||
5094 | 4550 |
searcher := ParseTreeSearcher new. |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4551 |
isMethod ifTrue:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4552 |
searcher |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4553 |
matchesMethod:aCodeString |
5256
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4554 |
do:[:aNode :answer | foundMatch := true]. |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4555 |
] ifFalse:[ |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4556 |
searcher |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4557 |
matchesTree:searchTree |
c37bc91f2460
better none-found behavior for unary messages
Claus Gittinger <cg@exept.de>
parents:
5254
diff
changeset
|
4558 |
do:[:aNode :answer | foundMatch := true]. |
6303 | 4559 |
]. |
5094 | 4560 |
|
6581 | 4561 |
|
4562 |
searchBlock := [:c :m :sel | |
|
4563 |
|allSelectorsInLiteralArray allMessagesSent |
|
9544
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4564 |
allGlobalsReferenced allUsedSymbolsInLiteralArray allSent src rslt parseTree |
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4565 |
literalsInMethod| |
6581 | 4566 |
|
4567 |
foundMatch := false. |
|
4568 |
||
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4569 |
"/ can speedup the search, by filtering for number of message-args first... |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4570 |
(isMethod not |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4571 |
or:[ numMethodArgs isNil |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4572 |
or:[ numMethodArgs == m numArgs ]]) ifTrue:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4573 |
m isLazyMethod ifTrue:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4574 |
src := m source. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4575 |
src notNil ifTrue:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4576 |
m makeRealMethod. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4577 |
]. |
5135 | 4578 |
]. |
9544
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4579 |
"/ can speedup the search, by filtering for sent messages and used globals first... |
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4580 |
literalsInMethod := m literals. |
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4581 |
allSelectorsInLiteralArray := sentMessages isEmptyOrNil or:[ literalsInMethod includesAll:sentMessages ]. |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4582 |
allSelectorsInLiteralArray ifTrue:[ |
9544
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4583 |
allUsedSymbolsInLiteralArray := usedSymbols isEmptyOrNil or:[ literalsInMethod includesAll:usedSymbols ]. |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4584 |
allUsedSymbolsInLiteralArray ifTrue:[ |
8505
dd4cfeb8d6ad
allGlobalsReferenced before allMessagesSent in #searchBlockForCode:isMethod:
fm
parents:
8478
diff
changeset
|
4585 |
allGlobalsReferenced := globalVariablesUsed conform:[:varName | m referencesGlobal:varName]. |
dd4cfeb8d6ad
allGlobalsReferenced before allMessagesSent in #searchBlockForCode:isMethod:
fm
parents:
8478
diff
changeset
|
4586 |
allGlobalsReferenced ifTrue:[ |
dd4cfeb8d6ad
allGlobalsReferenced before allMessagesSent in #searchBlockForCode:isMethod:
fm
parents:
8478
diff
changeset
|
4587 |
allMessagesSent := sentMessages isEmptyOrNil or:[ m messages includesAll:sentMessages ]. |
dd4cfeb8d6ad
allGlobalsReferenced before allMessagesSent in #searchBlockForCode:isMethod:
fm
parents:
8478
diff
changeset
|
4588 |
allMessagesSent ifTrue:[ |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4589 |
allSent := sentMessages conform:[:sel | (m sends:sel)]. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4590 |
allSent ifTrue:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4591 |
src := m source. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4592 |
src isNil ifTrue:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4593 |
('Browser [info]: no source for ' , m printString) infoPrintCR. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4594 |
false |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4595 |
] ifFalse:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4596 |
parseTree := RBParser |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4597 |
parseSearchMethod:src |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4598 |
onError: [:str :pos | |
9544
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4599 |
self halt. |
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4600 |
Transcript show:'Error during search in '; showCR:m. |
8281
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4601 |
Transcript showCR:str. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4602 |
Transcript showCR:pos. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4603 |
nil]. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4604 |
|
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4605 |
parseTree notNil ifTrue:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4606 |
false "isMethod" ifTrue:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4607 |
rslt := searcher executeMethod:parseTree. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4608 |
] ifFalse:[ |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4609 |
rslt := searcher executeTree:parseTree. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4610 |
]. |
67f0cd20adf0
method-code search tuned: filter by number of methodArgs, if known.
Claus Gittinger <cg@exept.de>
parents:
8158
diff
changeset
|
4611 |
] |
6552
343882b29fec
code search bug - leftover foundMatch flag (must be cleared)
Claus Gittinger <cg@exept.de>
parents:
6549
diff
changeset
|
4612 |
] |
6368 | 4613 |
] |
4614 |
] |
|
5251
847d633792ce
tuned code search if global vars are involved
Claus Gittinger <cg@exept.de>
parents:
5243
diff
changeset
|
4615 |
] |
5135 | 4616 |
] |
6581 | 4617 |
] |
4618 |
]. |
|
4619 |
foundMatch. |
|
4620 |
]. |
|
5094 | 4621 |
^ searchBlock. |
7395 | 4622 |
|
9544
0947c3513df7
changed: #searchBlockForCode:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9483
diff
changeset
|
4623 |
"Modified: / 12-08-2010 / 11:03:36 / cg" |
5094 | 4624 |
! |
4625 |
||
9482 | 4626 |
searchBlockForParseTreeSearcher:searcher isMethod:isMethod |
4627 |
"return a block to search for a piece of code (intelligent search)." |
|
4628 |
||
4629 |
|errAction searchBlock foundMatch| |
|
4630 |
||
4631 |
errAction := [:str :pos | |
|
4632 |
Dialog warn:'Error during parse: ' , str , ' (position ' , pos printString , ')'. |
|
4633 |
^ nil |
|
4634 |
]. |
|
4635 |
||
4636 |
searchBlock := [:c :m :sel | |
|
9483
eead021c9729
changed: #searchBlockForParseTreeSearcher:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9482
diff
changeset
|
4637 |
|src parseTree| |
9482 | 4638 |
|
4639 |
foundMatch := false. |
|
4640 |
||
4641 |
m isLazyMethod ifTrue:[ |
|
4642 |
src := m source. |
|
4643 |
src notNil ifTrue:[ |
|
4644 |
m makeRealMethod. |
|
4645 |
]. |
|
4646 |
]. |
|
4647 |
||
4648 |
src := m source. |
|
4649 |
src isNil ifTrue:[ |
|
4650 |
('Browser [info]: no source for ' , m printString) infoPrintCR. |
|
4651 |
false |
|
4652 |
] ifFalse:[ |
|
4653 |
parseTree := RBParser |
|
4654 |
parseSearchMethod:src |
|
4655 |
onError: [:str :pos | |
|
4656 |
Transcript show:'Error in '; showCR:m. |
|
4657 |
Transcript showCR:str. |
|
4658 |
Transcript showCR:pos. |
|
4659 |
nil]. |
|
4660 |
||
4661 |
parseTree notNil ifTrue:[ |
|
9483
eead021c9729
changed: #searchBlockForParseTreeSearcher:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9482
diff
changeset
|
4662 |
foundMatch := searcher executeTree:parseTree initialAnswer:false. |
9482 | 4663 |
] |
4664 |
]. |
|
4665 |
foundMatch. |
|
4666 |
]. |
|
4667 |
||
4668 |
^ searchBlock. |
|
4669 |
||
4670 |
"Created: / 11-05-2010 / 16:14:25 / cg" |
|
9483
eead021c9729
changed: #searchBlockForParseTreeSearcher:isMethod:
Claus Gittinger <cg@exept.de>
parents:
9482
diff
changeset
|
4671 |
"Modified: / 11-05-2010 / 22:05:09 / cg" |
9482 | 4672 |
! |
4673 |
||
9002 | 4674 |
searchBlockForReferendsOf:aGlobalName |
4675 |
"return a block which searches for all methods which reference a global named aGlobalName, |
|
4676 |
which may be a matchpattern" |
|
4677 |
||
4678 |
|globalsPlainName idx matchingGlobalNames| |
|
4679 |
||
4680 |
globalsPlainName := aGlobalName. |
|
4681 |
(idx := globalsPlainName lastIndexOf:$:) ~~ 0 ifTrue:[ |
|
4682 |
globalsPlainName := globalsPlainName copyFrom:idx+1. |
|
4683 |
(globalsPlainName size == 0 |
|
4684 |
or:[globalsPlainName = '*']) ifTrue:[ |
|
4685 |
globalsPlainName := aGlobalName |
|
4686 |
] |
|
4687 |
]. |
|
4688 |
||
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4689 |
"/ matchingGlobalNames := OrderedCollection new. |
9002 | 4690 |
|
4691 |
aGlobalName includesMatchCharacters ifFalse:[ |
|
4692 |
^ [:cls :mthd :sel | |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4693 |
|sym1 sym2 mSource ok m| |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4694 |
|
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4695 |
sym1 := aGlobalName asSymbolIfInterned. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4696 |
sym2 := globalsPlainName asSymbolIfInterned. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4697 |
(sym1 isNil and:[ sym2 isNil ]) ifTrue:[ |
9002 | 4698 |
false |
4699 |
] ifFalse:[ |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4700 |
ok := false. |
9002 | 4701 |
"/ kludge: Lazy methods do not include symbols in the literal array - sigh |
4702 |
mthd isLazyMethod ifTrue:[ |
|
4703 |
mSource := mthd source. |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4704 |
(mSource notNil) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4705 |
(mSource includesString:sym2) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4706 |
(mthd usedGlobals includes:sym1) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4707 |
ok := true |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4708 |
] ifFalse:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4709 |
(mthd usedGlobals includes:sym2) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4710 |
ok := true |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4711 |
] |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4712 |
] |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4713 |
] |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4714 |
] |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4715 |
] ifFalse:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4716 |
(m := mthd) isWrapped ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4717 |
m := m originalMethod. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4718 |
]. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4719 |
|
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4720 |
((m refersToLiteral:sym1) or:[ (m refersToLiteral:sym2) ]) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4721 |
(m usedGlobals includes:sym1) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4722 |
ok := true |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4723 |
] ifFalse:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4724 |
(m usedGlobals includes:sym2) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4725 |
ok := true |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4726 |
]. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4727 |
]. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4728 |
]. |
9002 | 4729 |
] |
4730 |
] |
|
4731 |
]. |
|
4732 |
]. |
|
4733 |
||
4734 |
^ [:cls :mthd :sel | |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4735 |
|mSource usedGlobals global m| |
9002 | 4736 |
|
4737 |
"/ kludge: Lazy methods do not include symbols in the literal array - sigh |
|
4738 |
mthd isLazyMethod ifTrue:[ |
|
4739 |
mSource := mthd source. |
|
4740 |
mSource notNil ifTrue:[ |
|
4741 |
usedGlobals := mthd usedGlobals |
|
4742 |
] |
|
4743 |
] ifFalse:[ |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4744 |
(m := mthd) isWrapped ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4745 |
m := m originalMethod. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4746 |
]. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4747 |
(m literals contains:[:lit | (aGlobalName match:lit) or:[globalsPlainName match:lit]]) ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4748 |
usedGlobals := m usedGlobals |
9002 | 4749 |
]. |
4750 |
]. |
|
4751 |
usedGlobals notNil ifTrue:[ |
|
4752 |
global := usedGlobals detect:[:lit | aGlobalName match:lit] ifNone:nil. |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4753 |
global isNil ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4754 |
global := usedGlobals detect:[:lit | globalsPlainName match:lit] ifNone:nil. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4755 |
]. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4756 |
"/ global notNil ifTrue:[ |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4757 |
"/ matchingGlobalNames add:global. |
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4758 |
"/ ] |
9002 | 4759 |
]. |
4760 |
global notNil |
|
4761 |
]. |
|
9660
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4762 |
|
e8b452501452
changed: #searchBlockForReferendsOf:
Claus Gittinger <cg@exept.de>
parents:
9578
diff
changeset
|
4763 |
"Modified: / 08-12-2010 / 12:20:18 / cg" |
9002 | 4764 |
! |
4765 |
||
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4766 |
searchBlockForString:aString ignoreCase:ignoreCase match:doMatch |
5094 | 4767 |
"return a block to search for a string." |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4768 |
|
8129 | 4769 |
|searchBlock s| |
5891 | 4770 |
|
4771 |
(doMatch and:[ aString includesMatchCharacters ]) ifTrue:[ |
|
2675 | 4772 |
s := '*' , aString , '*'. |
4773 |
"a matchString" |
|
4774 |
searchBlock := [:c :m :sel | |
|
4775 |
|src| |
|
4776 |
src := m source. |
|
4777 |
src isNil ifTrue:[ |
|
4778 |
('Browser [info]: no source for ' , m printString) infoPrintCR. |
|
4779 |
false |
|
4780 |
] ifFalse:[ |
|
4781 |
s match:src ignoreCase:ignoreCase |
|
4782 |
] |
|
4783 |
] |
|
4784 |
] ifFalse:[ |
|
8129 | 4785 |
searchBlock := |
4786 |
[:c :m :sel | |
|
4787 |
|src| |
|
4788 |
||
4789 |
src := m source. |
|
4790 |
src isNil ifTrue:[ |
|
4791 |
('Browser [info]: no source for ' , m printString) infoPrintCR. |
|
4792 |
false |
|
4793 |
] ifFalse:[ |
|
4794 |
(src findString:aString ignoreCase:ignoreCase) ~~ 0 |
|
4795 |
] |
|
5891 | 4796 |
] |
2675 | 4797 |
]. |
4235
bba308f409dd
images & another special case startup
Claus Gittinger <cg@exept.de>
parents:
4222
diff
changeset
|
4798 |
^ searchBlock. |
2675 | 4799 |
|
4800 |
" |
|
4801 |
SystemBrowser findString:'should' in:(Array with:Object) ignoreCase:false |
|
4802 |
" |
|
4152
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4803 |
! |
92e3975f1904
allow for non-matching search (searching for impl. of '*')
Claus Gittinger <cg@exept.de>
parents:
4150
diff
changeset
|
4804 |
|
5877 | 4805 |
searchBlockForStringLiteral:aString ignoreCase:ignoreCase match:doMatch |
4806 |
"return a block to search for a string-literal." |
|
4807 |
||
4808 |
|searchBlock s| |
|
4809 |
||
5891 | 4810 |
(doMatch and:[ aString includesMatchCharacters]) ifTrue:[ |
5877 | 4811 |
s := '*' , aString , '*'. |
4812 |
"a matchString" |
|
4813 |
searchBlock := [:c :m :sel | |
|
4814 |
|lits| |
|
4815 |
lits := m literals ? #(). |
|
4816 |
lits contains:[:lit | |
|
4817 |
lit isString |
|
4818 |
and:[lit isSymbol not |
|
4819 |
and:[s match:lit ignoreCase:ignoreCase]] |
|
4820 |
] |
|
4821 |
] |
|
4822 |
] ifFalse:[ |
|
5891 | 4823 |
ignoreCase ifTrue:[ |
4824 |
s := aString asLowercase. |
|
4825 |
searchBlock := [:c :m :sel | |
|
4826 |
|lits| |
|
4827 |
lits := m literals ? #(). |
|
4828 |
lits contains:[:lit | |
|
4829 |
lit isString |
|
4830 |
and:[lit isSymbol not |
|
4831 |
and:[s = lit asLowercase]] |
|
4832 |
] |
|
4833 |
] |
|
4834 |
] ifFalse:[ |
|
4835 |
searchBlock := [:c :m :sel | |
|
4836 |
|lits| |
|
4837 |
lits := m literals ? #(). |
|
4838 |
lits contains:[:lit | |
|
4839 |
lit isString |
|
4840 |
and:[lit isSymbol not |
|
4841 |
and:[s = lit]] |
|
4842 |
] |
|
4843 |
] |
|
4844 |
]. |
|
5877 | 4845 |
]. |
4846 |
^ searchBlock. |
|
4847 |
||
4848 |
" |
|
4849 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:true |
|
4850 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:true match:false |
|
4851 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:true |
|
4852 |
SystemBrowser findStringLiteral:'error' in:(Array with:Object) ignoreCase:false match:false |
|
4853 |
" |
|
203 | 4854 |
! ! |
4855 |
||
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
4856 |
!SystemBrowser class methodsFor:'startup'! |
36 | 4857 |
|
203 | 4858 |
browseAllSelect:aBlock |
4859 |
"launch a browser for all methods where aBlock returns true. |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4860 |
The block is called with 3 arguments, class, method and selector." |
203 | 4861 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4862 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4863 |
browseMethodsWhere:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4864 |
title:'selected messages' |
36 | 4865 |
|
53 | 4866 |
" |
203 | 4867 |
SystemBrowser browseAllSelect:[:aClass :aMethod :selector | selector numArgs == 3] |
53 | 4868 |
" |
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4869 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4870 |
"Modified: 24.1.1997 / 19:45:05 / cg" |
203 | 4871 |
! |
75 | 4872 |
|
203 | 4873 |
browseClass:aClass |
4490 | 4874 |
"launch a browser for aClass. |
4875 |
Notice: better go via Smalltalk browseClass:, which honors the tool-preferences" |
|
203 | 4876 |
|
4877 |
^ self |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4878 |
newWithLabel:aClass name |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4879 |
setupSelector:#setupForClass: |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4880 |
arg:aClass |
203 | 4881 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4882 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4883 |
SystemBrowser browseClass:Object |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4884 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4885 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4886 |
"Modified: 24.1.1997 / 19:45:16 / cg" |
203 | 4887 |
! |
4888 |
||
4889 |
browseClass:aClass methodCategory:aCategory |
|
4890 |
"launch a browser for all methods under aCategory in aClass" |
|
4891 |
||
4892 |
^ self newWithLabel:(aClass name , ' ' , aCategory) |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4893 |
setupBlock:[:browser | browser setupForClass:aClass methodCategory:aCategory] |
203 | 4894 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4895 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4896 |
SystemBrowser browseClass:String methodCategory:'copying' |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4897 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4898 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4899 |
"Modified: 24.1.1997 / 19:45:23 / cg" |
203 | 4900 |
! |
4901 |
||
4902 |
browseClass:aClass selector:selector |
|
4490 | 4903 |
"launch a browser for the method at selector in aClass." |
203 | 4904 |
|
4905 |
^ self |
|
4158 | 4906 |
newWithLabel:(aClass name , ' ' , selector , ' ' , selector) |
4907 |
setupBlock:[:newBrowser | newBrowser setupForClass:aClass selector:selector] |
|
203 | 4908 |
|
4909 |
" |
|
4910 |
SystemBrowser browseClass:Object selector:#printString |
|
4911 |
" |
|
36 | 4912 |
! |
4913 |
||
203 | 4914 |
browseClassCategory:aClassCategory |
4915 |
"launch a browser for all classes under aCategory" |
|
4916 |
||
4917 |
^ self |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4918 |
newWithLabel:aClassCategory |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4919 |
setupSelector:#setupForClassCategory: |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4920 |
arg:aClassCategory |
203 | 4921 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4922 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4923 |
SystemBrowser browseClassCategory:'Kernel-Objects' |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4924 |
" |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4925 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
4926 |
"Modified: 24.1.1997 / 19:45:32 / cg" |
203 | 4927 |
! |
4928 |
||
4929 |
browseClassHierarchy:aClass |
|
4930 |
"launch a browser for aClass and all its superclasses. |
|
4931 |
this is different from the fullProtocol browser." |
|
36 | 4932 |
|
203 | 4933 |
^ self |
4158 | 4934 |
newWithLabel:(aClass name , '-' , 'hierarchy') |
4935 |
setupSelector:#setupForClassHierarchy: |
|
4936 |
arg:aClass |
|
203 | 4937 |
|
4938 |
" |
|
4939 |
SystemBrowser browseClassHierarchy:Number |
|
4940 |
" |
|
4941 |
! |
|
4942 |
||
8702 | 4943 |
browseClasses:aList label:title |
203 | 4944 |
"launch a browser for all classes in aList" |
4945 |
||
4946 |
^ self |
|
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4947 |
newWithLabel:title |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4948 |
setupBlock:[:b | b setupForClassList:aList sort:true] |
203 | 4949 |
|
4950 |
" |
|
4951 |
SystemBrowser browseClasses:(Array with:Object |
|
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4952 |
with:Float) |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4953 |
title:'two classes' |
203 | 4954 |
" |
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4955 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4956 |
"Modified: 28.5.1996 / 13:52:25 / cg" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4957 |
! |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4958 |
|
8702 | 4959 |
browseClasses:aList label:title sort:doSort |
576
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4960 |
"launch a browser for all classes in aList" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4961 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4962 |
^ self |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4963 |
newWithLabel:title |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4964 |
setupBlock:[:b | b setupForClassList:aList sort:doSort] |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4965 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4966 |
" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4967 |
SystemBrowser browseClasses:(Array with:Object |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4968 |
with:Float) |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4969 |
title:'two classes' |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4970 |
" |
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4971 |
|
62dc6c67d71c
show subclasses hierarchical (spawn subclasses)
Claus Gittinger <cg@exept.de>
parents:
573
diff
changeset
|
4972 |
"Created: 28.5.1996 / 13:52:09 / cg" |
52 | 4973 |
! |
4974 |
||
8702 | 4975 |
browseClasses:aList title:title |
4976 |
<resource: #obsolete> |
|
4977 |
"launch a browser for all classes in aList" |
|
4978 |
||
4979 |
self obsoleteMethodWarning. |
|
4980 |
^ self browseClasses:aList label:title |
|
4981 |
! |
|
4982 |
||
4983 |
browseClasses:aList title:title sort:doSort |
|
4984 |
<resource: #obsolete> |
|
4985 |
"launch a browser for all classes in aList" |
|
4986 |
||
4987 |
self obsoleteMethodWarning. |
|
4988 |
^ self browseClasses:aList label:title sort:doSort |
|
4989 |
||
4990 |
"Created: 28.5.1996 / 13:52:09 / cg" |
|
4991 |
! |
|
4992 |
||
203 | 4993 |
browseFullClassProtocol:aClass |
4994 |
"launch a browser for aClasses full protocol. |
|
4995 |
This is different from hierarchy browsing." |
|
4996 |
||
4997 |
^ self |
|
4158 | 4998 |
newWithLabel:(aClass name , '-' , 'full protocol') |
4999 |
setupSelector:#setupForFullClassProtocol: |
|
5000 |
arg:aClass |
|
203 | 5001 |
|
5002 |
" |
|
5003 |
SystemBrowser browseFullClassProtocol:Number |
|
5004 |
" |
|
5005 |
! |
|
36 | 5006 |
|
203 | 5007 |
browseFullClasses |
5008 |
"launch a browser showing all methods at once" |
|
5009 |
||
5010 |
^ self |
|
4158 | 5011 |
newWithLabel:'Full Class Browser' |
5012 |
setupBlock:[:newBrowser | newBrowser setupForFullClass] |
|
36 | 5013 |
|
203 | 5014 |
"SystemBrowser browseFullClasses" |
5015 |
! |
|
5016 |
||
5017 |
browseInstMethodsFrom:aClass where:aBlock title:title |
|
5018 |
"launch a browser for all instance methods in aClass and all subclasses |
|
5019 |
where aBlock evaluates to true" |
|
36 | 5020 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5021 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5022 |
browseMethodsIn:(aClass withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5023 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5024 |
class:false |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5025 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5026 |
title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5027 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5028 |
"Modified: 24.1.1997 / 19:44:45 / cg" |
203 | 5029 |
! |
5030 |
||
5031 |
browseInstMethodsIn:aCollectionOfClasses where:aBlock title:title |
|
5032 |
"launch a browser for all instance methods of all classes in |
|
5033 |
aCollectionOfClasses where aBlock evaluates to true" |
|
5034 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5035 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5036 |
browseMethodsIn:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5037 |
inst:true class:false |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5038 |
where:aBlock title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5039 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5040 |
"Modified: 24.1.1997 / 19:43:41 / cg" |
203 | 5041 |
! |
36 | 5042 |
|
203 | 5043 |
browseInstMethodsOf:aClass where:aBlock title:title |
5044 |
"launch a browser for all instance methods in aClass |
|
5045 |
where aBlock evaluates to true" |
|
5046 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5047 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5048 |
browseMethodsIn:(Array with:aClass) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5049 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5050 |
class:false |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5051 |
where:aBlock title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5052 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5053 |
"Modified: 24.1.1997 / 19:43:50 / cg" |
203 | 5054 |
! |
5055 |
||
5056 |
browseMethodCategory:aCategory |
|
5057 |
"launch a browser for all methods where category = aCategory" |
|
5058 |
||
5059 |
|searchBlock| |
|
5060 |
||
5061 |
aCategory includesMatchCharacters ifTrue:[ |
|
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5062 |
searchBlock := [:c :m :s | aCategory match:m category]. |
53 | 5063 |
] ifFalse:[ |
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5064 |
searchBlock := [:c :m :s | m category = aCategory] |
53 | 5065 |
]. |
5066 |
||
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5067 |
^ self browseMethodsWhere:searchBlock title:('all methods with category of ' , aCategory) |
203 | 5068 |
|
5069 |
" |
|
5070 |
SystemBrowser browseMethodCategory:'printing & storing' |
|
5071 |
SystemBrowser browseMethodCategory:'print*' |
|
5072 |
" |
|
5073 |
! |
|
5074 |
||
3666 | 5075 |
browseMethods:aListOfMethods |
5076 |
"launch a multi-method browser." |
|
5077 |
||
5078 |
^ self browseMethods:aListOfMethods title:'some methods' |
|
5079 |
||
5080 |
" |
|
5081 |
self |
|
5082 |
browseMethods:(Array with:(Array compiledMethodAt:#at:) |
|
5083 |
with:(OrderedCollection compiledMethodAt:#at:)) |
|
5084 |
||
5085 |
self |
|
5086 |
browseMethods:(Array with:(Array compiledMethodAt:#at:) |
|
5087 |
with:(Array compiledMethodAt:#at:put:)) |
|
5088 |
" |
|
5089 |
! |
|
5090 |
||
203 | 5091 |
browseMethods:aList title:aString |
5092 |
"launch a browser for an explicit list of class/selectors. |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5093 |
Each entry in the list can be either a method, or a string |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5094 |
consisting of the classes name and the selector, separated by spaces. |
634
24a678f81829
Change the name of a classes Metaclass from e.g. "SmallIntegerclass" to
Stefan Vogel <sv@exept.de>
parents:
620
diff
changeset
|
5095 |
For class methods, the string ' class' must be appended to the classname." |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5096 |
|
1919
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5097 |
^ self |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5098 |
browseMethods:aList |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5099 |
title:aString |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5100 |
sort:true |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5101 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5102 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5103 |
" |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5104 |
SystemBrowser |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5105 |
browseMethods:#('Object printOn:' 'Collection add:') |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5106 |
title:'some methods' |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5107 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5108 |
SystemBrowser |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5109 |
browseMethods:#('Behavior new:' 'Setclass new:') |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5110 |
title:'some new: methods' |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5111 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5112 |
SystemBrowser |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5113 |
browseMethods:(Array with:(Object compiledMethodAt:#printOn:) |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5114 |
with:(Collection compiledMethodAt:#add:) |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5115 |
with:(Object class compiledMethodAt:#initialize)) |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5116 |
title:'some methods' |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5117 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5118 |
" |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5119 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5120 |
"Modified: 1.11.1996 / 16:30:17 / cg" |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5121 |
! |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5122 |
|
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5123 |
browseMethods:aList title:aString sort:doSort |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5124 |
"launch a browser for an explicit list of class/selectors. |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5125 |
Each entry in the list can be either a method, or a string |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5126 |
consisting of the classes name and the selector, separated by spaces. |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5127 |
For class methods, the string ' class' must be appended to the classname." |
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5128 |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5129 |
|l| |
203 | 5130 |
|
5131 |
(aList size == 0) ifTrue:[ |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5132 |
self showNoneFound:aString. |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5133 |
^ nil |
203 | 5134 |
]. |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5135 |
l := aList asOrderedCollection. |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5136 |
l := l collect:[:entry | |
1937
fc541342f2db
more support for java code (implementors)
Claus Gittinger <cg@exept.de>
parents:
1931
diff
changeset
|
5137 |
|who cls clsName| |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5138 |
|
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5139 |
entry isString ifTrue:[ |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5140 |
entry |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5141 |
] ifFalse:[ |
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5142 |
cls := entry mclass. |
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5143 |
cls isNil ifTrue:[ |
1031 | 5144 |
'??? unbound' |
5145 |
] ifFalse:[ |
|
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5146 |
cls isJavaClass ifTrue:[ |
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5147 |
clsName := 'JAVA::' , cls fullName |
1937
fc541342f2db
more support for java code (implementors)
Claus Gittinger <cg@exept.de>
parents:
1931
diff
changeset
|
5148 |
] ifFalse:[ |
2822
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5149 |
clsName := cls name |
8127e7726fdd
changes for environment browsing
Claus Gittinger <cg@exept.de>
parents:
2818
diff
changeset
|
5150 |
]. |
7915 | 5151 |
(cls selectorAtMethod:entry) isNil ifTrue:[ |
5152 |
clsName |
|
5153 |
, ' ' |
|
5154 |
, '???' |
|
5155 |
] ifFalse:[ |
|
5156 |
clsName |
|
5157 |
, ' ' |
|
5158 |
, (entry printStringForBrowserWithSelector:(cls selectorAtMethod:entry) inClass:cls) |
|
5159 |
] |
|
1031 | 5160 |
] |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5161 |
] |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5162 |
]. |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5163 |
|
1919
0652e55065f9
added sort option to #browserMethods:
Claus Gittinger <cg@exept.de>
parents:
1703
diff
changeset
|
5164 |
doSort ifTrue:[l sort]. |
1937
fc541342f2db
more support for java code (implementors)
Claus Gittinger <cg@exept.de>
parents:
1931
diff
changeset
|
5165 |
|
203 | 5166 |
^ self |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5167 |
newWithLabel:aString |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5168 |
setupSelector:#setupForList: |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5169 |
arg:l |
53 | 5170 |
|
203 | 5171 |
" |
5172 |
SystemBrowser |
|
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5173 |
browseMethods:#('Object printOn:' 'Collection add:') |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5174 |
title:'some methods' |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5175 |
|
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5176 |
SystemBrowser |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5177 |
browseMethods:#('Behavior new:' 'Setclass new:') |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5178 |
title:'some new: methods' |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5179 |
|
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5180 |
SystemBrowser |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5181 |
browseMethods:(Array with:(Object compiledMethodAt:#printOn:) |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5182 |
with:(Collection compiledMethodAt:#add:) |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5183 |
with:(Object class compiledMethodAt:#initialize)) |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5184 |
title:'some methods' |
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5185 |
|
203 | 5186 |
" |
279
062022b53f22
allow browseMethods to be passed a collection of methodObjects (in addition to strings)
Claus Gittinger <cg@exept.de>
parents:
270
diff
changeset
|
5187 |
|
7711 | 5188 |
"Modified: / 17-06-1996 / 17:07:46 / stefan" |
5189 |
"Modified: / 05-03-2007 / 16:25:25 / cg" |
|
2826 | 5190 |
! |
53 | 5191 |
|
203 | 5192 |
browseMethodsFrom:aClass where:aBlock title:title |
5193 |
"launch a browser for all instance- and classmethods in aClass |
|
5194 |
and all its subclasses where aBlock evaluates to true. |
|
5195 |
The block is called with 3 arguments, class, method and seelctor." |
|
5196 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5197 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5198 |
browseMethodsIn:(aClass withAllSubclasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5199 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5200 |
title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5201 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5202 |
"Modified: 24.1.1997 / 19:44:00 / cg" |
203 | 5203 |
! |
5204 |
||
5205 |
browseMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock title:title |
|
5206 |
"launch a browser for all instance- (if wantInst is true) and/or |
|
5207 |
classmethods (if wantClass is true) from classes in aCollectionOfClasses, |
|
5208 |
where aBlock evaluates to true. |
|
270 | 5209 |
The block is called with 3 arguments, class, method and selector." |
203 | 5210 |
|
5211 |
|list| |
|
53 | 5212 |
|
5213 |
" |
|
203 | 5214 |
since this may take a long time, lower my priority ... |
53 | 5215 |
" |
2295
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
5216 |
Processor activeProcess |
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
5217 |
withPriority:Processor activePriority-1 to:Processor activePriority |
4e05198e7dd8
execute BG tasks at a prio range, to ensure progress.
Claus Gittinger <cg@exept.de>
parents:
2208
diff
changeset
|
5218 |
do:[ |
2675 | 5219 |
list := self findMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock |
203 | 5220 |
]. |
5221 |
^ self browseMethods:list title:title |
|
53 | 5222 |
! |
5223 |
||
3780 | 5224 |
browseMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock title:title ifNone:warnBlock |
5225 |
"launch a browser for all instance- (if wantInst is true) and/or |
|
5226 |
classmethods (if wantClass is true) from classes in aCollectionOfClasses, |
|
5227 |
where aBlock evaluates to true. |
|
5228 |
The block is called with 3 arguments, class, method and selector." |
|
5229 |
||
5230 |
|list| |
|
5231 |
||
5232 |
" |
|
5233 |
since this may take a long time, lower my priority ... |
|
5234 |
" |
|
5235 |
Processor activeProcess |
|
5236 |
withPriority:Processor activePriority-1 to:Processor activePriority |
|
5237 |
do:[ |
|
5238 |
list := self findMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock. |
|
5239 |
list size == 0 ifTrue:[warnBlock value]. |
|
5240 |
]. |
|
5241 |
^ self browseMethods:list title:title |
|
5242 |
! |
|
5243 |
||
203 | 5244 |
browseMethodsIn:aCollectionOfClasses where:aBlock title:title |
5245 |
"launch a browser for all instance- and classmethods from |
|
5246 |
all classes in aCollectionOfClasses where aBlock evaluates to true. |
|
5247 |
The block is called with 3 arguments, class, method and seelctor." |
|
53 | 5248 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5249 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5250 |
browseMethodsIn:aCollectionOfClasses |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5251 |
inst:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5252 |
class:true |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5253 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5254 |
title:title |
75 | 5255 |
|
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5256 |
"Modified: 24.1.1997 / 19:44:17 / cg" |
36 | 5257 |
! |
5258 |
||
3780 | 5259 |
browseMethodsIn:aCollectionOfClasses where:aBlock title:title ifNone:warnBlock |
5260 |
"launch a browser for all instance- and classmethods from |
|
5261 |
all classes in aCollectionOfClasses where aBlock evaluates to true. |
|
5262 |
The block is called with 3 arguments, class, method and seelctor." |
|
5263 |
||
5264 |
^ self |
|
5265 |
browseMethodsIn:aCollectionOfClasses |
|
5266 |
inst:true |
|
5267 |
class:true |
|
5268 |
where:aBlock |
|
5269 |
title:title |
|
5270 |
ifNone:warnBlock |
|
5271 |
||
5272 |
"Modified: 24.1.1997 / 19:44:17 / cg" |
|
5273 |
! |
|
5274 |
||
203 | 5275 |
browseMethodsOf:aClass where:aBlock title:title |
5276 |
"launch a browser for all instance- and classmethods in aClass |
|
5277 |
where aBlock evaluates to true. |
|
5278 |
The block is called with 3 arguments, class, method and seelctor." |
|
93 | 5279 |
|
203 | 5280 |
^ self browseMethodsIn:(Array with:aClass) where:aBlock title:title |
93 | 5281 |
! |
5282 |
||
203 | 5283 |
browseMethodsWhere:aBlock title:title |
5284 |
"launch a browser for all methods where aBlock returns true. |
|
5285 |
The block is called with 3 arguments, class, method and seelctor." |
|
5286 |
||
996
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5287 |
^ self |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5288 |
browseMethodsIn:(Smalltalk allClasses) |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5289 |
where:aBlock |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5290 |
title:title |
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5291 |
|
ed470d0b6029
more generic browseAll protocol;
Claus Gittinger <cg@exept.de>
parents:
929
diff
changeset
|
5292 |
"Modified: 24.1.1997 / 19:44:30 / cg" |
2675 | 5293 |
! |
5294 |
||
3780 | 5295 |
browseMethodsWhere:aBlock title:title ifNone:warnBlock |
5296 |
"launch a browser for all methods where aBlock returns true. |
|
5297 |
The block is called with 3 arguments, class, method and seelctor." |
|
5298 |
||
5299 |
^ self |
|
5300 |
browseMethodsIn:(Smalltalk allClasses) |
|
5301 |
where:aBlock |
|
5302 |
title:title |
|
5303 |
ifNone:warnBlock |
|
5304 |
||
5305 |
"Modified: 24.1.1997 / 19:44:30 / cg" |
|
5306 |
! |
|
5307 |
||
2675 | 5308 |
findMethodsIn:aCollectionOfClasses inst:wantInst class:wantClass where:aBlock |
5309 |
"return all instance- (if wantInst is true) and/or classmethods (if wantClass is true) |
|
5310 |
from classes in aCollectionOfClasses, where aBlock evaluates to true." |
|
5311 |
||
5312 |
|list checkedClasses checkBlock| |
|
5313 |
||
5314 |
checkedClasses := IdentitySet new. |
|
5315 |
list := OrderedCollection new. |
|
5316 |
||
5317 |
checkBlock := [:cls | |
|
5318 |
(checkedClasses includes:cls) ifFalse:[ |
|
8554
441ea25ad1fd
Do not complain about obsolete classes which are unloaded when searching
Stefan Vogel <sv@exept.de>
parents:
8505
diff
changeset
|
5319 |
(cls isObsolete and:[cls isLoaded]) ifTrue:[ |
2882 | 5320 |
Transcript showCR:'Browser method search: skipping obsolete class: ' , cls displayString |
2675 | 5321 |
] ifFalse:[ |
5322 |
cls methodDictionary keysAndValuesDo:[:sel :method | |
|
5323 |
(aBlock value:cls value:method value:sel) ifTrue:[ |
|
5324 |
list add:method "/ (cls name , ' ' , sel) |
|
5325 |
] |
|
5326 |
]. |
|
5327 |
checkedClasses add:cls. |
|
5328 |
] |
|
5329 |
] |
|
5330 |
]. |
|
5331 |
||
5332 |
aCollectionOfClasses do:[:aClass | |
|
3008 | 5333 |
(aClass notNil and:[aClass isObsolete not]) ifTrue:[ |
2675 | 5334 |
" |
5335 |
output disabled - it slows down things too much (when searching for |
|
5336 |
implementors or senders) |
|
5337 |
" |
|
5338 |
wantInst ifTrue:[ |
|
5339 |
"/ Transcript show:'searching '; show:aClass name; showCR:' ...'; endEntry. |
|
5340 |
checkBlock value:aClass |
|
5341 |
]. |
|
5342 |
wantClass ifTrue:[ |
|
5343 |
"/ Transcript show:'searching '; show:aClass class name; showCR:' ...'; endEntry. |
|
5344 |
checkBlock value:(aClass class) |
|
5345 |
]. |
|
5346 |
Processor yield |
|
5347 |
] |
|
5348 |
]. |
|
5349 |
^ list |
|
5350 |
! |
|
5351 |
||
5352 |
findMethodsIn:aCollectionOfClasses where:aBlock |
|
5353 |
"return all instance- and classmethods |
|
5354 |
from classes in aCollectionOfClasses, where aBlock evaluates to true." |
|
5355 |
||
5356 |
^ self |
|
5357 |
findMethodsIn:aCollectionOfClasses |
|
5358 |
inst:true |
|
5359 |
class:true |
|
5360 |
where:aBlock |
|
203 | 5361 |
! ! |
93 | 5362 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
5363 |
!SystemBrowser class methodsFor:'startup with query'! |
203 | 5364 |
|
5365 |
askThenBrowseClass |
|
5366 |
self getClassThenPerform:#browseClass: |
|
5367 |
||
5368 |
" |
|
5369 |
SystemBrowser askThenBrowseClass |
|
5370 |
" |
|
93 | 5371 |
! |
5372 |
||
203 | 5373 |
askThenBrowseClassHierarchy |
5374 |
self getClassThenPerform:#browseClassHierarchy: |
|
36 | 5375 |
|
203 | 5376 |
" |
5377 |
SystemBrowser askThenBrowseClassHierarchy |
|
5378 |
" |
|
36 | 5379 |
! |
5380 |
||
203 | 5381 |
askThenBrowseFullClassProtocol |
5382 |
self getClassThenPerform:#browseFullClassProtocol: |
|
36 | 5383 |
|
203 | 5384 |
" |
5385 |
SystemBrowser askThenBrowseFullClassProtocol |
|
5386 |
" |
|
52 | 5387 |
! |
5388 |
||
203 | 5389 |
getClassThenPerform:aSelector |
2729
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5390 |
|enterBox resources| |
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5391 |
|
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5392 |
resources := self classResources. |
52 | 5393 |
|
6353 | 5394 |
enterBox := EnterBox title:(self classResources stringWithCRs:'Browse which class:'). |
6640 | 5395 |
enterBox okText:(resources string:'Browse'). |
6873 | 5396 |
enterBox entryCompletionBlock:(DoWhatIMeanSupport classNameEntryCompletionBlock). |
203 | 5397 |
enterBox action:[:className | |
2729
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5398 |
|cls| |
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5399 |
|
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5400 |
cls := Smalltalk classNamed:className. |
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5401 |
cls isNil ifTrue:[ |
6640 | 5402 |
self warn:(resources string:'No such class'). |
2729
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5403 |
] ifFalse:[ |
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5404 |
self perform:aSelector with:cls |
9af04074a4bb
no direct access to super-class-instvars
Claus Gittinger <cg@exept.de>
parents:
2728
diff
changeset
|
5405 |
] |
203 | 5406 |
]. |
5407 |
enterBox showAtPointer |
|
75 | 5408 |
|
203 | 5409 |
" |
5410 |
SystemBrowser getClassThenPerform:#browseClass: |
|
5411 |
" |
|
6873 | 5412 |
|
5413 |
"Modified: / 10-08-2006 / 12:54:20 / cg" |
|
36 | 5414 |
! ! |
5415 |
||
2813 | 5416 |
!SystemBrowser class methodsFor:'utilities'! |
5417 |
||
3833 | 5418 |
classWithNameSimilarTo:className |
5419 |
"helper for class-name entry; finds a class by name tolerant w.r.t. case" |
|
5420 |
||
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5421 |
|allMatchingClasses| |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5422 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5423 |
allMatchingClasses := self classesWithNameSimilarTo:className. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5424 |
^ allMatchingClasses firstIfEmpty:nil |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5425 |
! |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5426 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5427 |
classesWithNameSimilarTo:className |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5428 |
"helper for class-name entry; finds a class by name tolerant w.r.t. case" |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5429 |
|
6944 | 5430 |
^ self classesWithNameSimilarTo:className from:nil |
5431 |
||
5432 |
"Modified: / 22-08-2006 / 13:22:41 / cg" |
|
5433 |
! |
|
5434 |
||
5435 |
classesWithNameSimilarTo:className from:aNameSpaceOrNil |
|
5436 |
"helper for class-name entry; finds classes with a name similar to the argument, className" |
|
5437 |
||
5438 |
|nm lcName class allClasses triedDetectors triedMatchers allMatchingClasses |
|
5439 |
prefNameSpaceOrNil prefLcNameSpace| |
|
5440 |
||
5441 |
prefNameSpaceOrNil := (aNameSpaceOrNil == Smalltalk) ifTrue:[ nil ] ifFalse:[aNameSpaceOrNil]. |
|
3833 | 5442 |
|
5443 |
(className startsWith:'Smalltalk::') ifTrue:[ |
|
5444 |
nm := className copyFrom:('Smalltalk::' size + 1). |
|
5445 |
] ifFalse:[ |
|
5446 |
nm := className. |
|
5447 |
]. |
|
5448 |
||
6944 | 5449 |
prefNameSpaceOrNil notNil ifTrue:[ |
5450 |
class := prefNameSpaceOrNil at:nm asSymbol. |
|
5451 |
class isBehavior ifTrue:[^ Array with:class]. "/ a direct hit |
|
5452 |
prefLcNameSpace := prefNameSpaceOrNil name asLowercase. |
|
5453 |
]. |
|
3833 | 5454 |
class := Smalltalk at:nm asSymbol. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5455 |
class isBehavior ifTrue:[^ Array with:class]. "/ a direct hit |
3833 | 5456 |
|
5457 |
lcName := className asLowercase. |
|
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5458 |
|
3833 | 5459 |
allClasses := Smalltalk allClasses. |
4806 | 5460 |
|
6134 | 5461 |
triedDetectors := OrderedCollection new. |
5462 |
triedDetectors add:[:cls | cls name asLowercase = lcName]. |
|
5463 |
||
5464 |
triedDetectors do:[:eachTry | |
|
5465 |
|class| |
|
5466 |
||
5467 |
class := allClasses detect:eachTry ifNone:nil. |
|
5468 |
class notNil ifTrue:[^ Array with:class]. |
|
5469 |
]. |
|
5470 |
||
4806 | 5471 |
triedMatchers := OrderedCollection new. |
5018
2fe02eac49c5
better classesWithNameSimilarTo
Claus Gittinger <cg@exept.de>
parents:
4924
diff
changeset
|
5472 |
triedMatchers add:[:cls | cls nameWithoutPrefix asLowercase = lcName]. |
2fe02eac49c5
better classesWithNameSimilarTo
Claus Gittinger <cg@exept.de>
parents:
4924
diff
changeset
|
5473 |
triedMatchers add:[:cls | cls nameWithoutNameSpacePrefix asLowercase = lcName]. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5474 |
|
4806 | 5475 |
triedMatchers add:[:cls | cls name asLowercase startsWith:lcName]. |
5476 |
triedMatchers add:[:cls | cls nameWithoutNameSpacePrefix asLowercase startsWith:lcName]. |
|
5477 |
triedMatchers add:[:cls | cls nameWithoutPrefix asLowercase startsWith:lcName]. |
|
5478 |
triedMatchers add:[:cls | cls nameWithoutPrefix asLowercase includesString:lcName]. |
|
6134 | 5479 |
triedMatchers add:[:cls | cls name asLowercase includesString:lcName]. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5480 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5481 |
allMatchingClasses := IdentitySet new. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5482 |
triedMatchers do:[:eachTry | |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5483 |
|matchingClasses| |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5484 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5485 |
matchingClasses := allClasses select:eachTry. |
6944 | 5486 |
"/ matchingClasses size == 1 ifTrue:[^ matchingClasses]. |
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5487 |
allMatchingClasses addAll:matchingClasses. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5488 |
]. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5489 |
allMatchingClasses isEmpty ifTrue:[^ #()]. |
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5490 |
|
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5491 |
allMatchingClasses := allMatchingClasses asOrderedCollection. |
6944 | 5492 |
allMatchingClasses |
5493 |
sort:[:a :b | |
|
5494 |
|lcNameA lcNameB da db distA distB | |
|
5495 |
||
5496 |
lcNameA := a name asLowercase. |
|
5497 |
lcNameB := b name asLowercase. |
|
5498 |
prefNameSpaceOrNil notNil ifTrue:[ |
|
5499 |
a nameSpace == prefNameSpaceOrNil ifTrue:[ |
|
5500 |
lcNameA := a nameWithoutNameSpacePrefix asLowercase. |
|
5501 |
]. |
|
5502 |
b nameSpace == prefNameSpaceOrNil ifTrue:[ |
|
5503 |
lcNameB := b nameWithoutNameSpacePrefix asLowercase. |
|
5504 |
]. |
|
5505 |
]. |
|
5506 |
||
5507 |
distA := da := lcName levenshteinTo:lcNameA. |
|
5508 |
distB := db := lcName levenshteinTo:lcNameB. |
|
5509 |
"prefer prefixes (i.e. classes whose name starts with what we search for)" |
|
5510 |
||
5511 |
(lcNameA startsWith:lcName) ifTrue:[ |
|
5512 |
distB := distB * 2 |
|
5513 |
]. |
|
5514 |
(lcNameB startsWith:lcName) ifTrue:[ |
|
5515 |
distA := distA * 2 |
|
5516 |
]. |
|
5517 |
distA < distB |
|
5518 |
]. |
|
4924
0d39bbc7203e
better search-class heuristics
Claus Gittinger <cg@exept.de>
parents:
4921
diff
changeset
|
5519 |
^ allMatchingClasses. |
6546 | 5520 |
|
5521 |
" |
|
6678 | 5522 |
self classesWithNameSimilarTo:'NewSystemBrowser' |
5523 |
self classesWithNameSimilarTo:'Moose::MSEAbstractOperator' |
|
6546 | 5524 |
" |
6944 | 5525 |
|
5526 |
"Created: / 22-08-2006 / 13:22:48 / cg" |
|
5527 |
"Modified: / 22-08-2006 / 14:53:38 / cg" |
|
3833 | 5528 |
! |
5529 |
||
2813 | 5530 |
extractClassAndSelectorFrom:aString into:aBlock |
5531 |
"given a string which can be either 'class>>sel' or |
|
5532 |
'class sel', extract className and selector, and call aBlock with |
|
5533 |
the result. |
|
5534 |
Useful to open browser on a method as selected in some documentation." |
|
5535 |
||
5536 |
|sel clsName isMeta sep s| |
|
5537 |
||
5538 |
sel := aString. |
|
5539 |
sel notNil ifTrue:[ |
|
5540 |
sel := sel asString withoutSeparators. |
|
5541 |
('*>>*' match:sel) ifTrue:[ |
|
5542 |
sep := $> |
|
5543 |
] ifFalse:[ |
|
5544 |
('* *' match:sel) ifTrue:[ |
|
5545 |
sep := Character space |
|
5546 |
] |
|
5547 |
]. |
|
5548 |
sep notNil ifTrue:[ |
|
5549 |
" |
|
5550 |
extract class/sel from selection |
|
5551 |
" |
|
5552 |
s := ReadStream on:sel. |
|
5553 |
clsName := s upTo:sep. |
|
5554 |
[s peek == sep] whileTrue:[s next]. |
|
5555 |
sel := s upToEnd. |
|
5556 |
||
5557 |
(clsName endsWith:' class') ifTrue:[ |
|
5558 |
isMeta := true. |
|
5559 |
clsName := clsName copyWithoutLast:6 "copyTo:(clsName size - 5)" |
|
5560 |
] ifFalse:[ |
|
5561 |
isMeta := false |
|
5562 |
]. |
|
5563 |
] |
|
5564 |
]. |
|
5565 |
aBlock value:clsName value:sel value:isMeta |
|
5566 |
||
5567 |
"Modified: / 17.6.1996 / 16:52:14 / stefan" |
|
5568 |
"Created: / 6.2.2000 / 00:51:51 / cg" |
|
5569 |
"Modified: / 6.2.2000 / 00:56:43 / cg" |
|
5570 |
! |
|
5571 |
||
5572 |
extractSelectorFrom:aString |
|
5573 |
"given an arbitrary string, try to extract a useful selector. |
|
5574 |
Useful to open browser on a selected code fragment." |
|
5575 |
||
8047
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5576 |
|s sel sel2 t| |
2813 | 5577 |
|
5578 |
aString isNil ifTrue:[^ nil]. |
|
5579 |
||
5580 |
s := aString asString string. |
|
5581 |
s := s withoutSeparators. |
|
5582 |
sel := s. |
|
5583 |
||
6705 | 5584 |
((sel endsWith:$:) |
5585 |
and:[sel knownAsSymbol]) ifTrue:[ |
|
5586 |
^ sel asSymbol |
|
5587 |
]. |
|
5588 |
||
2813 | 5589 |
t := Parser selectorInExpression:sel. |
5590 |
t notNil ifTrue:[ |
|
5591 |
sel := t |
|
5592 |
]. |
|
5593 |
(sel = s or:[sel isNil or:[t == #>>]]) ifTrue:[ |
|
5594 |
"oops - thats probably not what we want here ..." |
|
5595 |
self extractClassAndSelectorFrom:s into:[:c :s :m | |
|
5596 |
sel := s |
|
5597 |
] |
|
5598 |
]. |
|
8047
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5599 |
|
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5600 |
sel asSymbolIfInterned isNil ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5601 |
(sel startsWith:'#') ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5602 |
sel2 := sel copyFrom:2. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5603 |
((sel2 startsWith:'''') and:[(sel2 endsWith:'''')]) ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5604 |
sel2 := (sel2 copyFrom:2) copyWithoutLast:1 |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5605 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5606 |
sel2 asSymbolIfInterned notNil ifTrue:[ |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5607 |
^ sel2 |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5608 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5609 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5610 |
]. |
8bc319ff9ba7
better title in implementorsOfAny
Claus Gittinger <cg@exept.de>
parents:
7998
diff
changeset
|
5611 |
|
2813 | 5612 |
^ sel |
5613 |
||
5614 |
" |
|
5615 |
self extractSelectorFrom:'at:put:' |
|
5616 |
self extractSelectorFrom:'#at:put:' |
|
5617 |
self extractSelectorFrom:'at:something put:someValue' |
|
5618 |
self extractSelectorFrom:'self at:something put:someValue' |
|
5619 |
self extractSelectorFrom:'(self at:something put:someValue)' |
|
5620 |
self extractSelectorFrom:'[self at:something put:someValue] value' |
|
5621 |
self extractSelectorFrom:'Array>>at:put:' |
|
5622 |
" |
|
5623 |
||
5624 |
"Created: / 6.2.2000 / 00:49:44 / cg" |
|
5625 |
"Modified: / 6.2.2000 / 00:57:08 / cg" |
|
6560
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5626 |
! |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5627 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5628 |
resourceEditorClassFor:aResource |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5629 |
"resources are from a methods resource-info; |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5630 |
return an appropriate editor class." |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5631 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5632 |
(aResource == #canvas) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5633 |
^ UIPainter |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5634 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5635 |
(aResource == #menu) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5636 |
^ MenuEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5637 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5638 |
((aResource == #image) or:[aResource == #fileImage]) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5639 |
^ ImageEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5640 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5641 |
(aResource == #help) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5642 |
^ UIHelpTool |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5643 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5644 |
(aResource == #tableColumns) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5645 |
^ DataSetBuilder |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5646 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5647 |
(aResource == #tabList) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5648 |
^ TabListEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5649 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5650 |
(aResource == #hierarchicalList) ifTrue:[ |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5651 |
^ HierarchicalListEditor |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5652 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5653 |
^ nil |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5654 |
! |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5655 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5656 |
resourceEditorClassForResources:resources |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5657 |
"resources are from a methods resource-info; |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5658 |
return an appropriate editor class." |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5659 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5660 |
resources keysDo:[:eachResource | |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5661 |
|editor| |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5662 |
|
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5663 |
editor := self resourceEditorClassFor:eachResource. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5664 |
editor notNil ifTrue:[ ^ editor]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5665 |
]. |
80370d5aa971
share code between old and new browser
Claus Gittinger <cg@exept.de>
parents:
6552
diff
changeset
|
5666 |
^ nil |
2813 | 5667 |
! ! |
5668 |
||
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5669 |
!SystemBrowser::BrowserHistoryEntry methodsFor:'accessing'! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5670 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5671 |
className |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5672 |
"return the value of the instance variable 'className' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5673 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5674 |
^ className |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5675 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5676 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5677 |
className:something |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5678 |
"set the value of the instance variable 'className' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5679 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5680 |
className := something. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5681 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5682 |
|
3151 | 5683 |
className:classNameArg meta:metaArg selector:selectorArg |
5684 |
className := classNameArg. |
|
5685 |
meta := metaArg. |
|
5686 |
selector := selectorArg. |
|
5687 |
! |
|
5688 |
||
3131
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5689 |
meta |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5690 |
"return the value of the instance variable 'meta' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5691 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5692 |
^ meta |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5693 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5694 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5695 |
meta:something |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5696 |
"set the value of the instance variable 'meta' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5697 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5698 |
meta := something. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5699 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5700 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5701 |
selector |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5702 |
"return the value of the instance variable 'selector' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5703 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5704 |
^ selector |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5705 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5706 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5707 |
selector:something |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5708 |
"set the value of the instance variable 'selector' (automatically generated)" |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5709 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5710 |
selector := something. |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5711 |
! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5712 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5713 |
theClass |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5714 |
^ Smalltalk at:className asSymbol |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5715 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5716 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5717 |
!SystemBrowser::BrowserHistoryEntry methodsFor:'comparing'! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5718 |
|
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5719 |
= anEntry |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5720 |
^ className = anEntry className |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5721 |
and:[meta = anEntry meta |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5722 |
and:[selector = anEntry selector]] |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5723 |
! ! |
883d7b34bb86
history stuff refactored (common between old and new browser)
Claus Gittinger <cg@exept.de>
parents:
3125
diff
changeset
|
5724 |
|
820
2a412afad51d
fixed autoSearch, when searching for a private-classes name
Claus Gittinger <cg@exept.de>
parents:
742
diff
changeset
|
5725 |
!SystemBrowser class methodsFor:'documentation'! |
93 | 5726 |
|
203 | 5727 |
version |
9685
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
5728 |
^ '$Header: /cvs/stx/stx/libtool/SystemBrowser.st,v 1.287 2011-01-15 13:37:23 cg Exp $' |
8851 | 5729 |
! |
5730 |
||
5731 |
version_CVS |
|
9685
629e1d789a2d
changed: #browseImplementorsOf:in:ignoreCase:title:
Claus Gittinger <cg@exept.de>
parents:
9660
diff
changeset
|
5732 |
^ '$Header: /cvs/stx/stx/libtool/SystemBrowser.st,v 1.287 2011-01-15 13:37:23 cg Exp $' |
36 | 5733 |
! ! |
4112 | 5734 |
|
203 | 5735 |
SystemBrowser initialize! |