[REBOL] Re: Adding an action to an existing event
From: brett:codeconscious at: 10-Aug-2002 11:57
> I looked into the feel-object of the field-style. I found out that the
> up-action i need for my purpose is not used.
> how can i add my up-action to the existing engage-event of the field-style
> whitout writing it completely new?
The easy part is to say, make a clone the object (so you do not affect
Engage is just a function. So if it makes sense you could save the old one
and write a new one that will do what you want, but call the old one (only
if a condition is met perhaps) - in a way chaining them.
Maybe this will work for you:
special-field: field with [
feel: make ctx-text/edit [
engage: func [face act event][
either 'up = act [
print "MOUSE UP"
ctx-text/edit/engage face act event
view layout [special-field]