Closed
Bug 168875
Opened 22 years ago
Closed 21 years ago
img onload event is fired twice when switching the image from absolute to relative positioning
Categories
(Core :: DOM: Events, defect, P4)
Tracking
()
RESOLVED
FIXED
People
(Reporter: jl-mozilla, Assigned: joki)
References
()
Details
(Keywords: testcase)
Attachments
(1 file)
348 bytes,
text/html
|
Details |
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.1) Gecko/20020826 Build Identifier: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.1) Gecko/20020826 When I make an image and then have it absolutely positioned (so as to load it in the background, off screen and not effecting other elements), and then switch the image to relative positioning on the "onload" I get 2 onload events. It doesn't do this with other stylesheet changes (visibility, for example, which is my current work around but won't work in all cases). Reproducible: Always Steps to Reproduce: 1. Go to http://lynnsoft.2y.net:81/mozerr/err1.html 2. Inspect the source, it is a cut down version of this problem. Actual Results: You get the "Loaded" alert twice. It even looks like the image is rendered twice. Expected Results: It should have only fired the "onload" once, thus displaying the "Loaded" alert once.
Comment 1•22 years ago
|
||
Fjord, I get an access denied error when I try to access the url above. Can you please arrange to have that fixed. Or even better, attach your html testcase here (see create new attachment above)
Reporter | ||
Comment 2•22 years ago
|
||
Ok. I switched it to use an image on the mozilla server so clicking on the link here should show the problem. Don't know why you had access problems.
You need to log in
before you can comment on or make changes to this bug.
Description
•