I would like to know whether it is possible to use XBL in javascript/XPCOM. I have managed to parse an XML document using xpcshell, but I do not see how to trigger XBL loading.
Do someone knows how to do that ?
Regards,
Philippe
_________________________________________________________________
Show them the way! Add maps and directions to your party invites.
http://www.microsoft.com/windows/windowslive/events.aspx
XBL is a presentation/behavior binding language. If you're not going to
have a presentation or behavior (e.g. if your document is just a DOM
tree in memory), you don't get XBL binding happening.
> I have managed to parse an XML document using xpcshell, but I do not see how to trigger XBL loading.
There's no presentation or behavior in xpcshell, right?
-Boris
Well, there is no presentation in xpcshell, this is true.
But there may be behaviour. I would like to invoke constructor/destructor, and the methods I wrote in my XBL file on the DOM elements.
Again my question: is this possible ?
Philippe
> Date: Sun, 28 Dec 2008 09:28:18 -0800
> From: bzba...@mit.edu
> Subject: Re: Using XBL in xpcom
> To: dev-te...@lists.mozilla.org
> _______________________________________________
> dev-tech-xbl mailing list
> dev-te...@lists.mozilla.org
> https://lists.mozilla.org/listinfo/dev-tech-xbl
_________________________________________________________________
Drag n’ drop—Get easy photo sharing with Windows Live™ Photos.
You can always load the XBL file, parse it, take the
constructor/destructor, wrap them into functions, eval to get function
objects, and call them.
Of course if your constructor or destructor depends on the anonymous
content of the binding, this won't work.
If the question is whether you can get binding attachment to happen in
your setup, that would require some serious changes to core code.
-Boris
You may want to consider an alternate technology, XTF:
http://weblogs.mozillazine.org/weirdal/archives/017902.html
Alex