OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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/renderer/render_widget.h" | 5 #include "content/renderer/render_widget.h" |
6 | 6 |
7 #include <memory> | 7 #include <memory> |
8 #include <utility> | 8 #include <utility> |
9 | 9 |
10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
(...skipping 1127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1138 return false; | 1138 return false; |
1139 } | 1139 } |
1140 | 1140 |
1141 bool RenderWidget::WillHandleMouseEvent(const blink::WebMouseEvent& event) { | 1141 bool RenderWidget::WillHandleMouseEvent(const blink::WebMouseEvent& event) { |
1142 for (auto& observer : render_frames_) | 1142 for (auto& observer : render_frames_) |
1143 observer.RenderWidgetWillHandleMouseEvent(); | 1143 observer.RenderWidgetWillHandleMouseEvent(); |
1144 | 1144 |
1145 possible_drag_event_info_.event_source = | 1145 possible_drag_event_info_.event_source = |
1146 ui::DragDropTypes::DRAG_EVENT_SOURCE_MOUSE; | 1146 ui::DragDropTypes::DRAG_EVENT_SOURCE_MOUSE; |
1147 possible_drag_event_info_.event_location = | 1147 possible_drag_event_info_.event_location = |
1148 gfx::Point(event.globalX, event.globalY); | 1148 gfx::Point(event.positionInScreen().x, event.positionInScreen().y); |
1149 | 1149 |
1150 if (owner_delegate_) | 1150 if (owner_delegate_) |
1151 return owner_delegate_->RenderWidgetWillHandleMouseEvent(event); | 1151 return owner_delegate_->RenderWidgetWillHandleMouseEvent(event); |
1152 | 1152 |
1153 return false; | 1153 return false; |
1154 } | 1154 } |
1155 | 1155 |
1156 /////////////////////////////////////////////////////////////////////////////// | 1156 /////////////////////////////////////////////////////////////////////////////// |
1157 // RenderWidgetScreenMetricsDelegate | 1157 // RenderWidgetScreenMetricsDelegate |
1158 | 1158 |
(...skipping 1157 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2316 // browser side (https://crbug.com/669219). | 2316 // browser side (https://crbug.com/669219). |
2317 // If there is no WebFrameWidget, then there will be no | 2317 // If there is no WebFrameWidget, then there will be no |
2318 // InputMethodControllers for a WebLocalFrame. | 2318 // InputMethodControllers for a WebLocalFrame. |
2319 return nullptr; | 2319 return nullptr; |
2320 } | 2320 } |
2321 return static_cast<blink::WebFrameWidget*>(GetWebWidget()) | 2321 return static_cast<blink::WebFrameWidget*>(GetWebWidget()) |
2322 ->getActiveWebInputMethodController(); | 2322 ->getActiveWebInputMethodController(); |
2323 } | 2323 } |
2324 | 2324 |
2325 } // namespace content | 2325 } // namespace content |
OLD | NEW |