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

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

Issue 1910263003: Generate CSSPropertyEquality instead of using hand-updated file. Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: tests2! Created 4 years, 7 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 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 class TranslateTransformOperation; 125 class TranslateTransformOperation;
126 126
127 class ContentData; 127 class ContentData;
128 128
129 typedef Vector<RefPtr<ComputedStyle>, 4> PseudoStyleCache; 129 typedef Vector<RefPtr<ComputedStyle>, 4> PseudoStyleCache;
130 130
131 class CORE_EXPORT ComputedStyle: public RefCounted<ComputedStyle> { 131 class CORE_EXPORT ComputedStyle: public RefCounted<ComputedStyle> {
132 friend class AnimatedStyleBuilder; // Used by Web Animations CSS. Sets the c olor styles 132 friend class AnimatedStyleBuilder; // Used by Web Animations CSS. Sets the c olor styles
133 friend class CSSAnimatableValueFactory; // Used by Web Animations CSS. Gets visited and unvisited colors separately. 133 friend class CSSAnimatableValueFactory; // Used by Web Animations CSS. Gets visited and unvisited colors separately.
134 friend class CSSPropertyEquality; // Used by CSS animations. We can't allow them to animate based off visited colors. 134 friend class CSSPropertyEquality; // Used by CSS animations. We can't allow them to animate based off visited colors.
135 friend class CSSPropertyEqualityCustom; // Used by CSS animations. We can't allow them to animate based off visited colors.
Timothy Loh 2016/05/24 05:38:35 do we need to friend both of these?
135 friend class ApplyStyleCommand; // Editing has to only reveal unvisited info . 136 friend class ApplyStyleCommand; // Editing has to only reveal unvisited info .
136 friend class EditingStyle; // Editing has to only reveal unvisited info. 137 friend class EditingStyle; // Editing has to only reveal unvisited info.
137 friend class ComputedStyleCSSValueMapping; // Needs to be able to see visite d and unvisited colors for devtools. 138 friend class ComputedStyleCSSValueMapping; // Needs to be able to see visite d and unvisited colors for devtools.
138 friend class StyleBuilderFunctions; // Sets color styles 139 friend class StyleBuilderFunctions; // Sets color styles
139 friend class CachedUAStyle; // Saves Border/Background information for later comparison. 140 friend class CachedUAStyle; // Saves Border/Background information for later comparison.
140 friend class ColorPropertyFunctions; // Accesses visited and unvisited color s. 141 friend class ColorPropertyFunctions; // Accesses visited and unvisited color s.
141 142
142 // FIXME: When we stop resolving currentColor at style time, these can be re moved. 143 // FIXME: When we stop resolving currentColor at style time, these can be re moved.
143 friend class CSSToStyleMap; 144 friend class CSSToStyleMap;
144 friend class FilterOperationResolver; 145 friend class FilterOperationResolver;
(...skipping 809 matching lines...) Expand 10 before | Expand all | Expand 10 after
954 955
955 RespectImageOrientationEnum respectImageOrientation() const { return static_ cast<RespectImageOrientationEnum>(rareInheritedData->m_respectImageOrientation); } 956 RespectImageOrientationEnum respectImageOrientation() const { return static_ cast<RespectImageOrientationEnum>(rareInheritedData->m_respectImageOrientation); }
956 957
957 // End CSS3 Getters 958 // End CSS3 Getters
958 959
959 // Apple-specific property getter methods 960 // Apple-specific property getter methods
960 EPointerEvents pointerEvents() const { return static_cast<EPointerEvents>(in herited_flags._pointerEvents); } 961 EPointerEvents pointerEvents() const { return static_cast<EPointerEvents>(in herited_flags._pointerEvents); }
961 const CSSAnimationData* animations() const { return rareNonInheritedData->m_ animations.get(); } 962 const CSSAnimationData* animations() const { return rareNonInheritedData->m_ animations.get(); }
962 const CSSTransitionData* transitions() const { return rareNonInheritedData-> m_transitions.get(); } 963 const CSSTransitionData* transitions() const { return rareNonInheritedData-> m_transitions.get(); }
963 964
965 const Vector<double>* transitionDelayList() const { return transitions() ? & transitions()->delayList() : nullptr; }
966 const Vector<double>* transitionDurationList() const { return transitions() ? &transitions()->durationList() : nullptr; }
967 const Vector<RefPtr<TimingFunction>>* transitionTimingFunctionList() const { return transitions() ? &transitions()->timingFunctionList() : nullptr; }
968 const Vector<CSSTransitionData::TransitionProperty>* transitionPropertyList( ) const { return transitions() ? &transitions()->propertyList() : nullptr; }
969
970 const Vector<double>* animationDelayList() const { return animations() ? &an imations()->delayList() : nullptr; }
971 const Vector<double>* animationDurationList() const { return animations() ? &animations()->durationList() : nullptr; }
972 const Vector<RefPtr<TimingFunction>>* animationTimingFunctionList() const { return animations() ? &animations()-> timingFunctionList() : nullptr; }
973 const Vector<AtomicString>* animationNameList() const { return animations() ? &animations()->nameList() : nullptr; }
974 const Vector<double>* animationIterationCountList() const { return animation s() ? &animations()->iterationCountList() : nullptr; }
975 const Vector<Timing::PlaybackDirection>* animationDirectionList() const { re turn animations() ? &animations()->directionList() : nullptr; }
976 const Vector<Timing::FillMode>* animationFillModeList() const { return anima tions() ? &animations()->fillModeList() : nullptr; }
977 const Vector<EAnimPlayState>* animationPlayStateList() const { return animat ions() ? &animations()->playStateList() : nullptr; }
978
964 CSSAnimationData& accessAnimations(); 979 CSSAnimationData& accessAnimations();
965 CSSTransitionData& accessTransitions(); 980 CSSTransitionData& accessTransitions();
966 981
967 ETransformStyle3D transformStyle3D() const { return static_cast<ETransformSt yle3D>(rareNonInheritedData->m_transformStyle3D); } 982 ETransformStyle3D transformStyle3D() const { return static_cast<ETransformSt yle3D>(rareNonInheritedData->m_transformStyle3D); }
968 bool preserves3D() const { return rareNonInheritedData->m_transformStyle3D = = TransformStyle3DPreserve3D; } 983 bool preserves3D() const { return rareNonInheritedData->m_transformStyle3D = = TransformStyle3DPreserve3D; }
969 984
970 EBackfaceVisibility backfaceVisibility() const { return static_cast<EBackfac eVisibility>(rareNonInheritedData->m_backfaceVisibility); } 985 EBackfaceVisibility backfaceVisibility() const { return static_cast<EBackfac eVisibility>(rareNonInheritedData->m_backfaceVisibility); }
971 float perspective() const { return rareNonInheritedData->m_perspective; } 986 float perspective() const { return rareNonInheritedData->m_perspective; }
972 bool hasPerspective() const { return rareNonInheritedData->m_perspective > 0 ; } 987 bool hasPerspective() const { return rareNonInheritedData->m_perspective > 0 ; }
973 const LengthPoint& perspectiveOrigin() const { return rareNonInheritedData-> m_perspectiveOrigin; } 988 const LengthPoint& perspectiveOrigin() const { return rareNonInheritedData-> m_perspectiveOrigin; }
(...skipping 1068 matching lines...) Expand 10 before | Expand all | Expand 10 after
2042 } 2057 }
2043 2058
2044 inline bool ComputedStyle::hasPseudoElementStyle() const 2059 inline bool ComputedStyle::hasPseudoElementStyle() const
2045 { 2060 {
2046 return noninherited_flags.pseudoBits & ElementPseudoIdMask; 2061 return noninherited_flags.pseudoBits & ElementPseudoIdMask;
2047 } 2062 }
2048 2063
2049 } // namespace blink 2064 } // namespace blink
2050 2065
2051 #endif // ComputedStyle_h 2066 #endif // ComputedStyle_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698