Unduplicate GetHitTestQuery helper method.

Quickfix to resolve some jumbo build problems after a duplicate
instance of the GetHitTestQuery function was added.

Change-Id: I924ff8254e59d00a92170d09664c20328209103a
Reviewed-on: https://chromium-review.googlesource.com/c/1256688
Commit-Queue: Daniel Bratell <bratell@opera.com>
Reviewed-by: Sadrul Chowdhury <sadrul@chromium.org>
Cr-Commit-Position: refs/heads/master@{#599628}
diff --git a/content/browser/renderer_host/hit_test_debug_key_event_observer.cc b/content/browser/renderer_host/hit_test_debug_key_event_observer.cc
index ee542014..7cbb9c1 100644
--- a/content/browser/renderer_host/hit_test_debug_key_event_observer.cc
+++ b/content/browser/renderer_host/hit_test_debug_key_event_observer.cc
@@ -8,29 +8,13 @@
 #include "components/viz/host/host_frame_sink_manager.h"
 #include "content/browser/compositor/surface_utils.h"
 #include "content/browser/renderer_host/render_widget_host_impl.h"
+#include "content/browser/renderer_host/render_widget_host_input_event_router.h"
 #include "content/browser/renderer_host/render_widget_host_view_base.h"
 #include "ui/events/keycodes/keyboard_codes.h"
 
 typedef blink::WebInputEvent::Type Type;
 typedef blink::WebInputEvent::Modifiers Modifiers;
 
-namespace {
-
-viz::HitTestQuery* GetHitTestQuery(
-    viz::HostFrameSinkManager* host_frame_sink_manager,
-    const viz::FrameSinkId& frame_sink_id) {
-  if (!frame_sink_id.is_valid())
-    return nullptr;
-  const auto& display_hit_test_query_map =
-      host_frame_sink_manager->display_hit_test_query();
-  const auto iter = display_hit_test_query_map.find(frame_sink_id);
-  if (iter == display_hit_test_query_map.end())
-    return nullptr;
-  return iter->second.get();
-}
-
-}  // namespace
-
 namespace content {
 
 HitTestDebugKeyEventObserver::HitTestDebugKeyEventObserver(
diff --git a/content/browser/renderer_host/render_widget_host_input_event_router.cc b/content/browser/renderer_host/render_widget_host_input_event_router.cc
index db3a1e9..b5e4b7b 100644
--- a/content/browser/renderer_host/render_widget_host_input_event_router.cc
+++ b/content/browser/renderer_host/render_widget_host_input_event_router.cc
@@ -47,19 +47,6 @@
                                 blink::WebInputEvent::kNoModifiers, time_stamp);
 }
 
-viz::HitTestQuery* GetHitTestQuery(
-    viz::HostFrameSinkManager* host_frame_sink_manager,
-    const viz::FrameSinkId& frame_sink_id) {
-  if (!frame_sink_id.is_valid())
-    return nullptr;
-  const auto& display_hit_test_query_map =
-      host_frame_sink_manager->display_hit_test_query();
-  const auto iter = display_hit_test_query_map.find(frame_sink_id);
-  if (iter == display_hit_test_query_map.end())
-    return nullptr;
-  return iter->second.get();
-}
-
 gfx::PointF ComputePointInRootInPixels(
     const gfx::PointF& point,
     content::RenderWidgetHostViewBase* root_view,
@@ -84,6 +71,20 @@
 
 namespace content {
 
+// Helper method also used from hit_test_debug_key_event_observer.cc
+viz::HitTestQuery* GetHitTestQuery(
+    viz::HostFrameSinkManager* host_frame_sink_manager,
+    const viz::FrameSinkId& frame_sink_id) {
+  if (!frame_sink_id.is_valid())
+    return nullptr;
+  const auto& display_hit_test_query_map =
+      host_frame_sink_manager->display_hit_test_query();
+  const auto iter = display_hit_test_query_map.find(frame_sink_id);
+  if (iter == display_hit_test_query_map.end())
+    return nullptr;
+  return iter->second.get();
+}
+
 // A class to implement a queue for tracking outbound TouchEvents, and making
 // sure that their acks are returned to the appropriate root view in order.
 // This is important to ensure proper operation of the GestureProvider.
diff --git a/content/browser/renderer_host/render_widget_host_input_event_router.h b/content/browser/renderer_host/render_widget_host_input_event_router.h
index a453fcb..2506c3c 100644
--- a/content/browser/renderer_host/render_widget_host_input_event_router.h
+++ b/content/browser/renderer_host/render_widget_host_input_event_router.h
@@ -46,6 +46,10 @@
 class LatencyInfo;
 }
 
+namespace viz {
+class HostFrameSinkManager;
+}
+
 namespace content {
 
 class RenderWidgetHostImpl;
@@ -55,6 +59,11 @@
 class TouchEmulator;
 class TouchEventAckQueue;
 
+// Helper method also used from hit_test_debug_key_event_observer.cc
+viz::HitTestQuery* GetHitTestQuery(
+    viz::HostFrameSinkManager* host_frame_sink_manager,
+    const viz::FrameSinkId& frame_sink_id);
+
 // Class owned by WebContentsImpl for the purpose of directing input events
 // to the correct RenderWidgetHost on pages with multiple RenderWidgetHosts.
 // It maintains a mapping of RenderWidgetHostViews to Surface IDs that they