- From: Simon Pieters <simonp@opera.com>
- Date: Fri, 24 Apr 2015 10:37:51 +0200
- To: "public-fx@w3.org" <public-fx@w3.org>, "Domenic Denicola" <d@domenic.me>
- Cc: "Robert O'Callahan" <rocallahan@mozilla.com>
On Wed, 08 Apr 2015 14:38:02 +0200, Simon Pieters <simonp@opera.com> wrote:
> On Wed, 25 Mar 2015 13:55:04 +0100, Domenic Denicola <d@domenic.me>
> wrote:
>
>> I think a better solution might be a single constructor (no overloads)
>> plus static factory methods. So something like
>>
>> [Constructor(optional DOMPointInit p1, ...)]
>> interface DOMQuad {
>> ...
>> static fromRect(optional DOMRectInit);
>> static fromQuad(optional DOMQuadInit);
>> }
>
> I've started to implement this suggestion in the spec.
>
> https://github.com/w3c/fxtf-drafts/commit/62b9cb9d5be4982d2a9cbf314e3a59efb8a68dd6
>
> DOMMatrix constructor still has overloads, which I intend to convert to
> fromX also. It happens to already have toFloat32Array, toFloat64Array,
> and toString, so fromFloat32Array, fromFloat64Array and fromString would
> neatly mirror those.
OK I'm now basically done with the API redesign. Review welcome.
http://dev.w3.org/fxtf/geometry/#DOMPoint
http://dev.w3.org/fxtf/geometry/#DOMRect
http://dev.w3.org/fxtf/geometry/#DOMQuad
http://dev.w3.org/fxtf/geometry/#DOMMatrix
cheers
--
Simon Pieters
Opera Software
Received on Friday, 24 April 2015 08:38:23 UTC