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

Unified Diff: third_party/WebKit/LayoutTests/css3/blending/isolation-isolate-simple.html

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/LayoutTests/css3/blending/isolation-isolate-simple.html
diff --git a/third_party/WebKit/LayoutTests/css3/blending/isolation-isolate-simple.html b/third_party/WebKit/LayoutTests/css3/blending/isolation-isolate-simple.html
index 851c7658f61b8a1a8a8cf72c4508bf7eca750bbb..56d374ed442b1929919c333972b2d07fa5cc4a52 100644
--- a/third_party/WebKit/LayoutTests/css3/blending/isolation-isolate-simple.html
+++ b/third_party/WebKit/LayoutTests/css3/blending/isolation-isolate-simple.html
@@ -1,28 +1,32 @@
<!DOCTYPE HTML>
-<html>
-<head>
<style>
- div {
- width: 10px;
- height: 10px;
- background: green;
- isolation:isolate;
- }
+.red {
+ position: absolute;
+ width: 100px;
+ height: 200px;
+ background-color: red;
+ z-index: 0;
+}
+.green {
+ width: 100px;
+ height: 100px;
+ background-color: green;
+ z-index: -1;
+}
+.isolate {
+ width: 100px;
+ height: 100px;
+ isolation: isolate;
+}
+.layer {
+ transform: translateZ(0);
+}
</style>
-<!-- Isolation should create a stacking context. Test if "isolation:isolate" sets the zIndex to 0, instead of the default "auto" value. -->
-<body>
- <div id="isolator"></div>
- <div id="isolator_accelerated" style="transform: translateZ(0)"></div>
- <script src="../../resources/js-test.js"></script>
- <script>
- // Software path.
- var zIndex = getComputedStyle(document.getElementById("isolator")).zIndex;
- shouldBeZero(zIndex);
-
- // Hardware path.
- zIndex = getComputedStyle(document.getElementById("isolator_accelerated")).zIndex;
- shouldBeZero(zIndex);
- </script>
-</body>
-</html>
+<div class="red"></div>
+<div class="isolate">
+ <div class="green"></div>
+</div>
+<div class="isolate layer">
+ <div class="green"></div>
+</div>

Powered by Google App Engine
This is Rietveld 408576698