WebIDL question (was: DOMPoint dictionary problem)

On Mon, Sep 16, 2013 at 3:46 AM, Robert O'Callahan <robert@ocallahan.org>wrote:

> Making DOMPoint a dictionary, as currently proposed, is a problem since it
> means other objects (such as the proposed DOMQuad) can't have DOMPoints as
> attributes. I'm assuming the WebIDL restriction that attributes can't be
> dictionaries is not easily removed.
>

Why can't interfaces have dictionary attributes in IDL?


>
> I think we probably should make DOMPoint a regular interface. For methods
> that take DOMPoints as parameters, we can retain the convenient literal
> syntax for points by adding a DOMPointLiteral dictionary type and using
> union types, e.g.
>   DOMPoint convertPoint((DOMPoint or DOMPointLiteral) point);
>

Received on Tuesday, 24 September 2013 18:46:42 UTC