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

Unified Diff: Source/core/rendering/RenderView.h

Issue 354613002: Add test to track the number of hit tests on various events (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Merge with trunk Created 6 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
Index: Source/core/rendering/RenderView.h
diff --git a/Source/core/rendering/RenderView.h b/Source/core/rendering/RenderView.h
index 682cba953db46c8f52c66b16b024fa44c473633b..30062e3e49f5ad9a843a2a41cd47807cc5f71073 100644
--- a/Source/core/rendering/RenderView.h
+++ b/Source/core/rendering/RenderView.h
@@ -47,6 +47,10 @@ public:
bool hitTest(const HitTestRequest&, HitTestResult&);
bool hitTest(const HitTestRequest&, const HitTestLocation&, HitTestResult&);
+ // Returns the count of calls to HitTest since this was last called.
+ // Used by tests that catch unnecessary hit-tests.
+ unsigned hitTestCountDelta();
+
virtual const char* renderName() const OVERRIDE { return "RenderView"; }
virtual bool isRenderView() const OVERRIDE { return true; }
@@ -203,6 +207,8 @@ private:
RenderQuote* m_renderQuoteHead;
unsigned m_renderCounterCount;
+
+ unsigned m_hitTestCount;
};
DEFINE_RENDER_OBJECT_TYPE_CASTS(RenderView, isRenderView());

Powered by Google App Engine
This is Rietveld 408576698