Chromium Code Reviews| Index: ash/wm/system_gesture_event_filter.cc |
| diff --git a/ash/wm/system_gesture_event_filter.cc b/ash/wm/system_gesture_event_filter.cc |
| index 34ee6e442e9e991c451d46680a583563a8782f15..15fa798b7f128524c1db36b0c456a471ddc382dc 100644 |
| --- a/ash/wm/system_gesture_event_filter.cc |
| +++ b/ash/wm/system_gesture_event_filter.cc |
| @@ -10,6 +10,7 @@ |
| #include "ash/root_window_controller.h" |
| #include "ash/screen_ash.h" |
| #include "ash/shell.h" |
| +#include "ash/shell_delegate.h" |
| #include "ash/shell_window_ids.h" |
| #include "ash/system/brightness/brightness_control_delegate.h" |
| #include "ash/volume_control_delegate.h" |
| @@ -38,6 +39,10 @@ |
| #include "ui/views/widget/widget.h" |
| #include "ui/views/widget/widget_delegate.h" |
| +#if defined(OS_CHROMEOS) |
| +#include "ui/base/touch/touch_factory.h" |
| +#endif |
| + |
| namespace { |
| using views::Widget; |
| @@ -527,6 +532,14 @@ bool SystemGestureEventFilter::PreHandleKeyEvent(aura::Window* target, |
| bool SystemGestureEventFilter::PreHandleMouseEvent(aura::Window* target, |
| aura::MouseEvent* event) { |
| +#if defined(OS_CHROMEOS) |
| + if (event->type() == ui::ET_MOUSE_PRESSED && event->native_event() && |
| + ui::TouchFactory::GetInstance()->IsTouchDevicePresent() && |
| + ui::IsTouchpadEvent(event->native_event())) { |
|
Rick Byers
2012/07/31 20:37:36
I don't think we need to restrict ourselves to tou
sadrul
2012/08/01 16:15:27
Done (using just MOUSE_DOWN for both mouse/touchpa
|
| + Shell::GetInstance()->delegate()->RecordUserMetricsAction( |
| + UMA_TOUCHPAD_TAP_DOWN); |
| + } |
| +#endif |
| return false; |
| } |