[Dev] New block event dispatchEnumType
Bryan Stearns
stearns at osafoundation.org
Wed Nov 10 10:56:04 PST 2004
Hi John,
Donn made ToolbarItems act more like regular widgets, which allowed me to
push the stamping code down from the Markup Bar to a common base class that
the individual stamping ToolbarItems inherit from. This means the
ToolbarItems themselves want to receive the ButtonPressed event.
I didn't see an appropriate BlockEvent.dispatchEnumType to use for this:
SendToBlock is too specific, none of the Broadcast* ones fit, and the
existing ~BubbleUps started at blocks other than the event sender. So, I
added SelfBubbleUp - the new case in View.dispatchEvent() looks like:
elif dispatchEnum == 'SelfBubbleUp':
block = notification.data['sender']
bubbleUpCallMethod (block, methodName, notification)
Does this look reasonable?
...Bryan
More information about the Dev
mailing list