April 25, 2012
12:17 p.m.
In the future we will have to look at respondsTo: and remove them because we should enforce for example that objects that are used have the right protocol |label| label := self checkboxLabelForText: aCheckbox label. (label respondsTo: #enabled:) ifTrue: [ label enabled: aCheckbox enabled]. label font: self labelFont. ^label On Apr 25, 2012, at 1:53 PM, Stéphane Ducasse wrote:
I see such idiom and I'm thinking that it would be good to fix such kind of respondsTo:
self allMorphsDo: [:m | (m ~= self and: [m respondsTo: #font:]) ifTrue: [m font: aFont]]
Stef