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

Side by Side Diff: content/browser/renderer_host/input/touch_action_browsertest.cc

Issue 1871233002: Move LatencyInfo to ui/latency_info (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix some more gyp issues Created 4 years, 7 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <utility> 5 #include <utility>
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/bind.h" 8 #include "base/bind.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 14 matching lines...) Expand all
25 #include "content/public/browser/render_view_host.h" 25 #include "content/public/browser/render_view_host.h"
26 #include "content/public/browser/render_widget_host_view.h" 26 #include "content/public/browser/render_widget_host_view.h"
27 #include "content/public/common/content_switches.h" 27 #include "content/public/common/content_switches.h"
28 #include "content/public/test/browser_test_utils.h" 28 #include "content/public/test/browser_test_utils.h"
29 #include "content/public/test/content_browser_test.h" 29 #include "content/public/test/content_browser_test.h"
30 #include "content/public/test/content_browser_test_utils.h" 30 #include "content/public/test/content_browser_test_utils.h"
31 #include "content/public/test/test_utils.h" 31 #include "content/public/test/test_utils.h"
32 #include "content/shell/browser/shell.h" 32 #include "content/shell/browser/shell.h"
33 #include "third_party/WebKit/public/web/WebInputEvent.h" 33 #include "third_party/WebKit/public/web/WebInputEvent.h"
34 #include "ui/events/event_switches.h" 34 #include "ui/events/event_switches.h"
35 #include "ui/events/latency_info.h" 35 #include "ui/latency_info/latency_info.h"
36 36
37 using blink::WebInputEvent; 37 using blink::WebInputEvent;
38 38
39 namespace { 39 namespace {
40 40
41 const char kTouchActionDataURL[] = 41 const char kTouchActionDataURL[] =
42 "data:text/html;charset=utf-8," 42 "data:text/html;charset=utf-8,"
43 "<!DOCTYPE html>" 43 "<!DOCTYPE html>"
44 "<meta name='viewport' content='width=device-width'/>" 44 "<meta name='viewport' content='width=device-width'/>"
45 "<style>" 45 "<style>"
(...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after
207 bool scrolled = DoTouchScroll(gfx::Point(50, 150), gfx::Vector2d(0, 45)); 207 bool scrolled = DoTouchScroll(gfx::Point(50, 150), gfx::Vector2d(0, 45));
208 EXPECT_FALSE(scrolled); 208 EXPECT_FALSE(scrolled);
209 209
210 EXPECT_EQ(1, ExecuteScriptAndExtractInt("eventCounts.touchstart")); 210 EXPECT_EQ(1, ExecuteScriptAndExtractInt("eventCounts.touchstart"));
211 EXPECT_GE(ExecuteScriptAndExtractInt("eventCounts.touchmove"), 1); 211 EXPECT_GE(ExecuteScriptAndExtractInt("eventCounts.touchmove"), 1);
212 EXPECT_EQ(1, ExecuteScriptAndExtractInt("eventCounts.touchend")); 212 EXPECT_EQ(1, ExecuteScriptAndExtractInt("eventCounts.touchend"));
213 EXPECT_EQ(0, ExecuteScriptAndExtractInt("eventCounts.touchcancel")); 213 EXPECT_EQ(0, ExecuteScriptAndExtractInt("eventCounts.touchcancel"));
214 } 214 }
215 215
216 } // namespace content 216 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698