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

Unified Diff: third_party/WebKit/Source/core/style/StyleDifference.h

Issue 2772353002: Revert of Add StyleDifference::needsVisualRectUpdate (Closed)
Patch Set: Created 3 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/style/ComputedStyle.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/style/StyleDifference.h
diff --git a/third_party/WebKit/Source/core/style/StyleDifference.h b/third_party/WebKit/Source/core/style/StyleDifference.h
index b7756955b884a12e4c90933757836312826af685..64d62ac5b1f4a488f47af701dfcf7a86cffe2bad 100644
--- a/third_party/WebKit/Source/core/style/StyleDifference.h
+++ b/third_party/WebKit/Source/core/style/StyleDifference.h
@@ -24,7 +24,6 @@
// The object needs to issue paint invalidations if it is affected by text
// decorations or properties dependent on color (e.g., border or outline).
TextDecorationOrColorChanged = 1 << 6,
- ScrollAnchorDisablingPropertyChanged = 1 << 7,
// If you add a value here, be sure to update the number of bits on
// m_propertySpecificDifferences.
};
@@ -33,13 +32,17 @@
: m_paintInvalidationType(NoPaintInvalidation),
m_layoutType(NoLayout),
m_recomputeOverflow(false),
- m_visualRectUpdate(false),
- m_propertySpecificDifferences(0) {}
+ m_propertySpecificDifferences(0),
+ m_scrollAnchorDisablingPropertyChanged(false) {}
bool hasDifference() const {
- return m_paintInvalidationType || m_layoutType ||
- m_propertySpecificDifferences || m_recomputeOverflow ||
- m_visualRectUpdate;
+ bool result = m_paintInvalidationType || m_layoutType ||
+ m_propertySpecificDifferences;
+ // m_recomputeOverflow, m_scrollAnchorDisablingPropertyChanged and
+ // are never set without other flags set.
+ DCHECK(result ||
+ (!m_recomputeOverflow && !m_scrollAnchorDisablingPropertyChanged));
+ return result;
}
bool hasAtMostPropertySpecificDifferences(
@@ -87,9 +90,6 @@
bool needsRecomputeOverflow() const { return m_recomputeOverflow; }
void setNeedsRecomputeOverflow() { m_recomputeOverflow = true; }
- bool needsVisualRectUpdate() const { return m_visualRectUpdate; }
- void setNeedsVisualRectUpdate() { m_visualRectUpdate = true; }
-
bool transformChanged() const {
return m_propertySpecificDifferences & TransformChanged;
}
@@ -132,10 +132,10 @@
}
bool scrollAnchorDisablingPropertyChanged() const {
- return m_propertySpecificDifferences & ScrollAnchorDisablingPropertyChanged;
+ return m_scrollAnchorDisablingPropertyChanged;
}
void setScrollAnchorDisablingPropertyChanged() {
- m_propertySpecificDifferences |= ScrollAnchorDisablingPropertyChanged;
+ m_scrollAnchorDisablingPropertyChanged = true;
}
private:
@@ -149,8 +149,8 @@
enum LayoutType { NoLayout = 0, PositionedMovement, FullLayout };
unsigned m_layoutType : 2;
unsigned m_recomputeOverflow : 1;
- unsigned m_visualRectUpdate : 1;
- unsigned m_propertySpecificDifferences : 8;
+ unsigned m_propertySpecificDifferences : 7;
+ unsigned m_scrollAnchorDisablingPropertyChanged : 1;
};
} // namespace blink
« no previous file with comments | « third_party/WebKit/Source/core/style/ComputedStyle.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698