<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>27492</bug_id>
          
          <creation_ts>2014-12-03 10:20:25 +0000</creation_ts>
          <short_desc>&quot;DOMQuad&quot; constructor should accept DOMQuadInit</short_desc>
          <delta_ts>2015-04-17 12:51:30 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>FXTF</product>
          <component>Geometry</component>
          <version>unspecified</version>
          <rep_platform>PC</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Simon Pieters">zcorpan</reporter>
          <assigned_to name="Simon Pieters">zcorpan</assigned_to>
          <cc>mike</cc>
          
          <qa_contact>sideshowbarker+geometry</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>115827</commentid>
    <comment_count>0</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2014-12-03 10:20:25 +0000</bug_when>
    <thetext>http://dev.w3.org/fxtf/geometry/#dom-domquad

[[
DOMQuad
]]

Why is there no DOMQuadInit that can be used for DOMQuad constructor?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>118917</commentid>
    <comment_count>1</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2015-03-24 20:23:36 +0000</bug_when>
    <thetext>I guess we can&apos;t support both a DOMRectInit and a DOMQuadInit, as it wouldn&apos;t be possible to tell which one is used.

Possibly we can have a dictionary type with members for both rect and quad, and have the constructor throw if the object has members for both?

dictionary DOMRectOrQuadInit {
    unrestricted double x;
    unrestricted double y;
    unrestricted double width;
    unrestricted double height;
    DOMPointInit p1;
    DOMPointInit p2;
    DOMPointInit p3;
    DOMPointInit p4;
};

new DOMQuad({}); // all points are 0,0
new DOMQuad({width: 100, height: 100}); // rect
new DOMQuad({p2: {x: 100}, p3: {x: 100, y: 100}, p4: {y: 100}}); // quad
new DOMQuad({p1: {}, x: 100}); // throws TypeError</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>119632</commentid>
    <comment_count>2</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2015-04-17 12:16:52 +0000</bug_when>
    <thetext>https://github.com/w3c/fxtf-drafts/commit/62b9cb9d5be4982d2a9cbf314e3a59efb8a68dd6</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>119633</commentid>
    <comment_count>3</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2015-04-17 12:18:22 +0000</bug_when>
    <thetext>Oops, sorry, this is not fixed yet.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>119634</commentid>
    <comment_count>4</comment_count>
    <who name="Simon Pieters">zcorpan</who>
    <bug_when>2015-04-17 12:51:30 +0000</bug_when>
    <thetext>https://github.com/w3c/fxtf-drafts/commit/c453c6533c75facc86217fab47076029233909c3</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>