summaryrefslogtreecommitdiffstats
path: root/ash/wm/window_manager_unittest.cc
diff options
context:
space:
mode:
authorsadrul@chromium.org <sadrul@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-12-18 06:08:18 +0000
committersadrul@chromium.org <sadrul@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2012-12-18 06:08:18 +0000
commitd44efe090c5dd46b2857aaaca9c939dfbb3cba0b (patch)
tree2f80a7dbeaebadad5a0755dc3d8b349d31b390fc /ash/wm/window_manager_unittest.cc
parentefb6409dd196bc229910962753836e9d512905d3 (diff)
downloadchromium_src-d44efe090c5dd46b2857aaaca9c939dfbb3cba0b.zip
chromium_src-d44efe090c5dd46b2857aaaca9c939dfbb3cba0b.tar.gz
chromium_src-d44efe090c5dd46b2857aaaca9c939dfbb3cba0b.tar.bz2
events: Update mouse-event handlers to not return EventResult.
This is the last step. Once this is done, we can possibly hide EventResult. BUG=163618 Review URL: https://codereview.chromium.org/11592011 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@173653 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'ash/wm/window_manager_unittest.cc')
-rw-r--r--ash/wm/window_manager_unittest.cc9
1 files changed, 6 insertions, 3 deletions
diff --git a/ash/wm/window_manager_unittest.cc b/ash/wm/window_manager_unittest.cc
index 773a4a6..2328850 100644
--- a/ash/wm/window_manager_unittest.cc
+++ b/ash/wm/window_manager_unittest.cc
@@ -62,9 +62,12 @@ class CustomEventHandler : public aura::test::TestEventHandler {
event->StopPropagation();
}
- virtual ui::EventResult OnMouseEvent(ui::MouseEvent* event) OVERRIDE {
- ui::EventResult result = aura::test::TestEventHandler::OnMouseEvent(event);
- return mouse_result_ == ui::ER_UNHANDLED ? result : mouse_result_;
+ virtual void OnMouseEvent(ui::MouseEvent* event) OVERRIDE {
+ aura::test::TestEventHandler::OnMouseEvent(event);
+ if (mouse_result_ & ui::ER_HANDLED)
+ event->SetHandled();
+ if (mouse_result_ & ui::ER_CONSUMED)
+ event->StopPropagation();
}
private: