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

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

Issue 2047283002: Avoid touching z-index in StyleAdjuster by using an isStackingContext flag instead (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Update comments Created 4 years, 5 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
Index: third_party/WebKit/Source/core/style/ComputedStyle.h
diff --git a/third_party/WebKit/Source/core/style/ComputedStyle.h b/third_party/WebKit/Source/core/style/ComputedStyle.h
index 846794602022d074be64f05839655c084cc3ca2f..fd40574d9e49f76fee176ba1ad34dff1889a08d3 100644
--- a/third_party/WebKit/Source/core/style/ComputedStyle.h
+++ b/third_party/WebKit/Source/core/style/ComputedStyle.h
@@ -1293,10 +1293,12 @@ public:
// A stacking context is painted atomically and defines a stacking order, whereas
// a containing stacking context defines in which order the stacking contexts
- // below are painted. In Blink, a stacking context is defined by non-auto
- // z-index'. This invariant is enforced by the logic in StyleAdjuster
+ // below are painted.
// See CSS 2.1, Appendix E (https://www.w3.org/TR/CSS21/zindex.html) for more details.
- bool isStackingContext() const { return !hasAutoZIndex(); }
+ bool isStackingContext() const { return rareNonInheritedData->m_isStackingContext; }
+
+ void updateIsStackingContext(bool isDocumentElement, bool isInTopLayer);
+ void setIsStackingContext(bool b) { SET_VAR(rareNonInheritedData, m_isStackingContext, b); }
// Stacking contexts and positioned elements[1] are stacked (sorted in negZOrderList
// and posZOrderList) in their enclosing stacking contexts.
« no previous file with comments | « third_party/WebKit/Source/core/paint/README.md ('k') | third_party/WebKit/Source/core/style/ComputedStyle.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698