Re: RFE: context info for user-defined events

Fair point...although don't forget that event('x') is referring to a
property on the DOM 2 Events' Event object, so no XML is involved.

On 08/02/07, Erik Bruchez <ebruchez@orbeon.com> wrote:
>
> Mark Birbeck wrote:
> >
> > John,
> >
> >> Several events include useful context information that can be accessed
> >> from XPath expressions using the `event()` function.  I would like to be
> >> able to add context information to events that are dispatched using the
> >> `xf:dispatch` element[0].
> >>
> >> [...]
> >
> >  <xf:setvalue ref="event('context')" value="instance('other')/context"/>
> >  <xf:setvalue ref="event('name')" value="@name"/>
> >  <xf:dispatch name="foo" target="m" />
>
> The question is then: what would event('blah') return? Especially if you
> dispatch a custom event for which no properties are predefined.
>
> I know you can make event('blah') create and return a text node or an
> element, but I have always found that kind of suggestions quite clunky,
> maybe partly because it is without precedent in any XML specification
> that I know of.
>
> -Erik
>
> --
> Orbeon Forms - Web Forms for the Enterprise Done the Right Way
> http://www.orbeon.com/
>
>
>


-- 
  Mark Birbeck, formsPlayer

  mark.birbeck@x-port.net * +44 (0) 20 7689 9232
  www.formsPlayer.com * internet-apps.blogspot.com

  standards. innovation.

Received on Thursday, 8 February 2007 22:27:42 UTC