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

Unified Diff: Source/core/css/HoverUpdateTest.cpp

Issue 220943002: Use invalidation sets for :hover, :active, and :focus. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Remove unnecessary seenCombinator handling. Created 6 years, 8 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 | « Source/core/css/AffectedByFocusTest.cpp ('k') | Source/core/css/RuleFeature.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/css/HoverUpdateTest.cpp
diff --git a/Source/core/css/HoverUpdateTest.cpp b/Source/core/css/HoverUpdateTest.cpp
deleted file mode 100644
index ac60a2e5b78b41da70b1fc009cea7270d78c0d46..0000000000000000000000000000000000000000
--- a/Source/core/css/HoverUpdateTest.cpp
+++ /dev/null
@@ -1,49 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "config.h"
-#include "HTMLNames.h"
-#include "core/dom/Element.h"
-#include "core/dom/ElementTraversal.h"
-#include "core/frame/FrameView.h"
-#include "core/frame/LocalFrame.h"
-#include "core/html/HTMLDocument.h"
-#include "core/html/HTMLElement.h"
-#include "core/page/EventHandler.h"
-#include "core/testing/DummyPageHolder.h"
-#include "platform/PlatformMouseEvent.h"
-#include <gtest/gtest.h>
-
-using namespace WebCore;
-
-namespace {
-
-TEST(HoverUpdateTest, AffectedByHoverUpdate)
-{
- // Check that when hovering the div in the document below, you only get a
- // single element style recalc.
-
- OwnPtr<DummyPageHolder> dummyPageHolder = DummyPageHolder::create(IntSize(800, 600));
- HTMLDocument* document = toHTMLDocument(&dummyPageHolder->document());
- document->documentElement()->setInnerHTML("<style>div {width:100px;height:100px} div:hover { background-color: green }</style>"
- "<div>"
- "<span></span>"
- "<span></span>"
- "<span></span>"
- "<span></span>"
- "</div>", ASSERT_NO_EXCEPTION);
-
- document->view()->updateLayoutAndStyleIfNeededRecursive();
- unsigned startCount = document->styleEngine()->resolverAccessCount();
-
- PlatformMouseEvent moveEvent(IntPoint(20, 20), IntPoint(20, 20), NoButton, PlatformEvent::MouseMoved, 0, false, false, false, false, currentTime());
- document->frame()->eventHandler().handleMouseMoveEvent(moveEvent);
- document->view()->updateLayoutAndStyleIfNeededRecursive();
-
- unsigned accessCount = document->styleEngine()->resolverAccessCount() - startCount;
-
- ASSERT_EQ(1U, accessCount);
-}
-
-} // namespace
« no previous file with comments | « Source/core/css/AffectedByFocusTest.cpp ('k') | Source/core/css/RuleFeature.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698