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

<bugzilla version="5.0.4.1"
          urlbase="https://bugs.webkit.org/"
          
          maintainer="admin@webkit.org"
>

    <bug>
          <bug_id>20434</bug_id>
          
          <creation_ts>2008-08-18 14:37:37 -0700</creation_ts>
          <short_desc>Firefox allows &quot;svgElement instanceof SVGTransformable&quot; Safari does not</short_desc>
          <delta_ts>2014-05-12 05:23:07 -0700</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>WebKit</product>
          <component>SVG</component>
          <version>528+ (Nightly build)</version>
          <rep_platform>PC</rep_platform>
          <op_sys>OS X 10.5</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>INVALID</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>
          <dependson>20430</dependson>
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Holger Freyther">zecke</reporter>
          <assigned_to name="Nobody">webkit-unassigned</assigned_to>
          <cc>heycam</cc>
    
    <cc>krit</cc>
    
    <cc>webmaster</cc>
          

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>88760</commentid>
    <comment_count>0</comment_count>
    <who name="Holger Freyther">zecke</who>
    <bug_when>2008-08-18 14:37:37 -0700</bug_when>
    <thetext>This one is a bit tricky. There is no multiple inheritance in JavaScript and the IDL files for SVG use multiple inheritance and http://www.w3.org/TR/SVG11/ecmascript-binding.html is ambiguous. It says that that XYZElement has all functions and properties of SVGX, SVGY and SVGZ but does not say if that element is an instance of that other element.

E.g. in firefox3 SVGTransformable is bound to the DOM and a &quot;g&quot; element is instanceof SVGTransformable.

So should we add SVGTransformable and SVGLocatable to the DOM (it would probably require manual binding) to follow the SVG spec? Should we support &quot;instanceof&quot; as firefox3 is doing?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>88761</commentid>
    <comment_count>1</comment_count>
      <attachid>22862</attachid>
    <who name="Holger Freyther">zecke</who>
    <bug_when>2008-08-18 14:39:18 -0700</bug_when>
    <thetext>Created attachment 22862
SVGTransformable test case

The following test case is passed by firefox3</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>93772</commentid>
    <comment_count>2</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2008-10-02 12:47:47 -0700</bug_when>
    <thetext>If we wanted to fix this, we would fix this by making &quot;instanceof&quot; smarter.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>93791</commentid>
    <comment_count>3</comment_count>
    <who name="Sam Weinig">sam</who>
    <bug_when>2008-10-02 13:37:30 -0700</bug_when>
    <thetext>We could override instanceof for the classes in question.  In fact, we probably should.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>94026</commentid>
    <comment_count>4</comment_count>
    <who name="Eric Seidel (no email)">eric</who>
    <bug_when>2008-10-03 19:28:43 -0700</bug_when>
    <thetext>I think this is a bug in Gecko.  That&apos;s not how &quot;instanceof&quot; is supposed to work according to ECMAScript 262:
http://bclary.com/2004/11/07/#a-11.8.6

ECMAScript seems to specify that instanceof is just supposed to walk the prototype chain (which would suggest that one might be able to manipulate said chain and change what instanceof returned.

http://developer.mozilla.org/en/Core_JavaScript_1.5_Reference/Operators/Special_Operators/instanceof_Operator

I think we need to file a bug against Gecko and discuss this with the SVG folks.  I agree that to the web developer it might be nice to be able to ask svgElement instanceof SVGTransformable...</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1008539</commentid>
    <comment_count>5</comment_count>
    <who name="Dirk Schulze">krit</who>
    <bug_when>2014-05-12 05:23:07 -0700</bug_when>
    <thetext>SVG2 will have a different hierarchy that we already implement. SVGTransformable is no longer part of it.</thetext>
  </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>22862</attachid>
            <date>2008-08-18 14:39:18 -0700</date>
            <delta_ts>2010-06-10 20:16:25 -0700</delta_ts>
            <desc>SVGTransformable test case</desc>
            <filename>0003-svg-transformable-Testcase-that-mozilla-is-passing.patch</filename>
            <type>text/plain</type>
            <size>2079</size>
            <attacher name="Holger Freyther">zecke</attacher>
            
              <data encoding="base64">RnJvbSBlMGM0Y2E3NmJjN2FmNGE1Mjg2NmJmZWUwYzhlZjg1ZjI2MjA1NWUyIE1vbiBTZXAgMTcg
MDA6MDA6MDAgMjAwMQpGcm9tOiBIb2xnZXIgSGFucyBQZXRlciBGcmV5dGhlciA8emVja2VAc2Vs
ZmlzaC5vcmc+CkRhdGU6IFN1biwgMTcgQXVnIDIwMDggMDE6Mzc6MzQgKzAyMDAKU3ViamVjdDog
W1BBVENIXSBbc3ZnIHRyYW5zZm9ybWFibGVdIFRlc3RjYXNlIHRoYXQgbW96aWxsYSBpcyBwYXNz
aW5nIGJ1dCB3ZSBhcmUgbm90CgotLS0KIC4uLi9zdmcvY3VzdG9tL1NWR1RyYW5zZm9ybWFibGUt
cHJvdG90eXBlLnhodG1sICAgIHwgICAzOSArKysrKysrKysrKysrKysrKysrKwogMSBmaWxlcyBj
aGFuZ2VkLCAzOSBpbnNlcnRpb25zKCspLCAwIGRlbGV0aW9ucygtKQogY3JlYXRlIG1vZGUgMTAw
NjQ0IExheW91dFRlc3RzL3N2Zy9jdXN0b20vU1ZHVHJhbnNmb3JtYWJsZS1wcm90b3R5cGUueGh0
bWwKCmRpZmYgLS1naXQgYS9MYXlvdXRUZXN0cy9zdmcvY3VzdG9tL1NWR1RyYW5zZm9ybWFibGUt
cHJvdG90eXBlLnhodG1sIGIvTGF5b3V0VGVzdHMvc3ZnL2N1c3RvbS9TVkdUcmFuc2Zvcm1hYmxl
LXByb3RvdHlwZS54aHRtbApuZXcgZmlsZSBtb2RlIDEwMDY0NAppbmRleCAwM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