Title: [175445] trunk/Source/WebCore
- Revision
- 175445
- Author
- [email protected]
- Date
- 2014-10-31 18:31:46 -0700 (Fri, 31 Oct 2014)
Log Message
StyleBuilder: Stop using custom code for -webkit-hyphenate-limit-lines
https://bugs.webkit.org/show_bug.cgi?id=138270
Reviewed by Antti Koivisto.
Stop using custom code for -webkit-hyphenate-limit-lines in the new
StyleBuilder. We don't really need to, we can just have a Converter
specific to this property.
No new tests, no behavior change.
* css/CSSPropertyNames.in:
* css/StyleBuilderConverter.h:
(WebCore::StyleBuilderConverter::convertWebkitHyphenateLimitLines):
* css/StyleBuilderCustom.h:
(WebCore::StyleBuilderFunctions::applyValueWebkitHyphenateLimitLines): Deleted.
Modified Paths
Diff
Modified: trunk/Source/WebCore/ChangeLog (175444 => 175445)
--- trunk/Source/WebCore/ChangeLog 2014-11-01 01:07:48 UTC (rev 175444)
+++ trunk/Source/WebCore/ChangeLog 2014-11-01 01:31:46 UTC (rev 175445)
@@ -1,5 +1,24 @@
2014-10-31 Chris Dumez <[email protected]>
+ StyleBuilder: Stop using custom code for -webkit-hyphenate-limit-lines
+ https://bugs.webkit.org/show_bug.cgi?id=138270
+
+ Reviewed by Antti Koivisto.
+
+ Stop using custom code for -webkit-hyphenate-limit-lines in the new
+ StyleBuilder. We don't really need to, we can just have a Converter
+ specific to this property.
+
+ No new tests, no behavior change.
+
+ * css/CSSPropertyNames.in:
+ * css/StyleBuilderConverter.h:
+ (WebCore::StyleBuilderConverter::convertWebkitHyphenateLimitLines):
+ * css/StyleBuilderCustom.h:
+ (WebCore::StyleBuilderFunctions::applyValueWebkitHyphenateLimitLines): Deleted.
+
+2014-10-31 Chris Dumez <[email protected]>
+
Support throttling of DOMTimers using nested setTimeout() calls
https://bugs.webkit.org/show_bug.cgi?id=138262
Modified: trunk/Source/WebCore/css/CSSPropertyNames.in (175444 => 175445)
--- trunk/Source/WebCore/css/CSSPropertyNames.in 2014-11-01 01:07:48 UTC (rev 175444)
+++ trunk/Source/WebCore/css/CSSPropertyNames.in 2014-11-01 01:31:46 UTC (rev 175445)
@@ -390,7 +390,7 @@
-webkit-hyphenate-character [Inherited]
-webkit-hyphenate-limit-after [Inherited, NewStyleBuilder, NameForMethods=HyphenationLimitAfter, Converter=Number<short>]
-webkit-hyphenate-limit-before [Inherited, NewStyleBuilder, NameForMethods=HyphenationLimitBefore, Converter=Number<short>]
--webkit-hyphenate-limit-lines [Inherited, NewStyleBuilder, NameForMethods=HyphenationLimitLines, Custom=Value]
+-webkit-hyphenate-limit-lines [Inherited, NewStyleBuilder, NameForMethods=HyphenationLimitLines, Converter=WebkitHyphenateLimitLines]
-webkit-hyphens [Inherited, NewStyleBuilder, TypeName=Hyphens]
-epub-hyphens = -webkit-hyphens
-webkit-initial-letter
Modified: trunk/Source/WebCore/css/StyleBuilderConverter.h (175444 => 175445)
--- trunk/Source/WebCore/css/StyleBuilderConverter.h 2014-11-01 01:07:48 UTC (rev 175444)
+++ trunk/Source/WebCore/css/StyleBuilderConverter.h 2014-11-01 01:31:46 UTC (rev 175445)
@@ -47,6 +47,7 @@
static LengthSize convertRadius(StyleResolver&, CSSValue&);
static TextDecoration convertTextDecoration(StyleResolver&, CSSValue&);
template <typename T> static T convertNumber(StyleResolver&, CSSValue&);
+ static short convertWebkitHyphenateLimitLines(StyleResolver&, CSSValue&);
template <CSSPropertyID property> static NinePieceImage convertBorderImage(StyleResolver&, CSSValue&);
template <CSSPropertyID property> static NinePieceImage convertBorderMask(StyleResolver&, CSSValue&);
template <CSSPropertyID property> static PassRefPtr<StyleImage> convertBorderImageSource(StyleResolver&, CSSValue&);
@@ -209,6 +210,14 @@
return primitiveValue.getValue<T>(CSSPrimitiveValue::CSS_NUMBER);
}
+inline short StyleBuilderConverter::convertWebkitHyphenateLimitLines(StyleResolver&, CSSValue& value)
+{
+ auto& primitiveValue = downcast<CSSPrimitiveValue>(value);
+ if (primitiveValue.getValueID() == CSSValueNoLimit)
+ return -1;
+ return primitiveValue.getValue<short>(CSSPrimitiveValue::CSS_NUMBER);
+}
+
template <CSSPropertyID property>
inline NinePieceImage StyleBuilderConverter::convertBorderImage(StyleResolver& styleResolver, CSSValue& value)
{
Modified: trunk/Source/WebCore/css/StyleBuilderCustom.h (175444 => 175445)
--- trunk/Source/WebCore/css/StyleBuilderCustom.h 2014-11-01 01:07:48 UTC (rev 175444)
+++ trunk/Source/WebCore/css/StyleBuilderCustom.h 2014-11-01 01:31:46 UTC (rev 175445)
@@ -33,15 +33,6 @@
namespace StyleBuilderFunctions {
-inline void applyValueWebkitHyphenateLimitLines(StyleResolver& styleResolver, CSSValue& value)
-{
- auto& primitiveValue = downcast<CSSPrimitiveValue>(value);
- short number = -1;
- if (primitiveValue.getValueID() != CSSValueNoLimit)
- number = primitiveValue.getValue<short>(CSSPrimitiveValue::CSS_NUMBER);
- styleResolver.style()->setHyphenationLimitLines(number);
-}
-
inline void applyValueWebkitMarqueeIncrement(StyleResolver& styleResolver, CSSValue& value)
{
auto& primitiveValue = downcast<CSSPrimitiveValue>(value);
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes