| 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/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
| (...skipping 987 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 998 | 998 |
| 999 void WebContentsImpl::ToggleFullscreenMode(bool enter_fullscreen) { | 999 void WebContentsImpl::ToggleFullscreenMode(bool enter_fullscreen) { |
| 1000 if (delegate_) | 1000 if (delegate_) |
| 1001 delegate_->ToggleFullscreenModeForTab(this, enter_fullscreen); | 1001 delegate_->ToggleFullscreenModeForTab(this, enter_fullscreen); |
| 1002 } | 1002 } |
| 1003 | 1003 |
| 1004 bool WebContentsImpl::IsFullscreenForCurrentTab() const { | 1004 bool WebContentsImpl::IsFullscreenForCurrentTab() const { |
| 1005 return delegate_ ? delegate_->IsFullscreenForTabOrPending(this) : false; | 1005 return delegate_ ? delegate_->IsFullscreenForTabOrPending(this) : false; |
| 1006 } | 1006 } |
| 1007 | 1007 |
| 1008 void WebContentsImpl::RequestToLockMouse() { | 1008 void WebContentsImpl::RequestToLockMouse(bool user_gesture) { |
| 1009 if (delegate_) { | 1009 if (delegate_) { |
| 1010 delegate_->RequestToLockMouse(this); | 1010 delegate_->RequestToLockMouse(this, user_gesture); |
| 1011 } else { | 1011 } else { |
| 1012 GotResponseToLockMouseRequest(false); | 1012 GotResponseToLockMouseRequest(false); |
| 1013 } | 1013 } |
| 1014 } | 1014 } |
| 1015 | 1015 |
| 1016 void WebContentsImpl::LostMouseLock() { | 1016 void WebContentsImpl::LostMouseLock() { |
| 1017 if (delegate_) | 1017 if (delegate_) |
| 1018 delegate_->LostMouseLock(); | 1018 delegate_->LostMouseLock(); |
| 1019 } | 1019 } |
| 1020 | 1020 |
| (...skipping 1612 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2633 void WebContentsImpl::CreateViewAndSetSizeForRVH(RenderViewHost* rvh) { | 2633 void WebContentsImpl::CreateViewAndSetSizeForRVH(RenderViewHost* rvh) { |
| 2634 RenderWidgetHostView* rwh_view = GetView()->CreateViewForWidget(rvh); | 2634 RenderWidgetHostView* rwh_view = GetView()->CreateViewForWidget(rvh); |
| 2635 // Can be NULL during tests. | 2635 // Can be NULL during tests. |
| 2636 if (rwh_view) | 2636 if (rwh_view) |
| 2637 rwh_view->SetSize(GetView()->GetContainerSize()); | 2637 rwh_view->SetSize(GetView()->GetContainerSize()); |
| 2638 } | 2638 } |
| 2639 | 2639 |
| 2640 RenderViewHostImpl* WebContentsImpl::GetRenderViewHostImpl() { | 2640 RenderViewHostImpl* WebContentsImpl::GetRenderViewHostImpl() { |
| 2641 return static_cast<RenderViewHostImpl*>(GetRenderViewHost()); | 2641 return static_cast<RenderViewHostImpl*>(GetRenderViewHost()); |
| 2642 } | 2642 } |
| OLD | NEW |