| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_CHROMEOS_DEVICE_UMA_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_DEVICE_UMA_H_ |
| 6 #define CHROME_BROWSER_CHROMEOS_DEVICE_UMA_H_ | 6 #define CHROME_BROWSER_CHROMEOS_DEVICE_UMA_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/event_types.h" | 9 #include "base/event_types.h" |
| 10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
| (...skipping 15 matching lines...) Expand all Loading... |
| 26 friend struct DefaultSingletonTraits<DeviceUMA>; | 26 friend struct DefaultSingletonTraits<DeviceUMA>; |
| 27 | 27 |
| 28 DeviceUMA(); | 28 DeviceUMA(); |
| 29 virtual ~DeviceUMA(); | 29 virtual ~DeviceUMA(); |
| 30 | 30 |
| 31 // Start and stop observing events. | 31 // Start and stop observing events. |
| 32 void AddMessageLoopObserver(); | 32 void AddMessageLoopObserver(); |
| 33 void RemoveMessageLoopObserver(); | 33 void RemoveMessageLoopObserver(); |
| 34 | 34 |
| 35 // MessageLoopForUI::Observer overrides. | 35 // MessageLoopForUI::Observer overrides. |
| 36 virtual base::EventStatus WillProcessEvent( | 36 virtual void WillProcessEvent(const base::NativeEvent& event) OVERRIDE; |
| 37 const base::NativeEvent& event) OVERRIDE; | |
| 38 virtual void DidProcessEvent(const base::NativeEvent& event) OVERRIDE; | 37 virtual void DidProcessEvent(const base::NativeEvent& event) OVERRIDE; |
| 39 | 38 |
| 40 // Check CrOS touchpad events to see if the metrics gesture is present | 39 // Check CrOS touchpad events to see if the metrics gesture is present |
| 41 void CheckTouchpadEvent(const base::NativeEvent& event); | 40 void CheckTouchpadEvent(const base::NativeEvent& event); |
| 42 | 41 |
| 43 // Check the incoming events for interesting patterns that we care about. | 42 // Check the incoming events for interesting patterns that we care about. |
| 44 void CheckIncomingEvent(const base::NativeEvent& event); | 43 void CheckIncomingEvent(const base::NativeEvent& event); |
| 45 | 44 |
| 46 bool is_observing_; | 45 bool is_observing_; |
| 47 | 46 |
| 48 DISALLOW_COPY_AND_ASSIGN(DeviceUMA); | 47 DISALLOW_COPY_AND_ASSIGN(DeviceUMA); |
| 49 }; | 48 }; |
| 50 | 49 |
| 51 } // namespace chromeos | 50 } // namespace chromeos |
| 52 | 51 |
| 53 #endif // CHROME_BROWSER_CHROMEOS_DEVICE_UMA_H_ | 52 #endif // CHROME_BROWSER_CHROMEOS_DEVICE_UMA_H_ |
| OLD | NEW |