Title: [113009] trunk/Source/WebCore
Revision
113009
Author
[email protected]
Date
2012-04-03 04:26:50 -0700 (Tue, 03 Apr 2012)

Log Message

2012-04-03  Nikolas Zimmermann  <[email protected]>

        Enable animVal support for SVGAnimatedEnumeration
        https://bugs.webkit.org/show_bug.cgi?id=82459

        Rubber-stamped by Zoltan Herczeg.

        Make highestEnumValue() return an unsigned to avoid casting in SVGAnimatedEnumerationPropertyTearOff.
        Fixes the last chromium build failure on the debug carnary bots.

        * svg/SVGComponentTransferFunctionElement.h:
        * svg/SVGFEBlendElement.h:
        * svg/SVGFEColorMatrixElement.h:
        * svg/SVGFECompositeElement.h:
        * svg/SVGFEConvolveMatrixElement.h:
        * svg/SVGFEDisplacementMapElement.h:
        * svg/SVGFEMorphologyElement.h:
        * svg/SVGFETurbulenceElement.h:
        * svg/SVGGradientElement.h:
        * svg/SVGMarkerElement.h:
        * svg/SVGTextContentElement.h:
        * svg/SVGTextPathElement.h:
        * svg/SVGUnitTypes.h:
        * svg/properties/SVGAnimatedEnumerationPropertyTearOff.h:
        (WebCore::SVGAnimatedEnumerationPropertyTearOff::setBaseVal):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (113008 => 113009)


--- trunk/Source/WebCore/ChangeLog	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/ChangeLog	2012-04-03 11:26:50 UTC (rev 113009)
@@ -1,3 +1,29 @@
+2012-04-03  Nikolas Zimmermann  <[email protected]>
+
+        Enable animVal support for SVGAnimatedEnumeration
+        https://bugs.webkit.org/show_bug.cgi?id=82459
+
+        Rubber-stamped by Zoltan Herczeg.
+
+        Make highestEnumValue() return an unsigned to avoid casting in SVGAnimatedEnumerationPropertyTearOff.
+        Fixes the last chromium build failure on the debug carnary bots.
+
+        * svg/SVGComponentTransferFunctionElement.h:
+        * svg/SVGFEBlendElement.h:
+        * svg/SVGFEColorMatrixElement.h:
+        * svg/SVGFECompositeElement.h:
+        * svg/SVGFEConvolveMatrixElement.h:
+        * svg/SVGFEDisplacementMapElement.h:
+        * svg/SVGFEMorphologyElement.h:
+        * svg/SVGFETurbulenceElement.h:
+        * svg/SVGGradientElement.h:
+        * svg/SVGMarkerElement.h:
+        * svg/SVGTextContentElement.h:
+        * svg/SVGTextPathElement.h:
+        * svg/SVGUnitTypes.h:
+        * svg/properties/SVGAnimatedEnumerationPropertyTearOff.h:
+        (WebCore::SVGAnimatedEnumerationPropertyTearOff::setBaseVal):
+
 2012-04-01  Nikolas Zimmermann  <[email protected]>
 
         Animate animatedPoints instead of points for SVGPoly*Elements

Modified: trunk/Source/WebCore/svg/SVGComponentTransferFunctionElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGComponentTransferFunctionElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGComponentTransferFunctionElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -31,7 +31,7 @@
 
 template<>
 struct SVGPropertyTraits<ComponentTransferType> {
-    static ComponentTransferType highestEnumValue() { return FECOMPONENTTRANSFER_TYPE_GAMMA; }
+    static unsigned highestEnumValue() { return FECOMPONENTTRANSFER_TYPE_GAMMA; }
 
     static String toString(ComponentTransferType type)
     {

Modified: trunk/Source/WebCore/svg/SVGFEBlendElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGFEBlendElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGFEBlendElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -30,7 +30,7 @@
 
 template<>
 struct SVGPropertyTraits<BlendModeType> {
-    static BlendModeType highestEnumValue() { return FEBLEND_MODE_LIGHTEN; }
+    static unsigned highestEnumValue() { return FEBLEND_MODE_LIGHTEN; }
 
     static String toString(BlendModeType type)
     {

Modified: trunk/Source/WebCore/svg/SVGFEColorMatrixElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGFEColorMatrixElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGFEColorMatrixElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -31,7 +31,7 @@
 
 template<>
 struct SVGPropertyTraits<ColorMatrixType> {
-    static ColorMatrixType highestEnumValue() { return FECOLORMATRIX_TYPE_LUMINANCETOALPHA; }
+    static unsigned highestEnumValue() { return FECOLORMATRIX_TYPE_LUMINANCETOALPHA; }
 
     static String toString(ColorMatrixType type)
     {

Modified: trunk/Source/WebCore/svg/SVGFECompositeElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGFECompositeElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGFECompositeElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -31,7 +31,7 @@
 
 template<>
 struct SVGPropertyTraits<CompositeOperationType> {
-    static CompositeOperationType highestEnumValue() { return FECOMPOSITE_OPERATOR_ARITHMETIC; }
+    static unsigned highestEnumValue() { return FECOMPOSITE_OPERATOR_ARITHMETIC; }
 
     static String toString(CompositeOperationType type)
     {

Modified: trunk/Source/WebCore/svg/SVGFEConvolveMatrixElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGFEConvolveMatrixElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGFEConvolveMatrixElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -33,7 +33,7 @@
 
 template<>
 struct SVGPropertyTraits<EdgeModeType> {
-    static EdgeModeType highestEnumValue() { return EDGEMODE_NONE; }
+    static unsigned highestEnumValue() { return EDGEMODE_NONE; }
 
     static String toString(EdgeModeType type)
     {

Modified: trunk/Source/WebCore/svg/SVGFEDisplacementMapElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGFEDisplacementMapElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGFEDisplacementMapElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -30,7 +30,7 @@
  
 template<>
 struct SVGPropertyTraits<ChannelSelectorType> {
-    static ChannelSelectorType highestEnumValue() { return CHANNEL_A; }
+    static unsigned highestEnumValue() { return CHANNEL_A; }
 
     static String toString(ChannelSelectorType type)
     {

Modified: trunk/Source/WebCore/svg/SVGFEMorphologyElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGFEMorphologyElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGFEMorphologyElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -30,7 +30,7 @@
 
 template<>
 struct SVGPropertyTraits<MorphologyOperatorType> {
-    static MorphologyOperatorType highestEnumValue() { return FEMORPHOLOGY_OPERATOR_DILATE; }
+    static unsigned highestEnumValue() { return FEMORPHOLOGY_OPERATOR_DILATE; }
 
     static String toString(MorphologyOperatorType type)
     {

Modified: trunk/Source/WebCore/svg/SVGFETurbulenceElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGFETurbulenceElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGFETurbulenceElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -38,7 +38,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGStitchOptions> {
-    static SVGStitchOptions highestEnumValue() { return SVG_STITCHTYPE_NOSTITCH; }
+    static unsigned highestEnumValue() { return SVG_STITCHTYPE_NOSTITCH; }
 
     static String toString(SVGStitchOptions type)
     {
@@ -67,7 +67,7 @@
 
 template<>
 struct SVGPropertyTraits<TurbulenceType> {
-    static TurbulenceType highestEnumValue() { return FETURBULENCE_TYPE_TURBULENCE; }
+    static unsigned highestEnumValue() { return FETURBULENCE_TYPE_TURBULENCE; }
 
     static String toString(TurbulenceType type)
     {

Modified: trunk/Source/WebCore/svg/SVGGradientElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGGradientElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGGradientElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -42,7 +42,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGSpreadMethodType> {
-    static SVGSpreadMethodType highestEnumValue() { return SVGSpreadMethodRepeat; }
+    static unsigned highestEnumValue() { return SVGSpreadMethodRepeat; }
 
     static String toString(SVGSpreadMethodType type)
     {

Modified: trunk/Source/WebCore/svg/SVGMarkerElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGMarkerElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGMarkerElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -49,7 +49,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGMarkerUnitsType> {
-    static SVGMarkerUnitsType highestEnumValue() { return SVGMarkerUnitsStrokeWidth; }
+    static unsigned highestEnumValue() { return SVGMarkerUnitsStrokeWidth; }
 
     static String toString(SVGMarkerUnitsType type)
     {
@@ -78,7 +78,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGMarkerOrientType> {
-    static SVGMarkerOrientType highestEnumValue() { return SVGMarkerOrientAngle; }
+    static unsigned highestEnumValue() { return SVGMarkerOrientAngle; }
 
     // toString is not needed, synchronizeOrientType() handles this on its own.
 

Modified: trunk/Source/WebCore/svg/SVGTextContentElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGTextContentElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGTextContentElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -40,7 +40,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGLengthAdjustType> {
-    static SVGLengthAdjustType highestEnumValue() { return SVGLengthAdjustSpacingAndGlyphs; }
+    static unsigned highestEnumValue() { return SVGLengthAdjustSpacingAndGlyphs; }
 
     static String toString(SVGLengthAdjustType type)
     {

Modified: trunk/Source/WebCore/svg/SVGTextPathElement.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGTextPathElement.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGTextPathElement.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -41,7 +41,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGTextPathMethodType> {
-    static SVGTextPathMethodType highestEnumValue() { return SVGTextPathMethodStretch; }
+    static unsigned highestEnumValue() { return SVGTextPathMethodStretch; }
 
     static String toString(SVGTextPathMethodType type)
     {
@@ -70,7 +70,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGTextPathSpacingType> {
-    static SVGTextPathSpacingType highestEnumValue() { return SVGTextPathSpacingExact; }
+    static unsigned highestEnumValue() { return SVGTextPathSpacingExact; }
 
     static String toString(SVGTextPathSpacingType type)
     {

Modified: trunk/Source/WebCore/svg/SVGUnitTypes.h (113008 => 113009)


--- trunk/Source/WebCore/svg/SVGUnitTypes.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/SVGUnitTypes.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -40,7 +40,7 @@
 
 template<>
 struct SVGPropertyTraits<SVGUnitTypes::SVGUnitType> {
-    static SVGUnitTypes::SVGUnitType highestEnumValue() { return SVGUnitTypes::SVG_UNIT_TYPE_OBJECTBOUNDINGBOX; }
+    static unsigned highestEnumValue() { return SVGUnitTypes::SVG_UNIT_TYPE_OBJECTBOUNDINGBOX; }
 
     static String toString(SVGUnitTypes::SVGUnitType type)
     {

Modified: trunk/Source/WebCore/svg/properties/SVGAnimatedEnumerationPropertyTearOff.h (113008 => 113009)


--- trunk/Source/WebCore/svg/properties/SVGAnimatedEnumerationPropertyTearOff.h	2012-04-03 10:36:01 UTC (rev 113008)
+++ trunk/Source/WebCore/svg/properties/SVGAnimatedEnumerationPropertyTearOff.h	2012-04-03 11:26:50 UTC (rev 113009)
@@ -33,7 +33,7 @@
     virtual void setBaseVal(const unsigned& property, ExceptionCode& ec)
     {
         // All SVG enumeration values, that are allowed to be set via SVG DOM start with 1, 0 corresponds to unknown and is not settable through SVG DOM.
-        if (!property || property > static_cast<unsigned>(SVGPropertyTraits<EnumType>::highestEnumValue())) {
+        if (!property || property > SVGPropertyTraits<EnumType>::highestEnumValue()) {
             ec = SVGException::SVG_INVALID_VALUE_ERR;
             return;
         }
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to