On Tue, Apr 19, 2011 at 8:26 AM, Andreas Raab andreas.raab@gmx.de wrote:
On 4/19/2011 17:06, Tobias Pape wrote:
Curously, the buttons and the righ-click commands do not work, I suspect some OB-problems there.
Yes, definitely. It appears as if the culprit is in the combination of OBButtonBar>>buttonFor: aCommand which will substitute #yourself as action selector when the button is inactive. However, later, when the button should be updated we hit an optimization in OBButtonBar>>updateCommands which attempts to avoid the full recreation of the buttons and uses OBButtonBar>>updateButton:for: which does not update the action selector. Curiously, the latter method has my initials on it :-) so I'm taking a bit responsibility here. I think we should change OBButtonBar>>updateButton:for: to say:
updateButton: aButton for: aCommand
^aButton model: aCommand; setBalloonText: aCommand longDescription; action: (aCommand isActive ifTrue: [ #execute ] ifFalse: [ #yourself ]); yourself
I'm not sure where to push this fix.
The best place would be the OmniBrowser project on SqueakSource. It's world writable.
In this case though, don't bother, I'll just harvest the method above.
Colin