[Cuis-dev] MessageNames improvement
Gerald Klix
cuis.01 at klix.ch
Tue Sep 1 12:59:07 PDT 2020
Hi all, hi Juan,
I noticed that the MessageNames browser shows matching classes and
global variables as message names (this might be unintended), but you can
not browse them or their class.
Please find enclosed a "selectedClassOrMetaClass" method for the
MessageNames class, that fixes this issue.
HTH and Best Regards,
Gerald
-------------- next part --------------
'From Cuis 5.0 [latest update: #4362] on 1 September 2020 at 9:51:00 pm'!
!MessageNames methodsFor: 'class list' stamp: 'KLG 9/1/2020 21:48:42'!
selectedClassOrMetaClass
"Answer the currently selected class (or metaclass).
If no method is selected, try to interpret the selected message name
as a class"
^ super selectedClassOrMetaClass ifNil: [
self selectedMessageName ifNotNil: [ :className | | mayBeClass |
(mayBeClass _ Smalltalk
at: className ifAbsent: [^ nil ]) isBehavior
ifTrue: [ mayBeClass ]
ifFalse: [ mayBeClass class ] ] ].! !
More information about the Cuis-dev
mailing list