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

Unified Diff: ui/chromeos/touch_exploration_controller.cc

Issue 1975533002: Change ui::Event::time_stamp from TimeDelta to TimeTicks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 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 | « ui/chromeos/touch_exploration_controller.h ('k') | ui/chromeos/touch_exploration_controller_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/chromeos/touch_exploration_controller.cc
diff --git a/ui/chromeos/touch_exploration_controller.cc b/ui/chromeos/touch_exploration_controller.cc
index a2676adbdfcd3da793d786957d3c48cfe17ef8a9..edea02094c5f9919fb3c3f79ec38406c48743f62 100644
--- a/ui/chromeos/touch_exploration_controller.cc
+++ b/ui/chromeos/touch_exploration_controller.cc
@@ -693,12 +693,11 @@ ui::EventRewriteStatus TouchExplorationController::InTwoFingerTap(
return ui::EVENT_REWRITE_DISCARD;
}
-base::TimeDelta TouchExplorationController::Now() {
+base::TimeTicks TouchExplorationController::Now() {
if (tick_clock_) {
// This is the same as what EventTimeForNow() does, but here we do it
// with a clock that can be replaced with a simulated clock for tests.
- return base::TimeDelta::FromInternalValue(
- tick_clock_->NowTicks().ToInternalValue());
+ return tick_clock_->NowTicks();
}
return ui::EventTimeForNow();
}
@@ -1027,9 +1026,8 @@ TouchExplorationController::CreateMouseMoveEvent(const gfx::PointF& location,
// event to the new ChromeVox background page via the automation api.
flags |= ui::EF_COMMAND_DOWN;
- std::unique_ptr<ui::MouseEvent> event(
- new ui::MouseEvent(ui::ET_MOUSE_MOVED, gfx::Point(), gfx::Point(),
- ui::EventTimeForNow(), flags, 0));
+ std::unique_ptr<ui::MouseEvent> event(new ui::MouseEvent(
+ ui::ET_MOUSE_MOVED, gfx::Point(), gfx::Point(), Now(), flags, 0));
event->set_location_f(location);
event->set_root_location_f(location);
return event;
« no previous file with comments | « ui/chromeos/touch_exploration_controller.h ('k') | ui/chromeos/touch_exploration_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698