| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 "views/events/event.h" | 5 #include "views/events/event.h" |
| 6 | 6 |
| 7 #include "views/view.h" | 7 #include "views/view.h" |
| 8 #include "views/widget/root_view.h" | 8 #include "views/widget/root_view.h" |
| 9 | 9 |
| 10 namespace views { | 10 namespace views { |
| (...skipping 167 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 178 | 178 |
| 179 //////////////////////////////////////////////////////////////////////////////// | 179 //////////////////////////////////////////////////////////////////////////////// |
| 180 // TouchEvent, public: | 180 // TouchEvent, public: |
| 181 | 181 |
| 182 #if defined(TOUCH_UI) | 182 #if defined(TOUCH_UI) |
| 183 TouchEvent::TouchEvent(ui::EventType type, | 183 TouchEvent::TouchEvent(ui::EventType type, |
| 184 int x, | 184 int x, |
| 185 int y, | 185 int y, |
| 186 int flags, | 186 int flags, |
| 187 int touch_id, | 187 int touch_id, |
| 188 float radius, | 188 float radius_x, |
| 189 float angle, | 189 float radius_y, |
| 190 float ratio) | 190 float angle) |
| 191 : LocatedEvent(type, gfx::Point(x, y), flags), | 191 : LocatedEvent(type, gfx::Point(x, y), flags), |
| 192 touch_id_(touch_id), | 192 touch_id_(touch_id), |
| 193 radius_(radius), | 193 radius_x_(radius_x), |
| 194 angle_(angle), | 194 radius_y_(radius_y), |
| 195 ratio_(ratio) { | 195 angle_(angle) { |
| 196 } | 196 } |
| 197 | 197 |
| 198 TouchEvent::TouchEvent(const TouchEvent& model, View* source, View* target) | 198 TouchEvent::TouchEvent(const TouchEvent& model, View* source, View* target) |
| 199 : LocatedEvent(model, source, target), | 199 : LocatedEvent(model, source, target), |
| 200 touch_id_(model.touch_id_), | 200 touch_id_(model.touch_id_), |
| 201 radius_(model.radius_), | 201 radius_x_(model.radius_x_), |
| 202 angle_(model.angle_), | 202 radius_y_(model.radius_y_), |
| 203 ratio_(model.ratio_) { | 203 angle_(model.angle_) { |
| 204 } | 204 } |
| 205 | 205 |
| 206 //////////////////////////////////////////////////////////////////////////////// | 206 //////////////////////////////////////////////////////////////////////////////// |
| 207 // TouchEvent, private: | 207 // TouchEvent, private: |
| 208 | 208 |
| 209 TouchEvent::TouchEvent(const TouchEvent& model, View* root) | 209 TouchEvent::TouchEvent(const TouchEvent& model, View* root) |
| 210 : LocatedEvent(model, root), | 210 : LocatedEvent(model, root), |
| 211 touch_id_(model.touch_id_), | 211 touch_id_(model.touch_id_), |
| 212 radius_(model.radius_), | 212 radius_x_(model.radius_x_), |
| 213 angle_(model.angle_), | 213 radius_y_(model.radius_y_), |
| 214 ratio_(model.ratio_) { | 214 angle_(model.angle_) { |
| 215 } | 215 } |
| 216 #endif | 216 #endif |
| 217 | 217 |
| 218 //////////////////////////////////////////////////////////////////////////////// | 218 //////////////////////////////////////////////////////////////////////////////// |
| 219 // MouseWheelEvent, public: | 219 // MouseWheelEvent, public: |
| 220 | 220 |
| 221 // This value matches windows WHEEL_DELTA. | 221 // This value matches windows WHEEL_DELTA. |
| 222 // static | 222 // static |
| 223 const int MouseWheelEvent::kWheelDelta = 120; | 223 const int MouseWheelEvent::kWheelDelta = 120; |
| 224 | 224 |
| 225 } // namespace views | 225 } // namespace views |
| OLD | NEW |