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

Unified Diff: Source/core/layout/HitTestResult.cpp

Issue 1177123003: Revert "Implement a Hit Test Cache for same point hits." (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 6 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/layout/HitTestResult.h ('k') | Source/core/layout/LayoutImage.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/layout/HitTestResult.cpp
diff --git a/Source/core/layout/HitTestResult.cpp b/Source/core/layout/HitTestResult.cpp
index bf556d42e4aa8e5c0eede70f12faeccb885e809e..84e6dc112d581cd23546e2c4f697da907183033d 100644
--- a/Source/core/layout/HitTestResult.cpp
+++ b/Source/core/layout/HitTestResult.cpp
@@ -101,31 +101,6 @@ HitTestResult& HitTestResult::operator=(const HitTestResult& other)
{
m_hitTestLocation = other.m_hitTestLocation;
m_hitTestRequest = other.m_hitTestRequest;
- populateFromCachedResult(other);
-
- return *this;
-}
-
-bool HitTestResult::equalForCacheability(const HitTestResult& other) const
-{
- return m_hitTestRequest.equalForCacheability(other.m_hitTestRequest)
- && m_innerNode == other.innerNode()
- && m_innerPossiblyPseudoNode == other.innerPossiblyPseudoNode()
- && m_pointInInnerNodeFrame == other.m_pointInInnerNodeFrame
- && m_localPoint == other.localPoint()
- && m_innerURLElement == other.URLElement()
- && m_scrollbar == other.scrollbar()
- && m_isOverWidget == other.isOverWidget();
-}
-
-void HitTestResult::cacheValues(const HitTestResult& other)
-{
- *this = other;
- m_hitTestRequest = other.m_hitTestRequest.type() & ~HitTestRequest::AvoidCache;
-}
-
-void HitTestResult::populateFromCachedResult(const HitTestResult& other)
-{
m_innerNode = other.innerNode();
m_innerPossiblyPseudoNode = other.innerPossiblyPseudoNode();
m_pointInInnerNodeFrame = other.m_pointInInnerNodeFrame;
@@ -133,10 +108,11 @@ void HitTestResult::populateFromCachedResult(const HitTestResult& other)
m_innerURLElement = other.URLElement();
m_scrollbar = other.scrollbar();
m_isOverWidget = other.isOverWidget();
- m_validityRect = other.m_validityRect;
// Only copy the NodeSet in case of list hit test.
m_listBasedTestResult = adoptPtrWillBeNoop(other.m_listBasedTestResult ? new NodeSet(*other.m_listBasedTestResult) : 0);
+
+ return *this;
}
DEFINE_TRACE(HitTestResult)
@@ -243,11 +219,6 @@ bool HitTestResult::isSelected() const
return false;
}
-void HitTestResult::setValidityRect(const LayoutRect& rect)
-{
- m_validityRect = rect;
-}
-
String HitTestResult::spellingToolTip(TextDirection& dir) const
{
dir = LTR;
« no previous file with comments | « Source/core/layout/HitTestResult.h ('k') | Source/core/layout/LayoutImage.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698