Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

is there a short cut to refer to the binding ancestor element ?

1 view
Skip to first unread message

rvj

unread,
May 9, 2010, 5:36:18 AM5/9/10
to
assuming a binding such as element may contain many embedded elements
through extends etc
and a handler such as

<handler event="click" action="mouseclick(event)"/>

is there a quick way to refer to the top most element (ancestor) ??

something like

alert("ancestor tag name is "+ancestor(event).tagName)


.... or do you have to add some kind of event capture + addevent listener
workaround

rvj

unread,
May 9, 2010, 5:47:59 AM5/9/10
to
please ignore

this!
"rvj" <r...@rolemodels.net> wrote in message
news:E-SdnR_LhdaNH3vW...@mozilla.org...

Philip Chee

unread,
May 11, 2010, 4:59:16 AM5/11/10
to
On Sun, 9 May 2010 10:36:18 +0100, rvj wrote:
> assuming a binding such as element may contain many embedded elements
> through extends etc
> and a handler such as
>
> <handler event="click" action="mouseclick(event)"/>
>
> is there a quick way to refer to the top most element (ancestor) ??

document.getBindingParent(this)

Phil


--
Philip Chee <phi...@aleytys.pc.my>, <phili...@gmail.com>
http://flashblock.mozdev.org/ http://xsidebar.mozdev.org
Guard us from the she-wolf and the wolf, and guard us from the thief,
oh Night, and so be good for us to pass.
[ ]I'm a programmer, I don't do COBOL.
* TagZilla 0.066.6

rvj

unread,
May 14, 2010, 10:37:12 AM5/14/10
to
many thanks


"Philip Chee" <phi...@aleytys.pc.my> wrote in message
news:3o7roa....@news.alt.net...

0 new messages