| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
| 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) | 3 * (C) 2000 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2000 Dirk Mueller (mueller@kde.org) | 4 * (C) 2000 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. | 5 * Copyright (C) 2003, 2005, 2006, 2007, 2008, 2009, 2010, 2011 Apple Inc. All r
ights reserved. |
| 6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) | 6 * Copyright (C) 2006 Graham Dennis (graham.dennis@gmail.com) |
| 7 * | 7 * |
| 8 * This library is free software; you can redistribute it and/or | 8 * This library is free software; you can redistribute it and/or |
| 9 * modify it under the terms of the GNU Library General Public | 9 * modify it under the terms of the GNU Library General Public |
| 10 * License as published by the Free Software Foundation; either | 10 * License as published by the Free Software Foundation; either |
| (...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 66 #include "platform/fonts/FontBaseline.h" | 66 #include "platform/fonts/FontBaseline.h" |
| 67 #include "platform/fonts/FontDescription.h" | 67 #include "platform/fonts/FontDescription.h" |
| 68 #include "platform/geometry/FloatRoundedRect.h" | 68 #include "platform/geometry/FloatRoundedRect.h" |
| 69 #include "platform/geometry/LayoutRectOutsets.h" | 69 #include "platform/geometry/LayoutRectOutsets.h" |
| 70 #include "platform/graphics/Color.h" | 70 #include "platform/graphics/Color.h" |
| 71 #include "platform/graphics/GraphicsTypes.h" | 71 #include "platform/graphics/GraphicsTypes.h" |
| 72 #include "platform/scroll/ScrollableArea.h" | 72 #include "platform/scroll/ScrollableArea.h" |
| 73 #include "platform/text/TextDirection.h" | 73 #include "platform/text/TextDirection.h" |
| 74 #include "platform/text/UnicodeBidi.h" | 74 #include "platform/text/UnicodeBidi.h" |
| 75 #include "platform/transforms/TransformOperations.h" | 75 #include "platform/transforms/TransformOperations.h" |
| 76 #include "public/platform/WebScrollBlocksOn.h" |
| 76 #include "wtf/Forward.h" | 77 #include "wtf/Forward.h" |
| 77 #include "wtf/OwnPtr.h" | 78 #include "wtf/OwnPtr.h" |
| 78 #include "wtf/RefCounted.h" | 79 #include "wtf/RefCounted.h" |
| 79 #include "wtf/StdLibExtras.h" | 80 #include "wtf/StdLibExtras.h" |
| 80 #include "wtf/Vector.h" | 81 #include "wtf/Vector.h" |
| 81 | 82 |
| 82 template<typename T, typename U> inline bool compareEqual(const T& t, const U& u
) { return t == static_cast<T>(u); } | 83 template<typename T, typename U> inline bool compareEqual(const T& t, const U& u
) { return t == static_cast<T>(u); } |
| 83 | 84 |
| 84 #define SET_VAR(group, variable, value) \ | 85 #define SET_VAR(group, variable, value) \ |
| 85 if (!compareEqual(group->variable, value)) \ | 86 if (!compareEqual(group->variable, value)) \ |
| (...skipping 826 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 912 | 913 |
| 913 EIsolation isolation() const { return static_cast<EIsolation>(rareNonInherit
edData->m_isolation); } | 914 EIsolation isolation() const { return static_cast<EIsolation>(rareNonInherit
edData->m_isolation); } |
| 914 void setIsolation(EIsolation v) { rareNonInheritedData.access()->m_isolation
= v; } | 915 void setIsolation(EIsolation v) { rareNonInheritedData.access()->m_isolation
= v; } |
| 915 bool hasIsolation() const { return isolation() != IsolationAuto; } | 916 bool hasIsolation() const { return isolation() != IsolationAuto; } |
| 916 | 917 |
| 917 bool shouldPlaceBlockDirectionScrollbarOnLogicalLeft() const { return !isLef
tToRightDirection() && isHorizontalWritingMode(); } | 918 bool shouldPlaceBlockDirectionScrollbarOnLogicalLeft() const { return !isLef
tToRightDirection() && isHorizontalWritingMode(); } |
| 918 | 919 |
| 919 TouchAction touchAction() const { return static_cast<TouchAction>(rareNonInh
eritedData->m_touchAction); } | 920 TouchAction touchAction() const { return static_cast<TouchAction>(rareNonInh
eritedData->m_touchAction); } |
| 920 | 921 |
| 921 ScrollBehavior scrollBehavior() const { return static_cast<ScrollBehavior>(r
areNonInheritedData->m_scrollBehavior); } | 922 ScrollBehavior scrollBehavior() const { return static_cast<ScrollBehavior>(r
areNonInheritedData->m_scrollBehavior); } |
| 922 ScrollBlocksOn scrollBlocksOn() const { return static_cast<ScrollBlocksOn>(r
areNonInheritedData->m_scrollBlocksOn); } | 923 WebScrollBlocksOn scrollBlocksOn() const { return static_cast<WebScrollBlock
sOn>(rareNonInheritedData->m_scrollBlocksOn); } |
| 924 bool hasScrollBlocksOn() const { return scrollBlocksOn() != WebScrollBlocksO
nNone; } |
| 923 | 925 |
| 924 const Vector<CSSPropertyID>& willChangeProperties() const { return rareNonIn
heritedData->m_willChange->m_properties; } | 926 const Vector<CSSPropertyID>& willChangeProperties() const { return rareNonIn
heritedData->m_willChange->m_properties; } |
| 925 bool willChangeContents() const { return rareNonInheritedData->m_willChange-
>m_contents; } | 927 bool willChangeContents() const { return rareNonInheritedData->m_willChange-
>m_contents; } |
| 926 bool willChangeScrollPosition() const { return rareNonInheritedData->m_willC
hange->m_scrollPosition; } | 928 bool willChangeScrollPosition() const { return rareNonInheritedData->m_willC
hange->m_scrollPosition; } |
| 927 bool hasWillChangeCompositingHint() const; | 929 bool hasWillChangeCompositingHint() const; |
| 928 bool subtreeWillChangeContents() const { return rareInheritedData->m_subtree
WillChangeContents; } | 930 bool subtreeWillChangeContents() const { return rareInheritedData->m_subtree
WillChangeContents; } |
| 929 | 931 |
| 930 // attribute setter methods | 932 // attribute setter methods |
| 931 | 933 |
| 932 void setDisplay(EDisplay v) { noninherited_flags.effectiveDisplay = v; } | 934 void setDisplay(EDisplay v) { noninherited_flags.effectiveDisplay = v; } |
| (...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1328 void setIsRunningTransformAnimationOnCompositor(bool b = true) { SET_VAR(rar
eNonInheritedData, m_runningTransformAnimationOnCompositor, b); } | 1330 void setIsRunningTransformAnimationOnCompositor(bool b = true) { SET_VAR(rar
eNonInheritedData, m_runningTransformAnimationOnCompositor, b); } |
| 1329 void setIsRunningFilterAnimationOnCompositor(bool b = true) { SET_VAR(rareNo
nInheritedData, m_runningFilterAnimationOnCompositor, b); } | 1331 void setIsRunningFilterAnimationOnCompositor(bool b = true) { SET_VAR(rareNo
nInheritedData, m_runningFilterAnimationOnCompositor, b); } |
| 1330 | 1332 |
| 1331 void setLineBoxContain(LineBoxContain c) { SET_VAR(rareInheritedData, m_line
BoxContain, c); } | 1333 void setLineBoxContain(LineBoxContain c) { SET_VAR(rareInheritedData, m_line
BoxContain, c); } |
| 1332 void setLineClamp(LineClampValue c) { SET_VAR(rareNonInheritedData, lineClam
p, c); } | 1334 void setLineClamp(LineClampValue c) { SET_VAR(rareNonInheritedData, lineClam
p, c); } |
| 1333 void setTapHighlightColor(const Color& c) { SET_VAR(rareInheritedData, tapHi
ghlightColor, c); } | 1335 void setTapHighlightColor(const Color& c) { SET_VAR(rareInheritedData, tapHi
ghlightColor, c); } |
| 1334 void setTextSecurity(ETextSecurity aTextSecurity) { SET_VAR(rareInheritedDat
a, textSecurity, aTextSecurity); } | 1336 void setTextSecurity(ETextSecurity aTextSecurity) { SET_VAR(rareInheritedDat
a, textSecurity, aTextSecurity); } |
| 1335 void setTouchAction(TouchAction t) { SET_VAR(rareNonInheritedData, m_touchAc
tion, t); } | 1337 void setTouchAction(TouchAction t) { SET_VAR(rareNonInheritedData, m_touchAc
tion, t); } |
| 1336 | 1338 |
| 1337 void setScrollBehavior(ScrollBehavior b) { SET_VAR(rareNonInheritedData, m_s
crollBehavior, b); } | 1339 void setScrollBehavior(ScrollBehavior b) { SET_VAR(rareNonInheritedData, m_s
crollBehavior, b); } |
| 1338 void setScrollBlocksOn(ScrollBlocksOn b) { SET_VAR(rareNonInheritedData, m_s
crollBlocksOn, b); } | 1340 void setScrollBlocksOn(WebScrollBlocksOn b) { SET_VAR(rareNonInheritedData,
m_scrollBlocksOn, b); } |
| 1339 | 1341 |
| 1340 void setWillChangeProperties(const Vector<CSSPropertyID>& properties) { SET_
VAR(rareNonInheritedData.access()->m_willChange, m_properties, properties); } | 1342 void setWillChangeProperties(const Vector<CSSPropertyID>& properties) { SET_
VAR(rareNonInheritedData.access()->m_willChange, m_properties, properties); } |
| 1341 void setWillChangeContents(bool b) { SET_VAR(rareNonInheritedData.access()->
m_willChange, m_contents, b); } | 1343 void setWillChangeContents(bool b) { SET_VAR(rareNonInheritedData.access()->
m_willChange, m_contents, b); } |
| 1342 void setWillChangeScrollPosition(bool b) { SET_VAR(rareNonInheritedData.acce
ss()->m_willChange, m_scrollPosition, b); } | 1344 void setWillChangeScrollPosition(bool b) { SET_VAR(rareNonInheritedData.acce
ss()->m_willChange, m_scrollPosition, b); } |
| 1343 void setSubtreeWillChangeContents(bool b) { SET_VAR(rareInheritedData, m_sub
treeWillChangeContents, b); } | 1345 void setSubtreeWillChangeContents(bool b) { SET_VAR(rareInheritedData, m_sub
treeWillChangeContents, b); } |
| 1344 | 1346 |
| 1345 bool requiresAcceleratedCompositingForExternalReasons(bool b) { return rareN
onInheritedData->m_requiresAcceleratedCompositingForExternalReasons; } | 1347 bool requiresAcceleratedCompositingForExternalReasons(bool b) { return rareN
onInheritedData->m_requiresAcceleratedCompositingForExternalReasons; } |
| 1346 void setRequiresAcceleratedCompositingForExternalReasons(bool b) { SET_VAR(r
areNonInheritedData, m_requiresAcceleratedCompositingForExternalReasons, b); } | 1348 void setRequiresAcceleratedCompositingForExternalReasons(bool b) { SET_VAR(r
areNonInheritedData, m_requiresAcceleratedCompositingForExternalReasons, b); } |
| 1347 | 1349 |
| 1348 const SVGRenderStyle& svgStyle() const { return *m_svgStyle.get(); } | 1350 const SVGRenderStyle& svgStyle() const { return *m_svgStyle.get(); } |
| (...skipping 255 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1604 static ImageResolutionSource initialImageResolutionSource() { return ImageRe
solutionSpecified; } | 1606 static ImageResolutionSource initialImageResolutionSource() { return ImageRe
solutionSpecified; } |
| 1605 static ImageResolutionSnap initialImageResolutionSnap() { return ImageResolu
tionNoSnap; } | 1607 static ImageResolutionSnap initialImageResolutionSnap() { return ImageResolu
tionNoSnap; } |
| 1606 static float initialImageResolution() { return 1; } | 1608 static float initialImageResolution() { return 1; } |
| 1607 static StyleImage* initialBorderImageSource() { return 0; } | 1609 static StyleImage* initialBorderImageSource() { return 0; } |
| 1608 static StyleImage* initialMaskBoxImageSource() { return 0; } | 1610 static StyleImage* initialMaskBoxImageSource() { return 0; } |
| 1609 static PrintColorAdjust initialPrintColorAdjust() { return PrintColorAdjustE
conomy; } | 1611 static PrintColorAdjust initialPrintColorAdjust() { return PrintColorAdjustE
conomy; } |
| 1610 static TouchAction initialTouchAction() { return TouchActionAuto; } | 1612 static TouchAction initialTouchAction() { return TouchActionAuto; } |
| 1611 static ShadowList* initialBoxShadow() { return 0; } | 1613 static ShadowList* initialBoxShadow() { return 0; } |
| 1612 static ShadowList* initialTextShadow() { return 0; } | 1614 static ShadowList* initialTextShadow() { return 0; } |
| 1613 static ScrollBehavior initialScrollBehavior() { return ScrollBehaviorAuto; } | 1615 static ScrollBehavior initialScrollBehavior() { return ScrollBehaviorAuto; } |
| 1614 static ScrollBlocksOn initialScrollBlocksOn() { return ScrollBlocksOnNone; } | 1616 static WebScrollBlocksOn initialScrollBlocksOn() { return WebScrollBlocksOnN
one; } |
| 1615 | 1617 |
| 1616 // The initial value is 'none' for grid tracks. | 1618 // The initial value is 'none' for grid tracks. |
| 1617 static Vector<GridTrackSize> initialGridTemplateColumns() { return Vector<Gr
idTrackSize>(); } | 1619 static Vector<GridTrackSize> initialGridTemplateColumns() { return Vector<Gr
idTrackSize>(); } |
| 1618 static Vector<GridTrackSize> initialGridTemplateRows() { return Vector<GridT
rackSize>(); } | 1620 static Vector<GridTrackSize> initialGridTemplateRows() { return Vector<GridT
rackSize>(); } |
| 1619 | 1621 |
| 1620 static GridAutoFlow initialGridAutoFlow() { return AutoFlowRow; } | 1622 static GridAutoFlow initialGridAutoFlow() { return AutoFlowRow; } |
| 1621 | 1623 |
| 1622 static GridTrackSize initialGridAutoColumns() { return GridTrackSize(Length(
Auto)); } | 1624 static GridTrackSize initialGridAutoColumns() { return GridTrackSize(Length(
Auto)); } |
| 1623 static GridTrackSize initialGridAutoRows() { return GridTrackSize(Length(Aut
o)); } | 1625 static GridTrackSize initialGridAutoRows() { return GridTrackSize(Length(Aut
o)); } |
| 1624 | 1626 |
| (...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1843 inline bool RenderStyle::hasPseudoElementStyle() const | 1845 inline bool RenderStyle::hasPseudoElementStyle() const |
| 1844 { | 1846 { |
| 1845 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK; | 1847 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK; |
| 1846 } | 1848 } |
| 1847 | 1849 |
| 1848 float calcBorderRadiiConstraintScaleFor(const FloatRect&, const FloatRoundedRect
::Radii&); | 1850 float calcBorderRadiiConstraintScaleFor(const FloatRect&, const FloatRoundedRect
::Radii&); |
| 1849 | 1851 |
| 1850 } // namespace blink | 1852 } // namespace blink |
| 1851 | 1853 |
| 1852 #endif // RenderStyle_h | 1854 #endif // RenderStyle_h |
| OLD | NEW |