| 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/browser/renderer_host/render_widget_host_view_aura.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_aura.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
| (...skipping 1581 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1592 // |point| from DIPs to pixels before hittesting. | 1592 // |point| from DIPs to pixels before hittesting. |
| 1593 gfx::Point point_in_pixels = | 1593 gfx::Point point_in_pixels = |
| 1594 gfx::ConvertPointToPixel(device_scale_factor_, point); | 1594 gfx::ConvertPointToPixel(device_scale_factor_, point); |
| 1595 cc::SurfaceId id = delegated_frame_host_->SurfaceIdAtPoint( | 1595 cc::SurfaceId id = delegated_frame_host_->SurfaceIdAtPoint( |
| 1596 delegate, point_in_pixels, transformed_point); | 1596 delegate, point_in_pixels, transformed_point); |
| 1597 *transformed_point = | 1597 *transformed_point = |
| 1598 gfx::ConvertPointToDIP(device_scale_factor_, *transformed_point); | 1598 gfx::ConvertPointToDIP(device_scale_factor_, *transformed_point); |
| 1599 | 1599 |
| 1600 // It is possible that the renderer has not yet produced a surface, in which | 1600 // It is possible that the renderer has not yet produced a surface, in which |
| 1601 // case we return our current namespace. | 1601 // case we return our current namespace. |
| 1602 if (id.is_null()) | 1602 if (!id.is_valid()) |
| 1603 return GetFrameSinkId(); | 1603 return GetFrameSinkId(); |
| 1604 return id.frame_sink_id(); | 1604 return id.frame_sink_id(); |
| 1605 } | 1605 } |
| 1606 | 1606 |
| 1607 void RenderWidgetHostViewAura::ProcessMouseEvent( | 1607 void RenderWidgetHostViewAura::ProcessMouseEvent( |
| 1608 const blink::WebMouseEvent& event, | 1608 const blink::WebMouseEvent& event, |
| 1609 const ui::LatencyInfo& latency) { | 1609 const ui::LatencyInfo& latency) { |
| 1610 host_->ForwardMouseEventWithLatencyInfo(event, latency); | 1610 host_->ForwardMouseEventWithLatencyInfo(event, latency); |
| 1611 } | 1611 } |
| 1612 | 1612 |
| (...skipping 766 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2379 | 2379 |
| 2380 void RenderWidgetHostViewAura::SetPopupChild( | 2380 void RenderWidgetHostViewAura::SetPopupChild( |
| 2381 RenderWidgetHostViewAura* popup_child_host_view) { | 2381 RenderWidgetHostViewAura* popup_child_host_view) { |
| 2382 popup_child_host_view_ = popup_child_host_view; | 2382 popup_child_host_view_ = popup_child_host_view; |
| 2383 event_handler_->SetPopupChild( | 2383 event_handler_->SetPopupChild( |
| 2384 popup_child_host_view, | 2384 popup_child_host_view, |
| 2385 popup_child_host_view ? popup_child_host_view->event_handler() : nullptr); | 2385 popup_child_host_view ? popup_child_host_view->event_handler() : nullptr); |
| 2386 } | 2386 } |
| 2387 | 2387 |
| 2388 } // namespace content | 2388 } // namespace content |
| OLD | NEW |