Closed Bug 40594 Opened 26 years ago Closed 26 years ago

DOM_L2: Does the mailnews rely on old incorrect DOM Level 1 behavior

Categories

(SeaMonkey :: MailNews: Message Display, defect, P1)

defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: jst, Assigned: alecf)

Details

(Whiteboard: [nsbeta2+])

This bug is for tracking if and how mailnews breaks when the old incorrect way of manipulating a DOM document containing XML namespace elements in mozilla is replaced with the new correct DOM Level 2 way of dealing with elements in a XML namespace aware application. The old incorrect implementation allows for code like this to work: document.createElement("html:input"); document.getElementsByTagName("html:checkbox"); element.setAttribute("rdf:resource", "http://..."); element.getAttribute("rdf:resource"); if (element.tagName == "BODY") ... // element is a HTML element in XUL if (element.nodeName == "TD") ... // element is a HTML element in XUL The correct new DOM Level 2 way of doing the above would be something like this: document.createElementNS("http://www.w3.org/TR/REC-html40", "html:input"); document.getElementsByTagNameNS("http://www.w3.org/TR/REC-html40", "checkbox"); element.setAttributeNS("http://www.w3.org/1999/02/22-rdf-syntax-ns#", "rdf:resource", "http://..."); element.getAttributeNS("http://www.w3.org/1999/02/22-rdf-syntax-ns#", "resource");
Keywords: nsbeta2
When are you going to switch over to this new way?
The temporary code that lets you turn on the new behavior by setting a pref is now checked in, to enable the new behavior, add this to all.js pref("temp.DOMLevel2update.enabled", true); With this pref enabled you'll see output like this: Possible DOM Error: CreateElement("html:input") called, use CreateElementNS() in stead! if the old incorrect behavior is expected. This temporary code does it's best to issue warnings when possible, but it's not quaranteed to find all the problems for you.
lchiang, this will be switched on by default as soon as mozilla is ready for it, the sooner the better. IMO it shouldn't take many days to realize where the problems are and getting them fixed, but I don't have a final date for this, more info here when available. lchiang, is it OK to have only one bug on this for all of mailnews, or should I add separate bugs for some other mailnews components?
this is fine. If I need more help then I'll file bugs. cc'ing alecf because I think he expressed interest in this.
one bug is fine, I guess, per putterman. When turned on by default and we find bugs, then we should file add'l bugs as needed. We would probably want to run for one or so days before the switch is set to default. What do you think, Scott?
I'll bet we're pretty safe in mail actually, if these are the extent of the rest of the changes...
Target nominated bugs to M16. Please update as necessary.
Target Milestone: --- → M16
We're plussing this to say that it is OK to do the flip to the DOM Level2 behavior.
Whiteboard: [nsbeta2+]
marking P1
Status: NEW → ASSIGNED
Priority: P3 → P1
Assignee: putterman → alecf
Status: ASSIGNED → NEW
reassigning to alecf who has already done this. thanks, Alec.
ok, fix is in... even found/fixed a XUL/DOM2 bug in the process
Status: NEW → RESOLVED
Closed: 26 years ago
Resolution: --- → FIXED
I'm going to mark verified. If this has been turned on, then we've been using the trunk builds for the last few days on all platforms without any serious side effects/regressions from this.
Status: RESOLVED → VERIFIED
jst says this is not turned on by default. But I've been running with this on I suggest someone sets the pref and runs with mail for a while to see if it's truly working. There are still warnings, but they all seem to come from the browser...
ok, I will unverify this then. I'll set the pref on Monday and run for a day.
Status: VERIFIED → REOPENED
Resolution: FIXED → ---
.
Status: REOPENED → RESOLVED
Closed: 26 years ago26 years ago
Resolution: --- → FIXED
I'm marking verified. This has been in the product for a while and no adverse effects.
Status: RESOLVED → VERIFIED
Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.