Closed
Bug 879807
Opened 12 years ago
Closed 12 years ago
Since release 21 FireFox does not show DHTML-Menu
Categories
(Tech Evangelism Graveyard :: German, defect)
Tech Evangelism Graveyard
German
Tracking
(firefox21 affected, firefox22-, firefox23-, firefox24-, firefox-esr17 unaffected)
RESOLVED
FIXED
Tracking | Status | |
---|---|---|
firefox21 | --- | affected |
firefox22 | - | --- |
firefox23 | - | --- |
firefox24 | - | --- |
firefox-esr17 | --- | unaffected |
People
(Reporter: Frank.Weichert, Unassigned)
References
Details
(Keywords: regression)
Attachments
(1 file)
18.12 KB,
text/html
|
Details |
User Agent: Mozilla/5.0 (Windows NT 5.1; rv:20.0) Gecko/20100101 Firefox/20.0 (Beta/Release)
Build ID: 20130409194949
Steps to reproduce:
Update to release 21
Actual results:
DHTML-Menu is not shown. All older releases working fine.
Example-HTML-File is attacht.
Expected results:
it should work again
Attachment #758611 -
Attachment mime type: text/plain → text/html
Web console:
[18:34:38,999] TypeError: this[i] is undefined @ https://bug879807.bugzilla.mozilla.org/attachment.cgi?id=758611:260
Maybe a dupe.
![]() |
||
Comment 2•12 years ago
|
||
Regression window(m-c)
Good:
http://hg.mozilla.org/mozilla-central/rev/e9f39220b8e7
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20130123 Firefox/21.0 ID:20130123031657
Bad:
http://hg.mozilla.org/mozilla-central/rev/35e0c12f4332
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20130123 Firefox/21.0 ID:20130123081412
Pushlog:
http://hg.mozilla.org/mozilla-central/pushloghtml?fromchange=e9f39220b8e7&tochange=35e0c12f4332
Regression window(m-i)
Good:
http://hg.mozilla.org/integration/mozilla-inbound/rev/4d567ebd2624
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20130122 Firefox/21.0 ID:20130122115532
Bad:
http://hg.mozilla.org/integration/mozilla-inbound/rev/059c7e8541e2
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:21.0) Gecko/20130122 Firefox/21.0 ID:20130122123031
Pushlog:
http://hg.mozilla.org/integration/mozilla-inbound/pushloghtml?fromchange=4d567ebd2624&tochange=059c7e8541e2
Regressed by:
059c7e8541e2 Boris Zbarsky — Bug 828787. Stop allowing indexed expandos on windows. r=peterv
Assignee: general → nobody
Blocks: 828787
Status: UNCONFIRMED → NEW
status-firefox21:
--- → affected
status-firefox-esr17:
--- → unaffected
tracking-firefox22:
--- → ?
tracking-firefox23:
--- → ?
tracking-firefox24:
--- → ?
Component: JavaScript Engine → DOM
Ever confirmed: true
Keywords: regressionwindow-wanted → regression
![]() |
||
Comment 3•12 years ago
|
||
The new behavior is following the spec, so unless this is happening on a site that can't get changed and is widely used I think the right solution is to fix the site to follow the spec too...
Updated•12 years ago
|
Assignee: nobody → german
Component: DOM → German
OS: Windows XP → All
Product: Core → Tech Evangelism
Hardware: x86 → All
Version: 21 Branch → unspecified
Comment 4•12 years ago
|
||
A small tip would be to use strict mode [1], which would have cought this bug.
1: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Functions_and_function_scope/Strict_mode
Comment 5•12 years ago
|
||
(In reply to Boris Zbarsky (:bz) from comment #3)
> The new behavior is following the spec, so unless this is happening on a
> site that can't get changed and is widely used I think the right solution is
> to fix the site to follow the spec too...
Sounds good - not tracking until we know of major web properties being impacted.
Reporter | ||
Comment 6•12 years ago
|
||
Ok, I can change the code of my page. But which line is unsupported now?
The Error-Box (german: Fehlerkonsole) does not show any error.
What has been changed in the spec?
I have no idea how to fix it.
Comment 7•12 years ago
|
||
Replace
> this[i]=new Image()
> this[i].src=arguments[i]
with
> (new Image()).src=arguments[i]
Comment 8•12 years ago
|
||
This change has been described in the compatibility document.
https://developer.mozilla.org/en-US/docs/Site_Compatibility_for_Firefox_21
You cannot the "this" keyword in the preLoadBackgrounds() because it's the window object. You can use another variable name instead:
> function preLoadBackgrounds(){
> var img
> for(i=0;i<arguments.length;i++){
> img[i]=new Image()
> img[i].src=arguments[i]
> }
> return img
> }
![]() |
||
Comment 9•12 years ago
|
||
You'd need |var img = []| or something.
But yes, the upshot is that setting window[0] is now ignored (or throws, in strict mode) and in preLoadBackgrounds "this" is "window" because the function is not in strict mode.
Reporter | ||
Comment 10•12 years ago
|
||
Now my page works again with FireFox release 21.
function preLoadBackgrounds(){
var img = [];
for(i=0;i<arguments.length;i++){
img[i]=new Image();
img[i].src=arguments[i];
}
return img
}
Many Thanks to all.
Comment 11•12 years ago
|
||
According to Comment 10 this bug can be resolved as fixed.
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Updated•10 years ago
|
Product: Tech Evangelism → Tech Evangelism Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•