Last Comment Bug 711958 - Add a 'length' property to DOMSVGStringList
: Add a 'length' property to DOMSVGStringList
Status: RESOLVED FIXED
: dev-doc-complete
Product: Core
Classification: Components
Component: SVG (show other bugs)
: Trunk
: All All
: -- normal (vote)
: mozilla12
Assigned To: Jonathan Watt [:jwatt] (catching up after vacation)
:
Mentors:
Depends on: 607854
Blocks:
  Show dependency treegraph
 
Reported: 2011-12-19 05:46 PST by Jonathan Watt [:jwatt] (catching up after vacation)
Modified: 2012-02-11 13:30 PST (History)
5 users (show)
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
patch (3.70 KB, patch)
2012-01-27 07:29 PST, Jonathan Watt [:jwatt] (catching up after vacation)
dholbert: review+
Details | Diff | Splinter Review

Description Jonathan Watt [:jwatt] (catching up after vacation) 2011-12-19 05:46:37 PST
Follow-up from the last comment in bug 607854 comment 7. For consistency with the other list classes, we should add a 'length' property to DOMSVGStringList to mirror the 'numberOfItems' property.
Comment 1 Jonathan Watt [:jwatt] (catching up after vacation) 2012-01-27 07:29:27 PST
Created attachment 592131 [details] [diff] [review]
patch
Comment 2 Daniel Holbert [:dholbert] 2012-01-27 17:29:35 PST
Comment on attachment 592131 [details] [diff] [review]
patch

Looks good!

Just one thing -- fix end-of-line whitespace after "GetNumberOfItems(aLength);" here:
> NS_IMETHODIMP
>+DOMSVGStringList::GetLength(PRUint32 *aLength)
>+{
>+  return GetNumberOfItems(aLength);  
>+}

r=me with that
Comment 3 Joe Drew (not getting mail) 2012-01-28 18:53:50 PST
https://hg.mozilla.org/mozilla-central/rev/b939fbd0a46f
Comment 4 Eric Shepherd [:sheppy] 2012-02-10 13:19:08 PST
I've documented this here, flagged as non-standard, since it's not in the spec.

https://developer.mozilla.org/en/DOM/SVGStringList

Also mentioned on Firefox 12 for developers.
Comment 5 Jeremie Patonnier :Jeremie 2012-02-11 13:16:32 PST
I added a note on https://developer.mozilla.org/en/Firefox_12_for_developers
I assumed that SVGStringList is also indexable as an Array. Am I right?
Comment 6 Jeremie Patonnier :Jeremie 2012-02-11 13:30:22 PST
(In reply to Jeremie Patonnier from comment #5)
> I assumed that SVGStringList is also indexable as an Array. Am I right?
Sorry for the noise, Array style indexing is bug #722071

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