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

Unified Diff: ash/wm/user_activity_detector_unittest.cc

Issue 11592011: events: Update mouse-event handlers to not return EventResult. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years 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/wm/user_activity_detector.cc ('k') | ash/wm/window_manager_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/user_activity_detector_unittest.cc
diff --git a/ash/wm/user_activity_detector_unittest.cc b/ash/wm/user_activity_detector_unittest.cc
index 979c9eaab306684fe603f1bf4f8957fd21b1f5e0..e0108d44c720524274b672c5f2911c3a393594fc 100644
--- a/ash/wm/user_activity_detector_unittest.cc
+++ b/ash/wm/user_activity_detector_unittest.cc
@@ -103,14 +103,16 @@ TEST_F(UserActivityDetectorTest, Basic) {
ui::MouseEvent mouse_event(
ui::ET_MOUSE_MOVED, gfx::Point(), gfx::Point(), ui::EF_NONE);
SetEventTarget(window.get(), &mouse_event);
- EXPECT_FALSE(detector_->OnMouseEvent(&mouse_event));
+ detector_->OnMouseEvent(&mouse_event);
+ EXPECT_FALSE(mouse_event.handled());
EXPECT_EQ(1, observer_->num_invocations());
observer_->reset_stats();
// Ignore one mouse event when all displays are turned off.
detector_->OnAllOutputsTurnedOff();
AdvanceTime(advance_delta);
- EXPECT_EQ(ui::ER_UNHANDLED, detector_->OnMouseEvent(&mouse_event));
+ detector_->OnMouseEvent(&mouse_event);
+ EXPECT_FALSE(mouse_event.handled());
EXPECT_EQ(0, observer_->num_invocations());
observer_->reset_stats();
@@ -179,7 +181,8 @@ TEST_F(UserActivityDetectorTest, IgnoreSyntheticMouseEvents) {
ui::MouseEvent mouse_event(
ui::ET_MOUSE_MOVED, gfx::Point(), gfx::Point(), ui::EF_IS_SYNTHESIZED);
SetEventTarget(window.get(), &mouse_event);
- EXPECT_EQ(ui::ER_UNHANDLED, detector_->OnMouseEvent(&mouse_event));
+ detector_->OnMouseEvent(&mouse_event);
+ EXPECT_FALSE(mouse_event.handled());
EXPECT_EQ(0, observer_->num_invocations());
}
« no previous file with comments | « ash/wm/user_activity_detector.cc ('k') | ash/wm/window_manager_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698