Last Comment Bug 765590 - CSSNameSpaceRule.type should be 10, not 0
: CSSNameSpaceRule.type should be 10, not 0
Status: RESOLVED FIXED
[good first bug][mentor=Ms2ger][lang=...
: dev-doc-complete
Product: Core
Classification: Components
Component: DOM: CSS Object Model (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla16
Assigned To: Jignesh Kakadiya [:jhk]
:
:
Mentors:
http://dev.w3.org/csswg/cssom/#dom-cs...
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-06-17 10:16 PDT by :Ms2ger (⌚ UTC+1/+2)
Modified: 2012-08-13 07:31 PDT (History)
5 users (show)
dholbert: in‑testsuite+
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
Patch(v1) (1.87 KB, patch)
2012-06-21 03:19 PDT, Jignesh Kakadiya [:jhk]
Ms2ger: feedback+
Details | Diff | Splinter Review
Patch(v2) (3.38 KB, patch)
2012-06-21 05:55 PDT, Jignesh Kakadiya [:jhk]
dbaron: review+
Ms2ger: feedback+
Details | Diff | Splinter Review

Comment 1 David Baron :dbaron: ⌚️UTC-7 (busy September 14-25) 2012-06-17 10:35:29 PDT
Yeah, I don't think there was a value assigned at the time we implemented this.

Are you interested in posting a patch?
Comment 2 Kang-Hao (Kenny) Lu [:kennyluck] 2012-06-17 10:37:32 PDT
We could probably make this a "good first bug" too, although I am not sure this is really a good one...
Comment 3 :Ms2ger (⌚ UTC+1/+2) 2012-06-17 11:08:06 PDT
To fix this bug, a new constant NAMESPACE_RULE = 10; should be added to <http://mxr.mozilla.org/mozilla-central/source/dom/interfaces/css/nsIDOMCSSRule.idl>, and the implementation at <http://mxr.mozilla.org/mozilla-central/source/layout/style/nsCSSRules.cpp#1197> should be updated to use it instead of the UNKNOWN_RULE it has now.
Comment 4 David Baron :dbaron: ⌚️UTC-7 (busy September 14-25) 2012-06-17 12:51:56 PDT
and also see http://wiki.csswg.org/spec/cssom-constants
Comment 5 Jignesh Kakadiya [:jhk] 2012-06-21 03:19:18 PDT
Created attachment 635234 [details] [diff] [review]
Patch(v1)
Comment 6 :Ms2ger (⌚ UTC+1/+2) 2012-06-21 03:32:24 PDT
Comment on attachment 635234 [details] [diff] [review]
Patch(v1)

Review of attachment 635234 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good to me, code-wise; a test would be good, though.
Comment 7 Jignesh Kakadiya [:jhk] 2012-06-21 05:55:30 PDT
Created attachment 635276 [details] [diff] [review]
Patch(v2)

Patch+test. I tested it locally and it doesn't break any other tests.
Comment 8 :Ms2ger (⌚ UTC+1/+2) 2012-06-21 06:21:03 PDT
Comment on attachment 635276 [details] [diff] [review]
Patch(v2)

Review of attachment 635276 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good to me.
Comment 9 David Baron :dbaron: ⌚️UTC-7 (busy September 14-25) 2012-06-21 11:29:12 PDT
Comment on attachment 635276 [details] [diff] [review]
Patch(v2)

r=dbaron
Comment 10 Daniel Holbert [:dholbert] 2012-06-21 13:00:45 PDT
https://hg.mozilla.org/integration/mozilla-inbound/rev/0f3f06fbe11d
Comment 11 Ed Morley [:emorley] 2012-06-22 03:45:27 PDT
https://hg.mozilla.org/mozilla-central/rev/0f3f06fbe11d
Comment 12 Jean-Yves Perrier [:teoli] 2012-08-13 07:31:26 PDT
I've added a line in :
https://developer.mozilla.org/en-US/docs/Firefox_16_for_developers

Updated: https://developer.mozilla.org/en-US/docs/DOM/CSSRule which was quite outdated.

Created: https://developer.mozilla.org/en-US/docs/DOM/CSSNamespaceRule as it didn't existed at all!

Note that I still to add a link from the doc for @namespace to the CSSOM interface, but as this at-rule is not yet documented, I'll wait a bit. (Anyway I have to make sure that every combination of at-rule/CSSOM interface are correctly linked and documented.

Note You need to log in before you can comment on or make changes to this bug.