| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * * Redistributions of source code must retain the above copyright | 4 * * Redistributions of source code must retain the above copyright |
| 5 * notice, this list of conditions and the following disclaimer. | 5 * notice, this list of conditions and the following disclaimer. |
| 6 * * Redistributions in binary form must reproduce the above | 6 * * Redistributions in binary form must reproduce the above |
| 7 * copyright notice, this list of conditions and the following disclaimer | 7 * copyright notice, this list of conditions and the following disclaimer |
| 8 * in the documentation and/or other materials provided with the | 8 * in the documentation and/or other materials provided with the |
| 9 * distribution. | 9 * distribution. |
| 10 * * Neither the name of Google Inc. nor the names of its | 10 * * Neither the name of Google Inc. nor the names of its |
| 11 * contributors may be used to endorse or promote products derived from | 11 * contributors may be used to endorse or promote products derived from |
| 12 * this software without specific prior written permission. | 12 * this software without specific prior written permission. |
| 13 * | 13 * |
| 14 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS | 14 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS |
| 15 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT | 15 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT |
| 16 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR | 16 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR |
| 17 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT | 17 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT |
| 18 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, | 18 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, |
| 19 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT | 19 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT |
| 20 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, | 20 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, |
| 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY | 21 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY |
| 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT | 22 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT |
| 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 23 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
| 24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. | 24 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 25 */ | 25 */ |
| 26 | 26 |
| 27 #ifndef StyleBuilderConverter_h | 27 #ifndef StyleBuilderConverter_h |
| 28 #define StyleBuilderConverter_h | 28 #define StyleBuilderConverter_h |
| 29 | 29 |
| 30 #include "core/css/CSSFunctionValue.h" |
| 30 #include "core/css/CSSIdentifierValue.h" | 31 #include "core/css/CSSIdentifierValue.h" |
| 31 #include "core/css/CSSStringValue.h" | 32 #include "core/css/CSSStringValue.h" |
| 32 #include "core/css/CSSValue.h" | 33 #include "core/css/CSSValue.h" |
| 33 #include "core/css/CSSValueList.h" | 34 #include "core/css/CSSValueList.h" |
| 34 #include "core/css/CSSValuePair.h" | 35 #include "core/css/CSSValuePair.h" |
| 35 #include "core/css/resolver/StyleResolverState.h" | 36 #include "core/css/resolver/StyleResolverState.h" |
| 36 #include "core/style/QuotesData.h" | 37 #include "core/style/QuotesData.h" |
| 37 #include "core/style/ShadowList.h" | 38 #include "core/style/ShadowList.h" |
| 38 #include "core/style/StyleOffsetRotation.h" | 39 #include "core/style/StyleOffsetRotation.h" |
| 39 #include "core/style/StyleReflection.h" | 40 #include "core/style/StyleReflection.h" |
| (...skipping 26 matching lines...) Expand all Loading... |
| 66 static Color convertColor(StyleResolverState&, | 67 static Color convertColor(StyleResolverState&, |
| 67 const CSSValue&, | 68 const CSSValue&, |
| 68 bool forVisitedLink = false); | 69 bool forVisitedLink = false); |
| 69 template <typename T> | 70 template <typename T> |
| 70 static T convertComputedLength(StyleResolverState&, const CSSValue&); | 71 static T convertComputedLength(StyleResolverState&, const CSSValue&); |
| 71 static LengthBox convertClip(StyleResolverState&, const CSSValue&); | 72 static LengthBox convertClip(StyleResolverState&, const CSSValue&); |
| 72 static PassRefPtr<ClipPathOperation> convertClipPath(StyleResolverState&, | 73 static PassRefPtr<ClipPathOperation> convertClipPath(StyleResolverState&, |
| 73 const CSSValue&); | 74 const CSSValue&); |
| 74 static FilterOperations convertFilterOperations(StyleResolverState&, | 75 static FilterOperations convertFilterOperations(StyleResolverState&, |
| 75 const CSSValue&); | 76 const CSSValue&); |
| 77 static FilterOperations convertOffscreenFilterOperations(const CSSValue&); |
| 76 template <typename T> | 78 template <typename T> |
| 77 static T convertFlags(StyleResolverState&, const CSSValue&); | 79 static T convertFlags(StyleResolverState&, const CSSValue&); |
| 78 static FontDescription::FamilyDescription convertFontFamily( | 80 static FontDescription::FamilyDescription convertFontFamily( |
| 79 StyleResolverState&, | 81 StyleResolverState&, |
| 80 const CSSValue&); | 82 const CSSValue&); |
| 81 static PassRefPtr<FontFeatureSettings> convertFontFeatureSettings( | 83 static PassRefPtr<FontFeatureSettings> convertFontFeatureSettings( |
| 82 StyleResolverState&, | 84 StyleResolverState&, |
| 83 const CSSValue&); | 85 const CSSValue&); |
| 84 static PassRefPtr<FontVariationSettings> convertFontVariationSettings( | 86 static PassRefPtr<FontVariationSettings> convertFontVariationSettings( |
| 85 StyleResolverState&, | 87 StyleResolverState&, |
| (...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 123 const CSSValue&); | 125 const CSSValue&); |
| 124 static LengthPoint convertPosition(StyleResolverState&, const CSSValue&); | 126 static LengthPoint convertPosition(StyleResolverState&, const CSSValue&); |
| 125 static LengthPoint convertPositionOrAuto(StyleResolverState&, | 127 static LengthPoint convertPositionOrAuto(StyleResolverState&, |
| 126 const CSSValue&); | 128 const CSSValue&); |
| 127 static float convertPerspective(StyleResolverState&, const CSSValue&); | 129 static float convertPerspective(StyleResolverState&, const CSSValue&); |
| 128 static Length convertQuirkyLength(StyleResolverState&, const CSSValue&); | 130 static Length convertQuirkyLength(StyleResolverState&, const CSSValue&); |
| 129 static PassRefPtr<QuotesData> convertQuotes(StyleResolverState&, | 131 static PassRefPtr<QuotesData> convertQuotes(StyleResolverState&, |
| 130 const CSSValue&); | 132 const CSSValue&); |
| 131 static LengthSize convertRadius(StyleResolverState&, const CSSValue&); | 133 static LengthSize convertRadius(StyleResolverState&, const CSSValue&); |
| 132 static EPaintOrder convertPaintOrder(StyleResolverState&, const CSSValue&); | 134 static EPaintOrder convertPaintOrder(StyleResolverState&, const CSSValue&); |
| 133 static ShadowData convertShadow(StyleResolverState&, const CSSValue&); | 135 static ShadowData convertShadow(const CSSToLengthConversionData&, |
| 136 StyleResolverState*, |
| 137 const CSSValue&); |
| 138 static double convertValueToNumber(const CSSFunctionValue*, |
| 139 const CSSPrimitiveValue*); |
| 134 static PassRefPtr<ShadowList> convertShadowList(StyleResolverState&, | 140 static PassRefPtr<ShadowList> convertShadowList(StyleResolverState&, |
| 135 const CSSValue&); | 141 const CSSValue&); |
| 136 static ShapeValue* convertShapeValue(StyleResolverState&, const CSSValue&); | 142 static ShapeValue* convertShapeValue(StyleResolverState&, const CSSValue&); |
| 137 static float convertSpacing(StyleResolverState&, const CSSValue&); | 143 static float convertSpacing(StyleResolverState&, const CSSValue&); |
| 138 template <CSSValueID IdForNone> | 144 template <CSSValueID IdForNone> |
| 139 static AtomicString convertString(StyleResolverState&, const CSSValue&); | 145 static AtomicString convertString(StyleResolverState&, const CSSValue&); |
| 140 static PassRefPtr<SVGDashArray> convertStrokeDasharray(StyleResolverState&, | 146 static PassRefPtr<SVGDashArray> convertStrokeDasharray(StyleResolverState&, |
| 141 const CSSValue&); | 147 const CSSValue&); |
| 142 static StyleColor convertStyleColor(StyleResolverState&, | 148 static StyleColor convertStyleColor(StyleResolverState&, |
| 143 const CSSValue&, | 149 const CSSValue&, |
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 282 const CSSValue& value) { | 288 const CSSValue& value) { |
| 283 if (value.isStringValue()) | 289 if (value.isStringValue()) |
| 284 return AtomicString(toCSSStringValue(value).value()); | 290 return AtomicString(toCSSStringValue(value).value()); |
| 285 DCHECK_EQ(toCSSIdentifierValue(value).getValueID(), IdForNone); | 291 DCHECK_EQ(toCSSIdentifierValue(value).getValueID(), IdForNone); |
| 286 return nullAtom; | 292 return nullAtom; |
| 287 } | 293 } |
| 288 | 294 |
| 289 } // namespace blink | 295 } // namespace blink |
| 290 | 296 |
| 291 #endif | 297 #endif |
| OLD | NEW |