Closed Bug 10931 Opened 25 years ago Closed 24 years ago

Feature: onload() and onunload() should fire for xul overlays

Categories

(Core :: XUL, enhancement, P3)

enhancement

Tracking

()

RESOLVED WONTFIX

People

(Reporter: hangas, Assigned: hyatt)

Details

Attachments

(1 file)

It would be useful to have the onload and onunload handler fire for overlay
files.  Sometimes it is useful to have an overlay that the main window has no
knoledge of, in these cases there is no way to trigger an onload to fire for this
added xul.
Target Milestone: M9 → M10
Target Milestone: M10 → M14
moving to m14
As a workaround, do this:

  function OnLoad() {
    // do whatever here
  }

  setTimeout("OnLoad();", 0);
Status: ASSIGNED → RESOLVED
Closed: 25 years ago
Resolution: --- → WONTFIX
good enough for me.  i won't be implementing this then.
reopening:
using the code below, menuElement returns null unless (at least on my machine),
the delay in setTimeout is set to at least 2000.  This is completely
unacceptable.  OnLoad() should fire on load, there should be no need for a timeout.

function InitElement(ElementID)
{
  var menuElement=document.getElementById("menu" + ElementID);
}

function OnLoad()
{
    InitElement("PTBookmarks");
}
Status: RESOLVED → REOPENED
Resolution: WONTFIX → ---
Not if the element hasn't been merged in yet.  Besides, you can always manually 
add a load listener via script anyway using addEventListener.  There is no need 
for this functionality.

Status: REOPENED → RESOLVED
Closed: 25 years ago24 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: