[REBOL] Re: Event redirection within face hierachies
From: antonr:lexicon at: 21-Jun-2004 1:18
Try out this simple redirection:
view layout [
b: button "hello"
button "there" feel [
engage: func [face action event][
b/feel/engage b event/type event
And here is a little doc I made (and will put on my rebsite later):
Event datatype breakdown:
You can spoof or emulate an event! by creating a
block and putting the relevent data in the correct
my-event: reduce ['down none 20x20 now/time/precise none none face none]
Most view functions won't know the difference because
they don't check to see if it's really an event datatype.
Here's a way that should respond to both the "indexed"
access method (ie. event/3) and the "named select" access method
event: reduce [none none 30x30 none none none none none 'offset 30x30]
This block has all the 8 values in the first 8 positions, and following
that, a name/value pair [offset 30x30].
If a function expecting an event! gets the above block instead,
it may get the offset through the path:
or via the path: