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

<content> for image elements?

0 views
Skip to first unread message

StefanoC

unread,
Jul 9, 2009, 8:37:29 AM7/9/09
to
Hello!

if I attach a binding to an <img> tag, the anonymous <content> is well
created (i can see it with getAnonymousNode) but is not shown.
Only the original image is visible.

Is this a bug, is there a workaround?

PS.

simple example:

<binding id="image">
<content>
//this div is never shown
<xul:div style="border: 2px solid navy" class="xbl-image-
container">
<children/>
</xul:div>
</content>
<implementation>
<constructor>
<![CDATA[
//this exists
console.log
(w=document.getAnonymousElementByAttribute(this,'class', 'xbl-image-
container' ));
]]>
</constructor>
</implementation>
</binding>


thanks,
Stefano

Neil

unread,
Jul 9, 2009, 12:09:18 PM7/9/09
to
StefanoC wrote:

>if I attach a binding to an <img> tag, the anonymous <content> is well created (i can see it with getAnonymousNode) but is not shown. Only the original image is visible.
>
>Is this a bug, is there a workaround?
>

Isn't this normal behaviour for <img> with real child nodes? XBL doesn't
normally change that, but you can try extends="xul:box" (or
display="xul:box" if you are already using extends).

Also, <xul:div> looks confusing and may be mistaking for <html:div>
which is completely different. If you didn't mean <html:div> then you
should change it to <xul:hbox> or some such.

--
Warning: May contain traces of nuts.

0 new messages