| 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 |
| (...skipping 236 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 247 | 247 |
| 248 ASSERT(primitiveValue.isNumber()); | 248 ASSERT(primitiveValue.isNumber()); |
| 249 return primitiveValue.getFloatValue(); | 249 return primitiveValue.getFloatValue(); |
| 250 } | 250 } |
| 251 | 251 |
| 252 FontWeight StyleBuilderConverter::convertFontWeight(StyleResolverState& state, c
onst CSSValue& value) | 252 FontWeight StyleBuilderConverter::convertFontWeight(StyleResolverState& state, c
onst CSSValue& value) |
| 253 { | 253 { |
| 254 const CSSPrimitiveValue& primitiveValue = toCSSPrimitiveValue(value); | 254 const CSSPrimitiveValue& primitiveValue = toCSSPrimitiveValue(value); |
| 255 switch (primitiveValue.getValueID()) { | 255 switch (primitiveValue.getValueID()) { |
| 256 case CSSValueBolder: | 256 case CSSValueBolder: |
| 257 return FontDescription::bolderWeight(state.parentStyle()->fontDescriptio
n().weight()); | 257 return FontDescription::bolderWeight(state.parentStyle()->getFontDescrip
tion().weight()); |
| 258 case CSSValueLighter: | 258 case CSSValueLighter: |
| 259 return FontDescription::lighterWeight(state.parentStyle()->fontDescripti
on().weight()); | 259 return FontDescription::lighterWeight(state.parentStyle()->getFontDescri
ption().weight()); |
| 260 default: | 260 default: |
| 261 return primitiveValue.convertTo<FontWeight>(); | 261 return primitiveValue.convertTo<FontWeight>(); |
| 262 } | 262 } |
| 263 } | 263 } |
| 264 | 264 |
| 265 FontDescription::VariantLigatures StyleBuilderConverter::convertFontVariantLigat
ures(StyleResolverState&, const CSSValue& value) | 265 FontDescription::VariantLigatures StyleBuilderConverter::convertFontVariantLigat
ures(StyleResolverState&, const CSSValue& value) |
| 266 { | 266 { |
| 267 if (value.isValueList()) { | 267 if (value.isValueList()) { |
| 268 FontDescription::VariantLigatures ligatures; | 268 FontDescription::VariantLigatures ligatures; |
| 269 const CSSValueList& valueList = toCSSValueList(value); | 269 const CSSValueList& valueList = toCSSValueList(value); |
| (...skipping 672 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 942 | 942 |
| 943 PassRefPtr<StylePath> StyleBuilderConverter::convertPathOrNone(StyleResolverStat
e& state, const CSSValue& value) | 943 PassRefPtr<StylePath> StyleBuilderConverter::convertPathOrNone(StyleResolverStat
e& state, const CSSValue& value) |
| 944 { | 944 { |
| 945 if (value.isPathValue()) | 945 if (value.isPathValue()) |
| 946 return toCSSPathValue(value).stylePath(); | 946 return toCSSPathValue(value).stylePath(); |
| 947 ASSERT(value.isPrimitiveValue() && toCSSPrimitiveValue(value).getValueID() =
= CSSValueNone); | 947 ASSERT(value.isPrimitiveValue() && toCSSPrimitiveValue(value).getValueID() =
= CSSValueNone); |
| 948 return nullptr; | 948 return nullptr; |
| 949 } | 949 } |
| 950 | 950 |
| 951 } // namespace blink | 951 } // namespace blink |
| OLD | NEW |