| 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 "content/browser/renderer_host/input/touch_emulator.h" | 5 #include "content/browser/renderer_host/input/touch_emulator.h" |
| 6 | 6 |
| 7 #include "content/browser/renderer_host/input/motion_event_web.h" | 7 #include "content/browser/renderer_host/input/motion_event_web.h" |
| 8 #include "content/browser/renderer_host/input/web_input_event_util.h" | 8 #include "content/browser/renderer_host/input/web_input_event_util.h" |
| 9 #include "content/common/input/web_touch_event_traits.h" | 9 #include "content/common/input/web_touch_event_traits.h" |
| 10 #include "content/grit/content_resources.h" | 10 #include "content/grit/content_resources.h" |
| (...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 439 WebTouchPoint& point = touch_event_.touches[0]; | 439 WebTouchPoint& point = touch_event_.touches[0]; |
| 440 point.id = 0; | 440 point.id = 0; |
| 441 point.radiusX = 0.5f * cursor_size_.width(); | 441 point.radiusX = 0.5f * cursor_size_.width(); |
| 442 point.radiusY = 0.5f * cursor_size_.height(); | 442 point.radiusY = 0.5f * cursor_size_.height(); |
| 443 point.force = 1.f; | 443 point.force = 1.f; |
| 444 point.rotationAngle = 0.f; | 444 point.rotationAngle = 0.f; |
| 445 point.position.x = mouse_event.x; | 445 point.position.x = mouse_event.x; |
| 446 point.screenPosition.x = mouse_event.globalX; | 446 point.screenPosition.x = mouse_event.globalX; |
| 447 point.position.y = mouse_event.y; | 447 point.position.y = mouse_event.y; |
| 448 point.screenPosition.y = mouse_event.globalY; | 448 point.screenPosition.y = mouse_event.globalY; |
| 449 point.tiltX = 0; |
| 450 point.tiltY = 0; |
| 449 } | 451 } |
| 450 | 452 |
| 451 bool TouchEmulator::InPinchGestureMode() const { | 453 bool TouchEmulator::InPinchGestureMode() const { |
| 452 return shift_pressed_; | 454 return shift_pressed_; |
| 453 } | 455 } |
| 454 | 456 |
| 455 } // namespace content | 457 } // namespace content |
| OLD | NEW |