Chromium Code Reviews| 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 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 48 #include "core/style/StyleFilterData.h" | 48 #include "core/style/StyleFilterData.h" |
| 49 #include "core/style/StyleFlexibleBoxData.h" | 49 #include "core/style/StyleFlexibleBoxData.h" |
| 50 #include "core/style/StyleGridData.h" | 50 #include "core/style/StyleGridData.h" |
| 51 #include "core/style/StyleGridItemData.h" | 51 #include "core/style/StyleGridItemData.h" |
| 52 #include "core/style/StyleInheritedData.h" | 52 #include "core/style/StyleInheritedData.h" |
| 53 #include "core/style/StyleMotionPath.h" | 53 #include "core/style/StyleMotionPath.h" |
| 54 #include "core/style/StyleMultiColData.h" | 54 #include "core/style/StyleMultiColData.h" |
| 55 #include "core/style/StyleRareInheritedData.h" | 55 #include "core/style/StyleRareInheritedData.h" |
| 56 #include "core/style/StyleRareNonInheritedData.h" | 56 #include "core/style/StyleRareNonInheritedData.h" |
| 57 #include "core/style/StyleReflection.h" | 57 #include "core/style/StyleReflection.h" |
| 58 #include "core/style/StyleScrollSnapData.h" | |
| 58 #include "core/style/StyleSelfAlignmentData.h" | 59 #include "core/style/StyleSelfAlignmentData.h" |
| 59 #include "core/style/StyleSurroundData.h" | 60 #include "core/style/StyleSurroundData.h" |
| 60 #include "core/style/StyleTransformData.h" | 61 #include "core/style/StyleTransformData.h" |
| 61 #include "core/style/StyleVisualData.h" | 62 #include "core/style/StyleVisualData.h" |
| 62 #include "core/style/StyleWillChangeData.h" | 63 #include "core/style/StyleWillChangeData.h" |
| 63 #include "core/style/TransformOrigin.h" | 64 #include "core/style/TransformOrigin.h" |
| 64 #include "platform/Length.h" | 65 #include "platform/Length.h" |
| 65 #include "platform/LengthBox.h" | 66 #include "platform/LengthBox.h" |
| 66 #include "platform/LengthPoint.h" | 67 #include "platform/LengthPoint.h" |
| 67 #include "platform/LengthSize.h" | 68 #include "platform/LengthSize.h" |
| (...skipping 872 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 940 bool hasIsolation() const { return isolation() != IsolationAuto; } | 941 bool hasIsolation() const { return isolation() != IsolationAuto; } |
| 941 | 942 |
| 942 bool shouldPlaceBlockDirectionScrollbarOnLogicalLeft() const { return !isLef tToRightDirection() && isHorizontalWritingMode(); } | 943 bool shouldPlaceBlockDirectionScrollbarOnLogicalLeft() const { return !isLef tToRightDirection() && isHorizontalWritingMode(); } |
| 943 | 944 |
| 944 TouchAction touchAction() const { return static_cast<TouchAction>(rareNonInh eritedData->m_touchAction); } | 945 TouchAction touchAction() const { return static_cast<TouchAction>(rareNonInh eritedData->m_touchAction); } |
| 945 | 946 |
| 946 ScrollBehavior scrollBehavior() const { return static_cast<ScrollBehavior>(r areNonInheritedData->m_scrollBehavior); } | 947 ScrollBehavior scrollBehavior() const { return static_cast<ScrollBehavior>(r areNonInheritedData->m_scrollBehavior); } |
| 947 WebScrollBlocksOn scrollBlocksOn() const { return static_cast<WebScrollBlock sOn>(rareNonInheritedData->m_scrollBlocksOn); } | 948 WebScrollBlocksOn scrollBlocksOn() const { return static_cast<WebScrollBlock sOn>(rareNonInheritedData->m_scrollBlocksOn); } |
| 948 bool hasScrollBlocksOn() const { return scrollBlocksOn() != WebScrollBlocksO nNone; } | 949 bool hasScrollBlocksOn() const { return scrollBlocksOn() != WebScrollBlocksO nNone; } |
| 949 | 950 |
| 951 ScrollSnapType scrollSnapType() const { return static_cast<ScrollSnapType>(r areNonInheritedData->m_scrollSnapType); } | |
| 952 ScrollSnapPoints scrollSnapPointsX() const { return rareNonInheritedData->m_ scrollSnap->m_xPoints; } | |
| 953 ScrollSnapPoints scrollSnapPointsY() const { return rareNonInheritedData->m_ scrollSnap->m_yPoints; } | |
| 954 Vector<LengthSize> scrollSnapCoordinate() const { return rareNonInheritedDat a->m_scrollSnap->m_coordinates; } | |
| 955 LengthSize scrollSnapDestination() const { return rareNonInheritedData->m_sc rollSnap->m_destination; } | |
| 956 | |
| 957 | |
| 950 const Vector<CSSPropertyID>& willChangeProperties() const { return rareNonIn heritedData->m_willChange->m_properties; } | 958 const Vector<CSSPropertyID>& willChangeProperties() const { return rareNonIn heritedData->m_willChange->m_properties; } |
| 951 bool willChangeContents() const { return rareNonInheritedData->m_willChange- >m_contents; } | 959 bool willChangeContents() const { return rareNonInheritedData->m_willChange- >m_contents; } |
| 952 bool willChangeScrollPosition() const { return rareNonInheritedData->m_willC hange->m_scrollPosition; } | 960 bool willChangeScrollPosition() const { return rareNonInheritedData->m_willC hange->m_scrollPosition; } |
| 953 bool hasWillChangeCompositingHint() const; | 961 bool hasWillChangeCompositingHint() const; |
| 954 bool subtreeWillChangeContents() const { return rareInheritedData->m_subtree WillChangeContents; } | 962 bool subtreeWillChangeContents() const { return rareInheritedData->m_subtree WillChangeContents; } |
| 955 | 963 |
| 956 // attribute setter methods | 964 // attribute setter methods |
| 957 | 965 |
| 958 void setDisplay(EDisplay v) { noninherited_flags.effectiveDisplay = v; } | 966 void setDisplay(EDisplay v) { noninherited_flags.effectiveDisplay = v; } |
| 959 void setOriginalDisplay(EDisplay v) { noninherited_flags.originalDisplay = v ; } | 967 void setOriginalDisplay(EDisplay v) { noninherited_flags.originalDisplay = v ; } |
| (...skipping 408 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1368 | 1376 |
| 1369 void setLineBoxContain(LineBoxContain c) { SET_VAR(rareInheritedData, m_line BoxContain, c); } | 1377 void setLineBoxContain(LineBoxContain c) { SET_VAR(rareInheritedData, m_line BoxContain, c); } |
| 1370 void setLineClamp(LineClampValue c) { SET_VAR(rareNonInheritedData, lineClam p, c); } | 1378 void setLineClamp(LineClampValue c) { SET_VAR(rareNonInheritedData, lineClam p, c); } |
| 1371 void setTapHighlightColor(const Color& c) { SET_VAR(rareInheritedData, tapHi ghlightColor, c); } | 1379 void setTapHighlightColor(const Color& c) { SET_VAR(rareInheritedData, tapHi ghlightColor, c); } |
| 1372 void setTextSecurity(ETextSecurity aTextSecurity) { SET_VAR(rareInheritedDat a, textSecurity, aTextSecurity); } | 1380 void setTextSecurity(ETextSecurity aTextSecurity) { SET_VAR(rareInheritedDat a, textSecurity, aTextSecurity); } |
| 1373 void setTouchAction(TouchAction t) { SET_VAR(rareNonInheritedData, m_touchAc tion, t); } | 1381 void setTouchAction(TouchAction t) { SET_VAR(rareNonInheritedData, m_touchAc tion, t); } |
| 1374 | 1382 |
| 1375 void setScrollBehavior(ScrollBehavior b) { SET_VAR(rareNonInheritedData, m_s crollBehavior, b); } | 1383 void setScrollBehavior(ScrollBehavior b) { SET_VAR(rareNonInheritedData, m_s crollBehavior, b); } |
| 1376 void setScrollBlocksOn(WebScrollBlocksOn b) { SET_VAR(rareNonInheritedData, m_scrollBlocksOn, b); } | 1384 void setScrollBlocksOn(WebScrollBlocksOn b) { SET_VAR(rareNonInheritedData, m_scrollBlocksOn, b); } |
| 1377 | 1385 |
| 1386 void setScrollSnapType(ScrollSnapType b) { SET_VAR(rareNonInheritedData, m_s crollSnapType, b); } | |
| 1387 void setScrollSnapPointsX(const ScrollSnapPoints& b) { SET_VAR(rareNonInheri tedData.access()->m_scrollSnap, m_xPoints, b); } | |
| 1388 void setScrollSnapPointsY(const ScrollSnapPoints& b) { SET_VAR(rareNonInheri tedData.access()->m_scrollSnap, m_yPoints, b); } | |
| 1389 void setScrollSnapDestination(const LengthSize& b) { SET_VAR(rareNonInherite dData.access()->m_scrollSnap, m_destination, b); } | |
| 1390 void setScrollSnapCoordinate(const Vector<LengthSize>& b) { SET_VAR(rareNonI nheritedData.access()->m_scrollSnap, m_coordinates, b); } | |
| 1391 | |
| 1392 | |
| 1378 void setWillChangeProperties(const Vector<CSSPropertyID>& properties) { SET_ VAR(rareNonInheritedData.access()->m_willChange, m_properties, properties); } | 1393 void setWillChangeProperties(const Vector<CSSPropertyID>& properties) { SET_ VAR(rareNonInheritedData.access()->m_willChange, m_properties, properties); } |
| 1379 void setWillChangeContents(bool b) { SET_VAR(rareNonInheritedData.access()-> m_willChange, m_contents, b); } | 1394 void setWillChangeContents(bool b) { SET_VAR(rareNonInheritedData.access()-> m_willChange, m_contents, b); } |
| 1380 void setWillChangeScrollPosition(bool b) { SET_VAR(rareNonInheritedData.acce ss()->m_willChange, m_scrollPosition, b); } | 1395 void setWillChangeScrollPosition(bool b) { SET_VAR(rareNonInheritedData.acce ss()->m_willChange, m_scrollPosition, b); } |
| 1381 void setSubtreeWillChangeContents(bool b) { SET_VAR(rareInheritedData, m_sub treeWillChangeContents, b); } | 1396 void setSubtreeWillChangeContents(bool b) { SET_VAR(rareInheritedData, m_sub treeWillChangeContents, b); } |
| 1382 | 1397 |
| 1383 bool requiresAcceleratedCompositingForExternalReasons(bool b) { return rareN onInheritedData->m_requiresAcceleratedCompositingForExternalReasons; } | 1398 bool requiresAcceleratedCompositingForExternalReasons(bool b) { return rareN onInheritedData->m_requiresAcceleratedCompositingForExternalReasons; } |
| 1384 void setRequiresAcceleratedCompositingForExternalReasons(bool b) { SET_VAR(r areNonInheritedData, m_requiresAcceleratedCompositingForExternalReasons, b); } | 1399 void setRequiresAcceleratedCompositingForExternalReasons(bool b) { SET_VAR(r areNonInheritedData, m_requiresAcceleratedCompositingForExternalReasons, b); } |
| 1385 | 1400 |
| 1386 const SVGComputedStyle& svgStyle() const { return *m_svgStyle.get(); } | 1401 const SVGComputedStyle& svgStyle() const { return *m_svgStyle.get(); } |
| 1387 SVGComputedStyle& accessSVGStyle() { return *m_svgStyle.access(); } | 1402 SVGComputedStyle& accessSVGStyle() { return *m_svgStyle.access(); } |
| (...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1645 static ImageResolutionSnap initialImageResolutionSnap() { return ImageResolu tionNoSnap; } | 1660 static ImageResolutionSnap initialImageResolutionSnap() { return ImageResolu tionNoSnap; } |
| 1646 static float initialImageResolution() { return 1; } | 1661 static float initialImageResolution() { return 1; } |
| 1647 static StyleImage* initialBorderImageSource() { return 0; } | 1662 static StyleImage* initialBorderImageSource() { return 0; } |
| 1648 static StyleImage* initialMaskBoxImageSource() { return 0; } | 1663 static StyleImage* initialMaskBoxImageSource() { return 0; } |
| 1649 static PrintColorAdjust initialPrintColorAdjust() { return PrintColorAdjustE conomy; } | 1664 static PrintColorAdjust initialPrintColorAdjust() { return PrintColorAdjustE conomy; } |
| 1650 static TouchAction initialTouchAction() { return TouchActionAuto; } | 1665 static TouchAction initialTouchAction() { return TouchActionAuto; } |
| 1651 static ShadowList* initialBoxShadow() { return 0; } | 1666 static ShadowList* initialBoxShadow() { return 0; } |
| 1652 static ShadowList* initialTextShadow() { return 0; } | 1667 static ShadowList* initialTextShadow() { return 0; } |
| 1653 static ScrollBehavior initialScrollBehavior() { return ScrollBehaviorAuto; } | 1668 static ScrollBehavior initialScrollBehavior() { return ScrollBehaviorAuto; } |
| 1654 static WebScrollBlocksOn initialScrollBlocksOn() { return WebScrollBlocksOnN one; } | 1669 static WebScrollBlocksOn initialScrollBlocksOn() { return WebScrollBlocksOnN one; } |
| 1670 static ScrollSnapType initialScrollSnapType() { return ScrollSnapTypeNone; } | |
| 1671 static ScrollSnapPoints initialScrollSnapPointsX() { return ScrollSnapPoints (); } | |
| 1672 static ScrollSnapPoints initialScrollSnapPointsY() { return ScrollSnapPoints (); } | |
| 1673 static LengthSize initialScrollSnapDestination() { return LengthSize(Length( 0, Fixed), Length(0, Fixed)); } | |
| 1674 static Vector<LengthSize> initialScrollSnapCoordinate() { return Vector<Leng thSize>(); } | |
| 1675 | |
|
Timothy Loh
2015/05/28 07:09:27
nit: two extra blank lines here?
majidvp
2015/06/01 20:06:37
Done.
| |
| 1676 | |
| 1655 | 1677 |
| 1656 // The initial value is 'none' for grid tracks. | 1678 // The initial value is 'none' for grid tracks. |
| 1657 static Vector<GridTrackSize> initialGridTemplateColumns() { return Vector<Gr idTrackSize>(); } | 1679 static Vector<GridTrackSize> initialGridTemplateColumns() { return Vector<Gr idTrackSize>(); } |
| 1658 static Vector<GridTrackSize> initialGridTemplateRows() { return Vector<GridT rackSize>(); } | 1680 static Vector<GridTrackSize> initialGridTemplateRows() { return Vector<GridT rackSize>(); } |
| 1659 | 1681 |
| 1660 static GridAutoFlow initialGridAutoFlow() { return AutoFlowRow; } | 1682 static GridAutoFlow initialGridAutoFlow() { return AutoFlowRow; } |
| 1661 | 1683 |
| 1662 static GridTrackSize initialGridAutoColumns() { return GridTrackSize(Length( Auto)); } | 1684 static GridTrackSize initialGridAutoColumns() { return GridTrackSize(Length( Auto)); } |
| 1663 static GridTrackSize initialGridAutoRows() { return GridTrackSize(Length(Aut o)); } | 1685 static GridTrackSize initialGridAutoRows() { return GridTrackSize(Length(Aut o)); } |
| 1664 | 1686 |
| (...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1881 } | 1903 } |
| 1882 | 1904 |
| 1883 inline bool ComputedStyle::hasPseudoElementStyle() const | 1905 inline bool ComputedStyle::hasPseudoElementStyle() const |
| 1884 { | 1906 { |
| 1885 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK; | 1907 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK; |
| 1886 } | 1908 } |
| 1887 | 1909 |
| 1888 } // namespace blink | 1910 } // namespace blink |
| 1889 | 1911 |
| 1890 #endif // ComputedStyle_h | 1912 #endif // ComputedStyle_h |
| OLD | NEW |