2010-06-12 Andreas Kling <andreas.kling@nokia.com>
authoreric@webkit.org <eric@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 13 Jun 2010 01:03:54 +0000 (01:03 +0000)
committereric@webkit.org <eric@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Sun, 13 Jun 2010 01:03:54 +0000 (01:03 +0000)
        Reviewed by Darin Adler.

        Window object should have CanvasGradient and CanvasPattern
        https://bugs.webkit.org/show_bug.cgi?id=40394

        Unskipped 2 tests that are now working properly.

        * canvas/philip/tests/2d.gradient.object.return-expected.txt:
        * canvas/philip/tests/2d.pattern.basic.type-expected.txt:
        * fast/dom/Window/window-properties-expected.txt:
        * fast/dom/Window/window-property-descriptors-expected.txt:
        * fast/dom/dom-constructors-expected.txt:
        * fast/dom/prototype-inheritance-2-expected.txt:
        * fast/dom/prototype-inheritance-expected.txt:
        * fast/js/global-constructors-expected.txt:
        * platform/gtk/fast/dom/Window/window-properties-expected.txt:
        * platform/gtk/fast/dom/Window/window-property-descriptors-expected.txt:
        * platform/gtk/fast/dom/prototype-inheritance-expected.txt:
        * platform/gtk/fast/js/global-constructors-expected.txt:
        * platform/mac/Skipped:
        * platform/qt/Skipped:
        * platform/qt/fast/dom/Window/window-properties-expected.txt:
        * platform/qt/fast/dom/Window/window-property-descriptors-expected.txt:
        * platform/qt/fast/dom/prototype-inheritance-expected.txt:
        * platform/qt/fast/js/global-constructors-expected.txt:
2010-06-12  Andreas Kling  <andreas.kling@nokia.com>

        Reviewed by Darin Adler.

        Window object should have CanvasGradient and CanvasPattern
        https://bugs.webkit.org/show_bug.cgi?id=40394

        This fixes the following tests:
        - canvas/philip/tests/2d.gradient.object.return.html
        - canvas/philip/tests/2d.pattern.basic.type.html

        * html/canvas/CanvasGradient.idl:
        * html/canvas/CanvasPattern.idl:
        * page/DOMWindow.idl:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@61071 268f45cc-cd09-0410-ab3c-d52691b4dbfc

23 files changed:
LayoutTests/ChangeLog
LayoutTests/canvas/philip/tests/2d.gradient.object.return-expected.txt
LayoutTests/canvas/philip/tests/2d.pattern.basic.type-expected.txt
LayoutTests/fast/dom/Window/window-properties-expected.txt
LayoutTests/fast/dom/Window/window-property-descriptors-expected.txt
LayoutTests/fast/dom/dom-constructors-expected.txt
LayoutTests/fast/dom/prototype-inheritance-2-expected.txt
LayoutTests/fast/dom/prototype-inheritance-expected.txt
LayoutTests/fast/js/global-constructors-expected.txt
LayoutTests/platform/gtk/fast/dom/Window/window-properties-expected.txt
LayoutTests/platform/gtk/fast/dom/Window/window-property-descriptors-expected.txt
LayoutTests/platform/gtk/fast/dom/prototype-inheritance-expected.txt
LayoutTests/platform/gtk/fast/js/global-constructors-expected.txt
LayoutTests/platform/mac/Skipped
LayoutTests/platform/qt/Skipped
LayoutTests/platform/qt/fast/dom/Window/window-properties-expected.txt
LayoutTests/platform/qt/fast/dom/Window/window-property-descriptors-expected.txt
LayoutTests/platform/qt/fast/dom/prototype-inheritance-expected.txt
LayoutTests/platform/qt/fast/js/global-constructors-expected.txt
WebCore/ChangeLog
WebCore/html/canvas/CanvasGradient.idl
WebCore/html/canvas/CanvasPattern.idl
WebCore/page/DOMWindow.idl

index 4489e7b..daed24f 100644 (file)
@@ -1,3 +1,31 @@
+2010-06-12  Andreas Kling  <andreas.kling@nokia.com>
+
+        Reviewed by Darin Adler.
+
+        Window object should have CanvasGradient and CanvasPattern
+        https://bugs.webkit.org/show_bug.cgi?id=40394
+
+        Unskipped 2 tests that are now working properly.
+
+        * canvas/philip/tests/2d.gradient.object.return-expected.txt:
+        * canvas/philip/tests/2d.pattern.basic.type-expected.txt:
+        * fast/dom/Window/window-properties-expected.txt:
+        * fast/dom/Window/window-property-descriptors-expected.txt:
+        * fast/dom/dom-constructors-expected.txt:
+        * fast/dom/prototype-inheritance-2-expected.txt:
+        * fast/dom/prototype-inheritance-expected.txt:
+        * fast/js/global-constructors-expected.txt:
+        * platform/gtk/fast/dom/Window/window-properties-expected.txt:
+        * platform/gtk/fast/dom/Window/window-property-descriptors-expected.txt:
+        * platform/gtk/fast/dom/prototype-inheritance-expected.txt:
+        * platform/gtk/fast/js/global-constructors-expected.txt:
+        * platform/mac/Skipped:
+        * platform/qt/Skipped:
+        * platform/qt/fast/dom/Window/window-properties-expected.txt:
+        * platform/qt/fast/dom/Window/window-property-descriptors-expected.txt:
+        * platform/qt/fast/dom/prototype-inheritance-expected.txt:
+        * platform/qt/fast/js/global-constructors-expected.txt:
+
 2010-06-12  Dan Bernstein  <mitz@apple.com>
 
         Reviewed by Oliver Hunt.
index 3ebab43..b3d8eb2 100644 (file)
@@ -3,4 +3,4 @@
 createLinearGradient() and createRadialGradient() returns objects implementing CanvasGradient
 References: 2d.gradient.linear.return 2d.gradient.radial.return
 Actual output:
-Aborted with exception: Result of expression 'window.CanvasGradient' [undefined] is not an object.
+Passed
index 1bc61a9..bf081ab 100644 (file)
@@ -385,6 +385,11 @@ window.CSSVariablesDeclaration.prototype.removeVariable [function]
 window.CSSVariablesDeclaration.prototype.setVariable [function]
 window.CSSVariablesRule [object CSSVariablesRuleConstructor]
 window.CSSVariablesRule.prototype [printed above as window.CSSRule.prototype]
+window.CanvasGradient [object CanvasGradientConstructor]
+window.CanvasGradient.prototype [object CanvasGradientPrototype]
+window.CanvasGradient.prototype.addColorStop [function]
+window.CanvasPattern [object CanvasPatternConstructor]
+window.CanvasPattern.prototype [object CanvasPatternPrototype]
 window.CanvasRenderingContext2D [object CanvasRenderingContext2DConstructor]
 window.CanvasRenderingContext2D.prototype [object CanvasRenderingContext2DPrototype]
 window.CanvasRenderingContext2D.prototype.arc [function]
index 8736904..d4d34c2 100644 (file)
@@ -25,6 +25,8 @@ PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSValue') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSValueList') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSVariablesDeclaration') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSVariablesRule') is 'object'
+PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasGradient') is 'object'
+PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasPattern') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasRenderingContext2D') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CharacterData') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'ClientRect') is 'object'
index 083f9f8..4f459a9 100644 (file)
@@ -116,8 +116,8 @@ PASS TryAllocate('UIEvent') is 'exception'
 PASS TryAllocate('WheelEvent') is 'exception'
 PASS TryAllocate('XPathResult') is 'exception'
 FAIL TryAllocate('BarInfo') should be exception. Was no constructor.
-FAIL TryAllocate('CanvasGradient') should be exception. Was no constructor.
-FAIL TryAllocate('CanvasPattern') should be exception. Was no constructor.
+PASS TryAllocate('CanvasGradient') is 'exception'
+PASS TryAllocate('CanvasPattern') is 'exception'
 FAIL TryAllocate('Console') should be exception. Was no constructor.
 FAIL TryAllocate('DOMSelection') should be exception. Was no constructor.
 FAIL TryAllocate('DOMWindow') should be exception. Was no constructor.
index 6bbf0fa..d7227d6 100644 (file)
@@ -48,6 +48,7 @@ PASS CSSValueListConstructor from inner.getComputedStyle(inner.document.body).ge
 PASS CSSValueListPrototype from inner.getComputedStyle(inner.document.body).getPropertyCSSValue(-webkit-transition-timing-function).__proto__
 PASS CSSValuePrototype from inner.getComputedStyle(inner.document.body).getPropertyCSSValue(background-clip).__proto__.__proto__
 FAIL CanvasPattern from inner.document.getElementsByTagName("canvas")[0].getContext("2d").createPattern(inner.document.getElementsByTagName("img")[0], "")
+FAIL CanvasPatternConstructor from inner.document.getElementsByTagName("canvas")[0].getContext("2d").createPattern(inner.document.getElementsByTagName("img")[0], "").constructor
 FAIL CanvasPatternPrototype from inner.document.getElementsByTagName("canvas")[0].getContext("2d").createPattern(inner.document.getElementsByTagName("img")[0], "").__proto__
 PASS CanvasRenderingContext2D from inner.document.getElementsByTagName("canvas")[0].getContext("2d")
 PASS CanvasRenderingContext2DConstructor from inner.document.getElementsByTagName("canvas")[0].getContext("2d").constructor
@@ -214,6 +215,7 @@ Never found CDATASection
 Never found CSSRule
 Never found CSSVariablesDeclaration
 Never found CSSVariablesRule
+Never found CanvasGradient
 Never found CharacterData
 Never found Clipboard
 Never found DOMParser
index 1a3c11c..3245b3e 100644 (file)
@@ -43,6 +43,10 @@ PASS inner.CSSVariablesDeclaration.isInner is true
 PASS inner.CSSVariablesDeclaration.constructor.isInner is true
 PASS inner.CSSVariablesRule.isInner is true
 PASS inner.CSSVariablesRule.constructor.isInner is true
+PASS inner.CanvasGradient.isInner is true
+PASS inner.CanvasGradient.constructor.isInner is true
+PASS inner.CanvasPattern.isInner is true
+PASS inner.CanvasPattern.constructor.isInner is true
 PASS inner.CanvasRenderingContext2D.isInner is true
 PASS inner.CanvasRenderingContext2D.constructor.isInner is true
 PASS inner.CharacterData.isInner is true
index bfb1357..502fe51 100644 (file)
@@ -23,6 +23,8 @@ PASS CSSValue.toString() is '[object CSSValueConstructor]'
 PASS CSSValueList.toString() is '[object CSSValueListConstructor]'
 PASS CSSVariablesDeclaration.toString() is '[object CSSVariablesDeclarationConstructor]'
 PASS CSSVariablesRule.toString() is '[object CSSVariablesRuleConstructor]'
+PASS CanvasGradient.toString() is '[object CanvasGradientConstructor]'
+PASS CanvasPattern.toString() is '[object CanvasPatternConstructor]'
 PASS CanvasRenderingContext2D.toString() is '[object CanvasRenderingContext2DConstructor]'
 PASS CharacterData.toString() is '[object CharacterDataConstructor]'
 PASS ClientRect.toString() is '[object ClientRectConstructor]'
index c9e50cb..38e3c27 100644 (file)
@@ -356,6 +356,11 @@ window.CSSVariablesDeclaration.prototype.removeVariable [function]
 window.CSSVariablesDeclaration.prototype.setVariable [function]
 window.CSSVariablesRule [object CSSVariablesRuleConstructor]
 window.CSSVariablesRule.prototype [printed above as window.CSSRule.prototype]
+window.CanvasGradient [object CanvasGradientConstructor]
+window.CanvasGradient.prototype [object CanvasGradientPrototype]
+window.CanvasGradient.prototype.addColorStop [function]
+window.CanvasPattern [object CanvasPatternConstructor]
+window.CanvasPattern.prototype [object CanvasPatternPrototype]
 window.CanvasRenderingContext2D [object CanvasRenderingContext2DConstructor]
 window.CanvasRenderingContext2D.prototype [object CanvasRenderingContext2DPrototype]
 window.CanvasRenderingContext2D.prototype.arc [function]
index 10d6113..5b5d62f 100644 (file)
@@ -25,6 +25,8 @@ PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSValue') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSValueList') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSVariablesDeclaration') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSVariablesRule') is 'object'
+PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasGradient') is 'object'
+PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasPattern') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasRenderingContext2D') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CharacterData') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'ClientRect') is 'object'
index af2aa2e..1f078ae 100644 (file)
@@ -43,6 +43,10 @@ PASS inner.CSSVariablesDeclaration.isInner is true
 PASS inner.CSSVariablesDeclaration.constructor.isInner is true
 PASS inner.CSSVariablesRule.isInner is true
 PASS inner.CSSVariablesRule.constructor.isInner is true
+PASS inner.CanvasGradient.isInner is true
+PASS inner.CanvasGradient.constructor.isInner is true
+PASS inner.CanvasPattern.isInner is true
+PASS inner.CanvasPattern.constructor.isInner is true
 PASS inner.CanvasRenderingContext2D.isInner is true
 PASS inner.CanvasRenderingContext2D.constructor.isInner is true
 PASS inner.CharacterData.isInner is true
index cb8ac8e..60c4f62 100644 (file)
@@ -23,6 +23,8 @@ PASS CSSValue.toString() is '[object CSSValueConstructor]'
 PASS CSSValueList.toString() is '[object CSSValueListConstructor]'
 PASS CSSVariablesDeclaration.toString() is '[object CSSVariablesDeclarationConstructor]'
 PASS CSSVariablesRule.toString() is '[object CSSVariablesRuleConstructor]'
+PASS CanvasGradient.toString() is '[object CanvasGradientConstructor]'
+PASS CanvasPattern.toString() is '[object CanvasPatternConstructor]'
 PASS CanvasRenderingContext2D.toString() is '[object CanvasRenderingContext2DConstructor]'
 PASS CharacterData.toString() is '[object CharacterDataConstructor]'
 PASS ClientRect.toString() is '[object ClientRectConstructor]'
index a866365..ef8e2fe 100644 (file)
@@ -240,7 +240,6 @@ canvas/philip/tests/2d.path.stroke.prune.arc.html
 canvas/philip/tests/2d.path.stroke.prune.closed.html
 canvas/philip/tests/2d.path.stroke.prune.curve.html
 canvas/philip/tests/2d.path.stroke.prune.line.html
-canvas/philip/tests/2d.pattern.basic.type.html
 canvas/philip/tests/2d.pattern.image.broken.html
 canvas/philip/tests/2d.pattern.image.incomplete.html
 canvas/philip/tests/2d.pattern.image.null.html
index 569d2a7..83ed7e4 100644 (file)
@@ -5300,7 +5300,6 @@ canvas/philip/tests/2d.path.rect.zero.4.html
 canvas/philip/tests/2d.path.rect.zero.6.html
 canvas/philip/tests/2d.path.stroke.prune.arc.html
 canvas/philip/tests/2d.path.stroke.scale2.html
-canvas/philip/tests/2d.pattern.basic.type.html
 canvas/philip/tests/2d.pattern.image.broken.html
 canvas/philip/tests/2d.pattern.image.incomplete.html
 canvas/philip/tests/2d.pattern.image.null.html
index d9b5102..e4b094f 100644 (file)
@@ -385,6 +385,11 @@ window.CSSVariablesDeclaration.prototype.removeVariable [function]
 window.CSSVariablesDeclaration.prototype.setVariable [function]
 window.CSSVariablesRule [object CSSVariablesRuleConstructor]
 window.CSSVariablesRule.prototype [printed above as window.CSSRule.prototype]
+window.CanvasGradient [object CanvasGradientConstructor]
+window.CanvasGradient.prototype [object CanvasGradientPrototype]
+window.CanvasGradient.prototype.addColorStop [function]
+window.CanvasPattern [object CanvasPatternConstructor]
+window.CanvasPattern.prototype [object CanvasPatternPrototype]
 window.CanvasRenderingContext2D [object CanvasRenderingContext2DConstructor]
 window.CanvasRenderingContext2D.prototype [object CanvasRenderingContext2DPrototype]
 window.CanvasRenderingContext2D.prototype.arc [function]
index b62b2e9..f9ae486 100644 (file)
@@ -25,6 +25,8 @@ PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSValue') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSValueList') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSVariablesDeclaration') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CSSVariablesRule') is 'object'
+PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasGradient') is 'object'
+PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasPattern') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CanvasRenderingContext2D') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'CharacterData') is 'object'
 PASS typeof Object.getOwnPropertyDescriptor(window, 'ClientRect') is 'object'
index 29a4cee..48bbd7d 100644 (file)
@@ -43,6 +43,10 @@ PASS inner.CSSVariablesDeclaration.isInner is true
 PASS inner.CSSVariablesDeclaration.constructor.isInner is true
 PASS inner.CSSVariablesRule.isInner is true
 PASS inner.CSSVariablesRule.constructor.isInner is true
+PASS inner.CanvasGradient.isInner is true
+PASS inner.CanvasGradient.constructor.isInner is true
+PASS inner.CanvasPattern.isInner is true
+PASS inner.CanvasPattern.constructor.isInner is true
 PASS inner.CanvasRenderingContext2D.isInner is true
 PASS inner.CanvasRenderingContext2D.constructor.isInner is true
 PASS inner.CharacterData.isInner is true
index 64d7e46..dbfc8df 100644 (file)
@@ -23,6 +23,8 @@ PASS CSSValue.toString() is '[object CSSValueConstructor]'
 PASS CSSValueList.toString() is '[object CSSValueListConstructor]'
 PASS CSSVariablesDeclaration.toString() is '[object CSSVariablesDeclarationConstructor]'
 PASS CSSVariablesRule.toString() is '[object CSSVariablesRuleConstructor]'
+PASS CanvasGradient.toString() is '[object CanvasGradientConstructor]'
+PASS CanvasPattern.toString() is '[object CanvasPatternConstructor]'
 PASS CanvasRenderingContext2D.toString() is '[object CanvasRenderingContext2DConstructor]'
 PASS CharacterData.toString() is '[object CharacterDataConstructor]'
 PASS ClientRect.toString() is '[object ClientRectConstructor]'
index daeef55..7b3c7b9 100644 (file)
@@ -1,3 +1,18 @@
+2010-06-12  Andreas Kling  <andreas.kling@nokia.com>
+
+        Reviewed by Darin Adler.
+
+        Window object should have CanvasGradient and CanvasPattern
+        https://bugs.webkit.org/show_bug.cgi?id=40394
+
+        This fixes the following tests:
+        - canvas/philip/tests/2d.gradient.object.return.html
+        - canvas/philip/tests/2d.pattern.basic.type.html
+
+        * html/canvas/CanvasGradient.idl:
+        * html/canvas/CanvasPattern.idl:
+        * page/DOMWindow.idl:
+
 2010-06-12  Dan Bernstein  <mitz@apple.com>
 
         Reviewed by Oliver Hunt.
index 32813bc..a925a26 100644 (file)
@@ -27,8 +27,7 @@ module html {
 
     interface [
         InterfaceUUID=bb1108ea-6b8c-4a08-894a-218628630cdb,
-        ImplementationUUID=a2942ae6-2731-4286-98cc-9d5e79e20de1,
-        OmitConstructor
+        ImplementationUUID=a2942ae6-2731-4286-98cc-9d5e79e20de1
     ] CanvasGradient {
 
         void addColorStop(in float offset, in DOMString color)
index 492c93f..1cac8f8 100644 (file)
@@ -27,8 +27,7 @@ module html {
 
     interface [
         InterfaceUUID=c2131348-6d8c-47b5-86cc-d41aff34ce15,
-        ImplementationUUID=82f5d713-3d17-44dd-aa4a-7766fe345940,
-        OmitConstructor
+        ImplementationUUID=82f5d713-3d17-44dd-aa4a-7766fe345940
     ] CanvasPattern {
 
     };
index 8b4256f..791ecb1 100644 (file)
@@ -448,6 +448,8 @@ module window {
         attribute [CustomGetter] HTMLImageElementConstructor Image; // Usable with new operator
         attribute [CustomGetter] HTMLOptionElementConstructor Option; // Usable with new operator
 
+        attribute CanvasPatternConstructor CanvasPattern;
+        attribute CanvasGradientConstructor CanvasGradient;
         attribute CanvasRenderingContext2DConstructor CanvasRenderingContext2D;
         attribute ImageDataConstructor ImageData;
         attribute [Conditional=3D_CANVAS,EnabledAtRuntime] WebGLRenderingContextConstructor WebGLRenderingContext;