Open Bug 692348 Opened 13 years ago Updated 2 years ago

XUL panel doesn't become visible when children are added

Categories

(Core :: XUL, defect)

x86
macOS
defect

Tracking

()

People

(Reporter: mkaply, Unassigned)

Details

We have an autocomplete that uses a XUL panel.

We create the panel dynamically.

What we've discovered is that if we create the panel, show the panel and then add html divs to it dynamically, although the panel resizes (based on querying the width and height), it is never made visible.

If we explicitly set the height of the panel to 1 pixels, it works properly.

So it appears that if you show a panel using openPopup (the panel having no width/height), then add content to the panel dynamically, the panel still stays hidden. It is marked as .open, it just isn't shown.

I'm trying to put a testcase together for this, but it's part of a larger application.
I came across the same bug with the Firefox commandline devtool. If a panel has no size and no content it is not displayed by openPopup. When panels are dynamically created this can be an issue.

Setting the height attribute to a non-zero value allows to panel to be shown.

Seems to work fine on Linux but not on OSX or Windows.
Component: XUL → XP Toolkit/Widgets: XUL
Moving to Core:XUL per https://bugzilla.mozilla.org/show_bug.cgi?id=1455336
Component: XP Toolkit/Widgets: XUL → XUL
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.