Nicolas Cellier uploaded a new version of Protocols to project The Trunk:
http://source.squeak.org/trunk/Protocols-nice.31.mcz==================== Summary ====================
Name: Protocols-nice.31
Author: nice
Time: 11 June 2010, 10:25:29.352 pm
UUID: e97ce2a3-4051-df41-8509-f0995e86e74d
Ancestors: Protocols-fbs.30
Avoid using size == 0
=============== Diff against Protocols-fbs.30 ===============
Item was changed:
----- Method: Lexicon>>navigateToASender (in category 'senders') -----
navigateToASender
"Present the user with a list of senders of the currently-selected
message, and navigate to the chosen one"
| selectorSet chosen aSelector |
aSelector := self selectedMessageName.
selectorSet := Set new.
(self systemNavigation allCallsOn: aSelector)
do: [:anItem | selectorSet add: anItem methodSymbol].
selectorSet := selectorSet
select: [:sel | currentVocabulary
includesSelector: sel
forInstance: self targetObject
ofClass: targetClass
limitClass: limitClass].
+ selectorSet size = 0
- selectorSet size == 0
ifTrue: [^ Beeper beep].
self okToChange
ifFalse: [^ self].
chosen := UIManager default chooseFrom: selectorSet asSortedArray values: selectorSet asSortedArray.
chosen isEmptyOrNil
ifFalse: [self displaySelector: chosen]!