| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #include "ui/events/gesture_detection/gesture_touch_uma_histogram.h" | 5 #include "ui/events/gesture_detection/gesture_touch_uma_histogram.h" |
| 6 | 6 |
| 7 #include "base/metrics/histogram.h" | 7 #include "base/metrics/histogram.h" |
| 8 | 8 |
| 9 namespace ui { | 9 namespace ui { |
| 10 | 10 |
| (...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 112 case ET_GESTURE_SWIPE: { | 112 case ET_GESTURE_SWIPE: { |
| 113 int touch_points = gesture.details.touch_points(); | 113 int touch_points = gesture.details.touch_points(); |
| 114 if (touch_points == 1) | 114 if (touch_points == 1) |
| 115 return UMA_ET_GESTURE_SWIPE_1; | 115 return UMA_ET_GESTURE_SWIPE_1; |
| 116 else if (touch_points == 2) | 116 else if (touch_points == 2) |
| 117 return UMA_ET_GESTURE_SWIPE_2; | 117 return UMA_ET_GESTURE_SWIPE_2; |
| 118 else if (touch_points == 3) | 118 else if (touch_points == 3) |
| 119 return UMA_ET_GESTURE_SWIPE_3; | 119 return UMA_ET_GESTURE_SWIPE_3; |
| 120 return UMA_ET_GESTURE_SWIPE_4P; | 120 return UMA_ET_GESTURE_SWIPE_4P; |
| 121 } | 121 } |
| 122 case ET_GESTURE_WIN8_EDGE_SWIPE: | |
| 123 return UMA_ET_GESTURE_WIN8_EDGE_SWIPE; | |
| 124 case ET_GESTURE_TAP_CANCEL: | 122 case ET_GESTURE_TAP_CANCEL: |
| 125 return UMA_ET_GESTURE_TAP_CANCEL; | 123 return UMA_ET_GESTURE_TAP_CANCEL; |
| 126 case ET_GESTURE_SHOW_PRESS: | 124 case ET_GESTURE_SHOW_PRESS: |
| 127 return UMA_ET_GESTURE_SHOW_PRESS; | 125 return UMA_ET_GESTURE_SHOW_PRESS; |
| 128 case ET_SCROLL: | 126 case ET_SCROLL: |
| 129 return UMA_ET_SCROLL; | 127 return UMA_ET_SCROLL; |
| 130 case ET_SCROLL_FLING_START: | 128 case ET_SCROLL_FLING_START: |
| 131 return UMA_ET_SCROLL_FLING_START; | 129 return UMA_ET_SCROLL_FLING_START; |
| 132 case ET_SCROLL_FLING_CANCEL: | 130 case ET_SCROLL_FLING_CANCEL: |
| 133 return UMA_ET_SCROLL_FLING_CANCEL; | 131 return UMA_ET_SCROLL_FLING_CANCEL; |
| 134 case ET_GESTURE_TAP_UNCONFIRMED: | 132 case ET_GESTURE_TAP_UNCONFIRMED: |
| 135 return UMA_ET_GESTURE_TAP_UNCONFIRMED; | 133 return UMA_ET_GESTURE_TAP_UNCONFIRMED; |
| 136 case ET_GESTURE_DOUBLE_TAP: | 134 case ET_GESTURE_DOUBLE_TAP: |
| 137 return UMA_ET_GESTURE_DOUBLE_TAP; | 135 return UMA_ET_GESTURE_DOUBLE_TAP; |
| 138 default: | 136 default: |
| 139 NOTREACHED(); | 137 NOTREACHED(); |
| 140 return UMA_ET_UNKNOWN; | 138 return UMA_ET_UNKNOWN; |
| 141 } | 139 } |
| 142 } | 140 } |
| 143 | 141 |
| 144 } // namespace ui | 142 } // namespace ui |
| OLD | NEW |