Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(214)

Side by Side Diff: content/browser/frame_host/render_widget_host_view_child_frame.cc

Issue 1980133002: Implement pointer lock API for out-of-process iframes. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: removing one more override Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 438 matching lines...) Expand 10 before | Expand all | Expand 10 after
449 void RenderWidgetHostViewChildFrame::ProcessAckedTouchEvent( 449 void RenderWidgetHostViewChildFrame::ProcessAckedTouchEvent(
450 const TouchEventWithLatencyInfo& touch, 450 const TouchEventWithLatencyInfo& touch,
451 InputEventAckState ack_result) { 451 InputEventAckState ack_result) {
452 if (!frame_connector_) 452 if (!frame_connector_)
453 return; 453 return;
454 454
455 frame_connector_->ForwardProcessAckedTouchEvent(touch, ack_result); 455 frame_connector_->ForwardProcessAckedTouchEvent(touch, ack_result);
456 } 456 }
457 457
458 bool RenderWidgetHostViewChildFrame::LockMouse() { 458 bool RenderWidgetHostViewChildFrame::LockMouse() {
459 if (frame_connector_)
460 return frame_connector_->LockMouse();
459 return false; 461 return false;
460 } 462 }
461 463
462 void RenderWidgetHostViewChildFrame::UnlockMouse() { 464 void RenderWidgetHostViewChildFrame::UnlockMouse() {
463 } 465 }
464 466
467 bool RenderWidgetHostViewChildFrame::IsMouseLocked() {
468 if (frame_connector_) {
469 RenderWidgetHostViewBase* root_view =
470 frame_connector_->GetRootRenderWidgetHostView();
471
472 if (root_view)
473 return root_view->IsMouseLocked();
474 }
475
476 return false;
477 }
478
465 uint32_t RenderWidgetHostViewChildFrame::GetSurfaceIdNamespace() { 479 uint32_t RenderWidgetHostViewChildFrame::GetSurfaceIdNamespace() {
466 return id_allocator_->id_namespace(); 480 return id_allocator_->id_namespace();
467 } 481 }
468 482
469 void RenderWidgetHostViewChildFrame::ProcessKeyboardEvent( 483 void RenderWidgetHostViewChildFrame::ProcessKeyboardEvent(
470 const NativeWebKeyboardEvent& event) { 484 const NativeWebKeyboardEvent& event) {
471 host_->ForwardKeyboardEvent(event); 485 host_->ForwardKeyboardEvent(event);
472 } 486 }
473 487
474 void RenderWidgetHostViewChildFrame::ProcessMouseEvent( 488 void RenderWidgetHostViewChildFrame::ProcessMouseEvent(
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
664 678
665 bool RenderWidgetHostViewChildFrame::IsChildFrameForTesting() const { 679 bool RenderWidgetHostViewChildFrame::IsChildFrameForTesting() const {
666 return true; 680 return true;
667 } 681 }
668 682
669 cc::SurfaceId RenderWidgetHostViewChildFrame::SurfaceIdForTesting() const { 683 cc::SurfaceId RenderWidgetHostViewChildFrame::SurfaceIdForTesting() const {
670 return surface_id_; 684 return surface_id_;
671 }; 685 };
672 686
673 } // namespace content 687 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698