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

Unified Diff: ash/drag_drop/drag_drop_controller_unittest.cc

Issue 11591006: Track input latency with UMA stats (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Added per event type histograms Created 7 years, 11 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 | « ash/drag_drop/drag_drop_controller.cc ('k') | ash/wm/custom_frame_view_ash_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/drag_drop/drag_drop_controller_unittest.cc
diff --git a/ash/drag_drop/drag_drop_controller_unittest.cc b/ash/drag_drop/drag_drop_controller_unittest.cc
index 2af290542c278ea1e517bfc70174540c420e22a2..f52893a5414f6f3999b52fd2ed275ee096619387 100644
--- a/ash/drag_drop/drag_drop_controller_unittest.cc
+++ b/ash/drag_drop/drag_drop_controller_unittest.cc
@@ -19,6 +19,7 @@
#include "ui/base/dragdrop/drag_utils.h"
#include "ui/base/dragdrop/os_exchange_data.h"
#include "ui/base/events/event.h"
+#include "ui/base/events/event_utils.h"
#include "ui/base/gestures/gesture_types.h"
#include "ui/base/ui_base_switches.h"
#include "ui/gfx/image/image_skia_rep.h"
@@ -266,9 +267,14 @@ void AddViewToWidgetAndResize(views::Widget* widget, views::View* view) {
}
void DispatchGesture(ui::EventType gesture_type, gfx::Point location) {
- ui::GestureEvent gesture_event(gesture_type, location.x(), location.y(), 0,
- base::Time::NowFromSystemTime() - base::Time(),
- ui::GestureEventDetails(gesture_type, 0, 0), 1);
+ ui::GestureEvent gesture_event(
+ gesture_type,
+ location.x(),
+ location.y(),
+ 0,
+ ui::EventTimeForNow(),
+ ui::GestureEventDetails(gesture_type, 0, 0),
+ 1);
Shell::GetPrimaryRootWindow()->DispatchGestureEvent(&gesture_event);
}
« no previous file with comments | « ash/drag_drop/drag_drop_controller.cc ('k') | ash/wm/custom_frame_view_ash_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698