W3C home > Mailing lists > Public > public-script-coord@w3.org > January to March 2015

Re: [geometry] Dictionary argument for DOMQuad constructor

From: Robert O'Callahan <robert@ocallahan.org>
Date: Fri, 27 Mar 2015 10:10:08 +1300
Message-ID: <CAOp6jLa3Yn9vtnxXkBpFPAKjjigaQHdy2vLUi1HRamEcLj--Vg@mail.gmail.com>
To: Simon Pieters <simonp@opera.com>
Cc: "public-fx@w3.org" <public-fx@w3.org>, Domenic Denicola <d@domenic.me>, Boris Zbarsky <bzbarsky@mit.edu>, "public-script-coord@w3.org" <public-script-coord@w3.org>
On Fri, Mar 27, 2015 at 10:02 AM, Simon Pieters <simonp@opera.com> wrote:

> It is useful to be able to use a straight JS object as a rect. I think it
> would be good for Web developers to consistently support dictionary types
> instead of supporting them in some places but require an object of the
> proper interface in other places.

Hmm. If we apply that consistency strictly, then we're not going to use
interface types as parameters anywhere, correct?

I'm not sure we should do that. It makes overloading impossible unless we
make large changes to WebIDL. It also has performance implications: passing
a DOMRectReadOnly as a DOMRectInit parameter naively requires unpacking to
a JS object and then repacking to a DOMRectInit. We could optimize that but
it's a significant amount of work that nobody's done yet AFAIK.

On Thu, 26 Mar 2015 21:13:04 +0100, Robert O'Callahan <robert@ocallahan.org>
> wrote:
>  And FWIW we implemented that because it's what the spec used to say:
>> http://www.w3.org/TR/2014/WD-geometry-1-20140522/#DOMQuad
> Yes. That's why I ask if you're OK with the proposed change. :-)

I'll go along with it if everyone decides it's the right thing to do. I'm
not convinced yet.

oIo otoeololo oyooouo otohoaoto oaonoyooonoeo owohooo oioso oaonogoroyo
owoiotoho oao oboroootohoeoro oooro osoiosotoeoro owoiololo oboeo
osouobojoeocoto otooo ojouodogomoeonoto.o oAogoaoiono,o oaonoyooonoeo
osoaoyoso otooo oao oboroootohoeoro oooro osoiosotoeoro,o o‘oRoaocoao,o’o
oaonosowoeoroaoboloeo otooo otohoeo ocooouoroto.o oAonodo oaonoyooonoeo
osoaoyoso,o o‘oYooouo ofooooolo!o’o owoiololo oboeo oiono odoaonogoeoro
otohoeo ofoioroeo ooofo ohoeololo.
Received on Thursday, 26 March 2015 21:10:38 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 17:14:24 UTC