Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(366)

Side by Side Diff: Source/core/style/ComputedStyle.h

Issue 1158603003: CSS Independent Transform Properties (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Correct equality operators and remove dependencies on size() in parser Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
69 #include "platform/ThemeTypes.h" 69 #include "platform/ThemeTypes.h"
70 #include "platform/fonts/FontBaseline.h" 70 #include "platform/fonts/FontBaseline.h"
71 #include "platform/fonts/FontDescription.h" 71 #include "platform/fonts/FontDescription.h"
72 #include "platform/geometry/FloatRoundedRect.h" 72 #include "platform/geometry/FloatRoundedRect.h"
73 #include "platform/geometry/LayoutRectOutsets.h" 73 #include "platform/geometry/LayoutRectOutsets.h"
74 #include "platform/graphics/Color.h" 74 #include "platform/graphics/Color.h"
75 #include "platform/graphics/GraphicsTypes.h" 75 #include "platform/graphics/GraphicsTypes.h"
76 #include "platform/scroll/ScrollableArea.h" 76 #include "platform/scroll/ScrollableArea.h"
77 #include "platform/text/TextDirection.h" 77 #include "platform/text/TextDirection.h"
78 #include "platform/text/UnicodeBidi.h" 78 #include "platform/text/UnicodeBidi.h"
79 #include "platform/transforms/RotateTransformOperation.h"
80 #include "platform/transforms/ScaleTransformOperation.h"
79 #include "platform/transforms/TransformOperations.h" 81 #include "platform/transforms/TransformOperations.h"
82 #include "platform/transforms/TranslateTransformOperation.h"
80 #include "public/platform/WebScrollBlocksOn.h" 83 #include "public/platform/WebScrollBlocksOn.h"
81 #include "wtf/Forward.h" 84 #include "wtf/Forward.h"
82 #include "wtf/OwnPtr.h" 85 #include "wtf/OwnPtr.h"
83 #include "wtf/RefCounted.h" 86 #include "wtf/RefCounted.h"
84 #include "wtf/StdLibExtras.h" 87 #include "wtf/StdLibExtras.h"
85 #include "wtf/Vector.h" 88 #include "wtf/Vector.h"
86 89
87 template<typename T, typename U> inline bool compareEqual(const T& t, const U& u ) { return t == static_cast<T>(u); } 90 template<typename T, typename U> inline bool compareEqual(const T& t, const U& u ) { return t == static_cast<T>(u); }
88 91
89 #define SET_VAR(group, variable, value) \ 92 #define SET_VAR(group, variable, value) \
(...skipping 748 matching lines...) Expand 10 before | Expand all | Expand 10 after
838 ColumnSpan columnSpan() const { return static_cast<ColumnSpan>(rareNonInheri tedData->m_multiCol->m_columnSpan); } 841 ColumnSpan columnSpan() const { return static_cast<ColumnSpan>(rareNonInheri tedData->m_multiCol->m_columnSpan); }
839 EPageBreak columnBreakBefore() const { return static_cast<EPageBreak>(rareNo nInheritedData->m_multiCol->m_breakBefore); } 842 EPageBreak columnBreakBefore() const { return static_cast<EPageBreak>(rareNo nInheritedData->m_multiCol->m_breakBefore); }
840 EPageBreak columnBreakInside() const { return static_cast<EPageBreak>(rareNo nInheritedData->m_multiCol->m_breakInside); } 843 EPageBreak columnBreakInside() const { return static_cast<EPageBreak>(rareNo nInheritedData->m_multiCol->m_breakInside); }
841 EPageBreak columnBreakAfter() const { return static_cast<EPageBreak>(rareNon InheritedData->m_multiCol->m_breakAfter); } 844 EPageBreak columnBreakAfter() const { return static_cast<EPageBreak>(rareNon InheritedData->m_multiCol->m_breakAfter); }
842 bool hasInlineTransform() const { return rareNonInheritedData->m_hasInlineTr ansform; } 845 bool hasInlineTransform() const { return rareNonInheritedData->m_hasInlineTr ansform; }
843 bool hasCompositorProxy() const { return rareNonInheritedData->m_hasComposit orProxy; } 846 bool hasCompositorProxy() const { return rareNonInheritedData->m_hasComposit orProxy; }
844 const TransformOperations& transform() const { return rareNonInheritedData-> m_transform->m_operations; } 847 const TransformOperations& transform() const { return rareNonInheritedData-> m_transform->m_operations; }
845 const TransformOrigin& transformOrigin() const { return rareNonInheritedData ->m_transform->m_origin; } 848 const TransformOrigin& transformOrigin() const { return rareNonInheritedData ->m_transform->m_origin; }
846 const Length& transformOriginX() const { return transformOrigin().x(); } 849 const Length& transformOriginX() const { return transformOrigin().x(); }
847 const Length& transformOriginY() const { return transformOrigin().y(); } 850 const Length& transformOriginY() const { return transformOrigin().y(); }
851 TranslateTransformOperation* translate() const { return rareNonInheritedData ->m_transform->m_translate.get(); }
852 RotateTransformOperation* rotate() const { return rareNonInheritedData->m_tr ansform->m_rotate.get(); }
853 ScaleTransformOperation* scale() const { return rareNonInheritedData->m_tran sform->m_scale.get(); }
848 float transformOriginZ() const { return transformOrigin().z(); } 854 float transformOriginZ() const { return transformOrigin().z(); }
849 bool hasTransform() const { return hasTransformOperations() || hasMotionPath () || hasCurrentTransformAnimation(); } 855 bool hasTranslateProperty() const { return rareNonInheritedData->m_transform ->m_translate; }
856 bool hasRotateProperty() const { return rareNonInheritedData->m_transform->m _rotate; }
857 bool hasScaleProperty() const { return rareNonInheritedData->m_transform->m_ scale; }
858 bool has3DTransformProperties() const { return rareNonInheritedData->m_trans form->has3DTransformProperties(); }
859 bool hasTransformProperties() const { return hasTranslateProperty() || hasRo tateProperty() || hasScaleProperty(); }
860 bool hasTransform() const { return hasTransformOperations() || hasMotionPath () || hasCurrentTransformAnimation() || hasTransformProperties(); }
850 bool transformDataEquivalent(const ComputedStyle& otherStyle) const { return rareNonInheritedData->m_transform == otherStyle.rareNonInheritedData->m_transfo rm; } 861 bool transformDataEquivalent(const ComputedStyle& otherStyle) const { return rareNonInheritedData->m_transform == otherStyle.rareNonInheritedData->m_transfo rm; }
851 862
852 StyleMotionPath* motionPath() const { return rareNonInheritedData->m_transfo rm->m_motion.m_path.get(); } 863 StyleMotionPath* motionPath() const { return rareNonInheritedData->m_transfo rm->m_motion.m_path.get(); }
853 bool hasMotionPath() const { return rareNonInheritedData->m_transform->m_mot ion.m_path; } 864 bool hasMotionPath() const { return rareNonInheritedData->m_transform->m_mot ion.m_path; }
854 const Length& motionOffset() const { return rareNonInheritedData->m_transfor m->m_motion.m_offset; } 865 const Length& motionOffset() const { return rareNonInheritedData->m_transfor m->m_motion.m_offset; }
855 float motionRotation() const { return rareNonInheritedData->m_transform->m_m otion.m_rotation; } 866 float motionRotation() const { return rareNonInheritedData->m_transform->m_m otion.m_rotation; }
856 MotionRotationType motionRotationType() const { return rareNonInheritedData- >m_transform->m_motion.m_rotationType; } 867 MotionRotationType motionRotationType() const { return rareNonInheritedData- >m_transform->m_motion.m_rotationType; }
857 868
858 TextEmphasisFill textEmphasisFill() const { return static_cast<TextEmphasisF ill>(rareInheritedData->textEmphasisFill); } 869 TextEmphasisFill textEmphasisFill() const { return static_cast<TextEmphasisF ill>(rareInheritedData->textEmphasisFill); }
859 TextEmphasisMark textEmphasisMark() const; 870 TextEmphasisMark textEmphasisMark() const;
860 const AtomicString& textEmphasisCustomMark() const { return rareInheritedDat a->textEmphasisCustomMark; } 871 const AtomicString& textEmphasisCustomMark() const { return rareInheritedDat a->textEmphasisCustomMark; }
861 TextEmphasisPosition textEmphasisPosition() const { return static_cast<TextE mphasisPosition>(rareInheritedData->textEmphasisPosition); } 872 TextEmphasisPosition textEmphasisPosition() const { return static_cast<TextE mphasisPosition>(rareInheritedData->textEmphasisPosition); }
862 const AtomicString& textEmphasisMarkString() const; 873 const AtomicString& textEmphasisMarkString() const;
863 874
864 RubyPosition rubyPosition() const { return static_cast<RubyPosition>(rareInh eritedData->m_rubyPosition); } 875 RubyPosition rubyPosition() const { return static_cast<RubyPosition>(rareInh eritedData->m_rubyPosition); }
865 876
866 TextOrientation textOrientation() const { return static_cast<TextOrientation >(rareInheritedData->m_textOrientation); } 877 TextOrientation textOrientation() const { return static_cast<TextOrientation >(rareInheritedData->m_textOrientation); }
867 878
868 ObjectFit objectFit() const { return static_cast<ObjectFit>(rareNonInherited Data->m_objectFit); } 879 ObjectFit objectFit() const { return static_cast<ObjectFit>(rareNonInherited Data->m_objectFit); }
869 LengthPoint objectPosition() const { return rareNonInheritedData->m_objectPo sition; } 880 LengthPoint objectPosition() const { return rareNonInheritedData->m_objectPo sition; }
870 881
871 // Return true if any transform related property (currently transform/motion Path, transformStyle3D or perspective) 882 // Return true if any transform related property (currently transform/motion Path, transformStyle3D or perspective)
872 // indicates that we are transforming 883 // indicates that we are transforming
873 bool hasTransformRelatedProperty() const { return hasTransform() || preserve s3D() || hasPerspective(); } 884 bool hasTransformRelatedProperty() const { return hasTransform() || preserve s3D() || hasPerspective(); }
874 885
875 enum ApplyTransformOrigin { IncludeTransformOrigin, ExcludeTransformOrigin } ; 886 enum ApplyTransformOrigin { IncludeTransformOrigin, ExcludeTransformOrigin } ;
876 enum ApplyMotionPath { IncludeMotionPath, ExcludeMotionPath }; 887 enum ApplyMotionPath { IncludeMotionPath, ExcludeMotionPath };
877 void applyTransform(TransformationMatrix&, const LayoutSize& borderBoxSize, ApplyTransformOrigin = IncludeTransformOrigin, ApplyMotionPath = IncludeMotionPa th) const; 888 enum ApplyTransformProperty { IncludeTransformProperty, ExcludeTransformProp erty };
878 void applyTransform(TransformationMatrix&, const FloatRect& boundingBox, App lyTransformOrigin = IncludeTransformOrigin, ApplyMotionPath = IncludeMotionPath) const; 889 void applyTransform(TransformationMatrix&, const LayoutSize& borderBoxSize, ApplyTransformOrigin = IncludeTransformOrigin, ApplyMotionPath = IncludeMotionPa th, ApplyTransformProperty = IncludeTransformProperty) const;
890 void applyTransform(TransformationMatrix&, const FloatRect& boundingBox, App lyTransformOrigin = IncludeTransformOrigin, ApplyMotionPath = IncludeMotionPath, ApplyTransformProperty = IncludeTransformProperty) const;
879 891
880 bool hasMask() const { return rareNonInheritedData->m_mask.hasImage() || rar eNonInheritedData->m_maskBoxImage.hasImage(); } 892 bool hasMask() const { return rareNonInheritedData->m_mask.hasImage() || rar eNonInheritedData->m_maskBoxImage.hasImage(); }
881 893
882 TextCombine textCombine() const { return static_cast<TextCombine>(rareNonInh eritedData->m_textCombine); } 894 TextCombine textCombine() const { return static_cast<TextCombine>(rareNonInh eritedData->m_textCombine); }
883 bool hasTextCombine() const { return textCombine() != TextCombineNone; } 895 bool hasTextCombine() const { return textCombine() != TextCombineNone; }
884 896
885 TabSize tabSize() const { return rareInheritedData->m_tabSize; } 897 TabSize tabSize() const { return rareInheritedData->m_tabSize; }
886 898
887 // End CSS3 Getters 899 // End CSS3 Getters
888 900
(...skipping 444 matching lines...) Expand 10 before | Expand all | Expand 10 after
1333 void setColumnBreakInside(EPageBreak p) { ASSERT(p == PBAUTO || p == PBAVOID ); SET_VAR(rareNonInheritedData.access()->m_multiCol, m_breakInside, p); } 1345 void setColumnBreakInside(EPageBreak p) { ASSERT(p == PBAUTO || p == PBAVOID ); SET_VAR(rareNonInheritedData.access()->m_multiCol, m_breakInside, p); }
1334 void setColumnBreakAfter(EPageBreak p) { SET_VAR(rareNonInheritedData.access ()->m_multiCol, m_breakAfter, p); } 1346 void setColumnBreakAfter(EPageBreak p) { SET_VAR(rareNonInheritedData.access ()->m_multiCol, m_breakAfter, p); }
1335 void inheritColumnPropertiesFrom(const ComputedStyle& parent) { rareNonInher itedData.access()->m_multiCol = parent.rareNonInheritedData->m_multiCol; } 1347 void inheritColumnPropertiesFrom(const ComputedStyle& parent) { rareNonInher itedData.access()->m_multiCol = parent.rareNonInheritedData->m_multiCol; }
1336 void setHasInlineTransform(bool b) { SET_VAR(rareNonInheritedData, m_hasInli neTransform, b); } 1348 void setHasInlineTransform(bool b) { SET_VAR(rareNonInheritedData, m_hasInli neTransform, b); }
1337 void setHasCompositorProxy(bool b) { SET_VAR(rareNonInheritedData, m_hasComp ositorProxy, b); } 1349 void setHasCompositorProxy(bool b) { SET_VAR(rareNonInheritedData, m_hasComp ositorProxy, b); }
1338 void setTransform(const TransformOperations& ops) { SET_VAR(rareNonInherited Data.access()->m_transform, m_operations, ops); } 1350 void setTransform(const TransformOperations& ops) { SET_VAR(rareNonInherited Data.access()->m_transform, m_operations, ops); }
1339 void setTransformOriginX(const Length& v) { setTransformOrigin(TransformOrig in(v, transformOriginY(), transformOriginZ())); } 1351 void setTransformOriginX(const Length& v) { setTransformOrigin(TransformOrig in(v, transformOriginY(), transformOriginZ())); }
1340 void setTransformOriginY(const Length& v) { setTransformOrigin(TransformOrig in(transformOriginX(), v, transformOriginZ())); } 1352 void setTransformOriginY(const Length& v) { setTransformOrigin(TransformOrig in(transformOriginX(), v, transformOriginZ())); }
1341 void setTransformOriginZ(float f) { setTransformOrigin(TransformOrigin(trans formOriginX(), transformOriginY(), f)); } 1353 void setTransformOriginZ(float f) { setTransformOrigin(TransformOrigin(trans formOriginX(), transformOriginY(), f)); }
1342 void setTransformOrigin(const TransformOrigin& o) { SET_VAR(rareNonInherited Data.access()->m_transform, m_origin, o); } 1354 void setTransformOrigin(const TransformOrigin& o) { SET_VAR(rareNonInherited Data.access()->m_transform, m_origin, o); }
1355 void setTranslate(PassRefPtr<TranslateTransformOperation> v) { rareNonInheri tedData.access()->m_transform.access()->setTranslate(v); }
1356 void setRotate(PassRefPtr<RotateTransformOperation> v) { rareNonInheritedDat a.access()->m_transform.access()->setRotate(v); }
1357 void setScale(PassRefPtr<ScaleTransformOperation> v) { rareNonInheritedData. access()->m_transform.access()->setScale(v); }
1358
1343 void setSpeak(ESpeak s) { SET_VAR(rareInheritedData, speak, s); } 1359 void setSpeak(ESpeak s) { SET_VAR(rareInheritedData, speak, s); }
1344 void setTextCombine(TextCombine v) { SET_VAR(rareNonInheritedData, m_textCom bine, v); } 1360 void setTextCombine(TextCombine v) { SET_VAR(rareNonInheritedData, m_textCom bine, v); }
1345 void setTextDecorationColor(const StyleColor& c) { SET_VAR(rareNonInheritedD ata, m_textDecorationColor, c); } 1361 void setTextDecorationColor(const StyleColor& c) { SET_VAR(rareNonInheritedD ata, m_textDecorationColor, c); }
1346 void setTextEmphasisColor(const StyleColor& c) { SET_VAR_WITH_SETTER(rareInh eritedData, textEmphasisColor, setTextEmphasisColor, c); } 1362 void setTextEmphasisColor(const StyleColor& c) { SET_VAR_WITH_SETTER(rareInh eritedData, textEmphasisColor, setTextEmphasisColor, c); }
1347 void setTextEmphasisFill(TextEmphasisFill fill) { SET_VAR(rareInheritedData, textEmphasisFill, fill); } 1363 void setTextEmphasisFill(TextEmphasisFill fill) { SET_VAR(rareInheritedData, textEmphasisFill, fill); }
1348 void setTextEmphasisMark(TextEmphasisMark mark) { SET_VAR(rareInheritedData, textEmphasisMark, mark); } 1364 void setTextEmphasisMark(TextEmphasisMark mark) { SET_VAR(rareInheritedData, textEmphasisMark, mark); }
1349 void setTextEmphasisCustomMark(const AtomicString& mark) { SET_VAR(rareInher itedData, textEmphasisCustomMark, mark); } 1365 void setTextEmphasisCustomMark(const AtomicString& mark) { SET_VAR(rareInher itedData, textEmphasisCustomMark, mark); }
1350 void setTextEmphasisPosition(TextEmphasisPosition position) { SET_VAR(rareIn heritedData, textEmphasisPosition, position); } 1366 void setTextEmphasisPosition(TextEmphasisPosition position) { SET_VAR(rareIn heritedData, textEmphasisPosition, position); }
1351 bool setTextOrientation(TextOrientation); 1367 bool setTextOrientation(TextOrientation);
1352 1368
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after
1641 static const AtomicString& initialHyphenationString() { return nullAtom; } 1657 static const AtomicString& initialHyphenationString() { return nullAtom; }
1642 static const AtomicString& initialLocale() { return nullAtom; } 1658 static const AtomicString& initialLocale() { return nullAtom; }
1643 static EResize initialResize() { return RESIZE_NONE; } 1659 static EResize initialResize() { return RESIZE_NONE; }
1644 static ControlPart initialAppearance() { return NoControlPart; } 1660 static ControlPart initialAppearance() { return NoControlPart; }
1645 static Order initialRTLOrdering() { return LogicalOrder; } 1661 static Order initialRTLOrdering() { return LogicalOrder; }
1646 static float initialTextStrokeWidth() { return 0; } 1662 static float initialTextStrokeWidth() { return 0; }
1647 static unsigned short initialColumnCount() { return 1; } 1663 static unsigned short initialColumnCount() { return 1; }
1648 static ColumnFill initialColumnFill() { return ColumnFillBalance; } 1664 static ColumnFill initialColumnFill() { return ColumnFillBalance; }
1649 static ColumnSpan initialColumnSpan() { return ColumnSpanNone; } 1665 static ColumnSpan initialColumnSpan() { return ColumnSpanNone; }
1650 static const TransformOperations& initialTransform() { DEFINE_STATIC_LOCAL(T ransformOperations, ops, ()); return ops; } 1666 static const TransformOperations& initialTransform() { DEFINE_STATIC_LOCAL(T ransformOperations, ops, ()); return ops; }
1667 static const PassRefPtr<TranslateTransformOperation> initialTranslate() { re turn TranslateTransformOperation::create(Length(0, Fixed), Length(0, Fixed), 0, TransformOperation::TranslateX); }
1668 static const PassRefPtr<RotateTransformOperation> initialRotate() { return R otateTransformOperation::create(0, 0, 1, 0, TransformOperation::Rotate); }
1669 static const PassRefPtr<ScaleTransformOperation> initialScale() { return Sca leTransformOperation::create(1, 1, 1, TransformOperation::ScaleX); }
1651 static Length initialTransformOriginX() { return Length(50.0, Percent); } 1670 static Length initialTransformOriginX() { return Length(50.0, Percent); }
1652 static Length initialTransformOriginY() { return Length(50.0, Percent); } 1671 static Length initialTransformOriginY() { return Length(50.0, Percent); }
1653 static float initialTransformOriginZ() { return 0; } 1672 static float initialTransformOriginZ() { return 0; }
1654 static TransformOrigin initialTransformOrigin() { return TransformOrigin(Len gth(50.0, Percent), Length(50.0, Percent), 0); } 1673 static TransformOrigin initialTransformOrigin() { return TransformOrigin(Len gth(50.0, Percent), Length(50.0, Percent), 0); }
1655 static EPointerEvents initialPointerEvents() { return PE_AUTO; } 1674 static EPointerEvents initialPointerEvents() { return PE_AUTO; }
1656 static ETransformStyle3D initialTransformStyle3D() { return TransformStyle3D Flat; } 1675 static ETransformStyle3D initialTransformStyle3D() { return TransformStyle3D Flat; }
1657 static const StyleMotionPath* initialMotionPath() { return nullptr; } 1676 static const StyleMotionPath* initialMotionPath() { return nullptr; }
1658 static Length initialMotionOffset() { return Length(0, Fixed); } 1677 static Length initialMotionOffset() { return Length(0, Fixed); }
1659 static float initialMotionRotation() { return 0; } 1678 static float initialMotionRotation() { return 0; }
1660 static MotionRotationType initialMotionRotationType() { return MotionRotatio nAuto; } 1679 static MotionRotationType initialMotionRotationType() { return MotionRotatio nAuto; }
(...skipping 144 matching lines...) Expand 10 before | Expand all | Expand 10 after
1805 void appendContent(PassOwnPtr<ContentData>); 1824 void appendContent(PassOwnPtr<ContentData>);
1806 void addAppliedTextDecoration(const AppliedTextDecoration&); 1825 void addAppliedTextDecoration(const AppliedTextDecoration&);
1807 bool hasTransformOperations() const { return !rareNonInheritedData->m_transf orm->m_operations.operations().isEmpty(); } 1826 bool hasTransformOperations() const { return !rareNonInheritedData->m_transf orm->m_operations.operations().isEmpty(); }
1808 void applyMotionPathTransform(TransformationMatrix&) const; 1827 void applyMotionPathTransform(TransformationMatrix&) const;
1809 1828
1810 bool diffNeedsFullLayoutAndPaintInvalidation(const ComputedStyle& other) con st; 1829 bool diffNeedsFullLayoutAndPaintInvalidation(const ComputedStyle& other) con st;
1811 bool diffNeedsFullLayout(const ComputedStyle& other) const; 1830 bool diffNeedsFullLayout(const ComputedStyle& other) const;
1812 bool diffNeedsPaintInvalidationLayer(const ComputedStyle& other) const; 1831 bool diffNeedsPaintInvalidationLayer(const ComputedStyle& other) const;
1813 bool diffNeedsPaintInvalidationObject(const ComputedStyle& other) const; 1832 bool diffNeedsPaintInvalidationObject(const ComputedStyle& other) const;
1814 void updatePropertySpecificDifferences(const ComputedStyle& other, StyleDiff erence&) const; 1833 void updatePropertySpecificDifferences(const ComputedStyle& other, StyleDiff erence&) const;
1834
1835 bool requireTransformOrigin(ApplyTransformOrigin applyOrigin, ApplyMotionPat h) const;
1815 }; 1836 };
1816 1837
1817 // FIXME: Reduce/remove the dependency on zoom adjusted int values. 1838 // FIXME: Reduce/remove the dependency on zoom adjusted int values.
1818 // The float or LayoutUnit versions of layout values should be used. 1839 // The float or LayoutUnit versions of layout values should be used.
1819 inline int adjustForAbsoluteZoom(int value, float zoomFactor) 1840 inline int adjustForAbsoluteZoom(int value, float zoomFactor)
1820 { 1841 {
1821 if (zoomFactor == 1) 1842 if (zoomFactor == 1)
1822 return value; 1843 return value;
1823 // Needed because computeLengthInt truncates (rather than rounds) when scali ng up. 1844 // Needed because computeLengthInt truncates (rather than rounds) when scali ng up.
1824 float fvalue = value; 1845 float fvalue = value;
(...skipping 92 matching lines...) Expand 10 before | Expand all | Expand 10 after
1917 } 1938 }
1918 1939
1919 inline bool ComputedStyle::hasPseudoElementStyle() const 1940 inline bool ComputedStyle::hasPseudoElementStyle() const
1920 { 1941 {
1921 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK; 1942 return noninherited_flags.pseudoBits & PSEUDO_ELEMENT_MASK;
1922 } 1943 }
1923 1944
1924 } // namespace blink 1945 } // namespace blink
1925 1946
1926 #endif // ComputedStyle_h 1947 #endif // ComputedStyle_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698