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/frame_host/render_widget_host_view_child_frame.h" | 5 #include "content/browser/frame_host/render_widget_host_view_child_frame.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
374 const blink::WebMouseEvent& event) { | 374 const blink::WebMouseEvent& event) { |
375 host_->ForwardMouseEvent(event); | 375 host_->ForwardMouseEvent(event); |
376 } | 376 } |
377 | 377 |
378 void RenderWidgetHostViewChildFrame::ProcessMouseWheelEvent( | 378 void RenderWidgetHostViewChildFrame::ProcessMouseWheelEvent( |
379 const blink::WebMouseWheelEvent& event) { | 379 const blink::WebMouseWheelEvent& event) { |
380 if (event.deltaX != 0 || event.deltaY != 0) | 380 if (event.deltaX != 0 || event.deltaY != 0) |
381 host_->ForwardWheelEvent(event); | 381 host_->ForwardWheelEvent(event); |
382 } | 382 } |
383 | 383 |
384 void RenderWidgetHostViewChildFrame::TransformPointToRootCoordSpace( | 384 gfx::Point RenderWidgetHostViewChildFrame::TransformPointToRootCoordSpace( |
385 const gfx::Point& point, | 385 const gfx::Point& point) { |
386 gfx::Point* transformed_point) { | |
387 *transformed_point = point; | |
388 if (!frame_connector_ || !use_surfaces_) | 386 if (!frame_connector_ || !use_surfaces_) |
389 return; | 387 return point; |
390 | 388 |
391 frame_connector_->TransformPointToRootCoordSpace(point, surface_id_, | 389 return frame_connector_->TransformPointToRootCoordSpace(point, surface_id_); |
392 transformed_point); | |
393 } | 390 } |
394 | 391 |
395 #if defined(OS_MACOSX) | 392 #if defined(OS_MACOSX) |
396 void RenderWidgetHostViewChildFrame::SetActive(bool active) { | 393 void RenderWidgetHostViewChildFrame::SetActive(bool active) { |
397 } | 394 } |
398 | 395 |
399 void RenderWidgetHostViewChildFrame::SetWindowVisibility(bool visible) { | 396 void RenderWidgetHostViewChildFrame::SetWindowVisibility(bool visible) { |
400 } | 397 } |
401 | 398 |
402 void RenderWidgetHostViewChildFrame::WindowFrameChanged() { | 399 void RenderWidgetHostViewChildFrame::WindowFrameChanged() { |
(...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
497 #endif | 494 #endif |
498 } | 495 } |
499 | 496 |
500 void RenderWidgetHostViewChildFrame::ClearCompositorSurfaceIfNecessary() { | 497 void RenderWidgetHostViewChildFrame::ClearCompositorSurfaceIfNecessary() { |
501 if (surface_factory_ && !surface_id_.is_null()) | 498 if (surface_factory_ && !surface_id_.is_null()) |
502 surface_factory_->Destroy(surface_id_); | 499 surface_factory_->Destroy(surface_id_); |
503 surface_id_ = cc::SurfaceId(); | 500 surface_id_ = cc::SurfaceId(); |
504 } | 501 } |
505 | 502 |
506 } // namespace content | 503 } // namespace content |
OLD | NEW |