Chromium Code Reviews| Index: content/browser/frame_host/render_frame_host_impl.cc |
| diff --git a/content/browser/frame_host/render_frame_host_impl.cc b/content/browser/frame_host/render_frame_host_impl.cc |
| index 72d53245905548c7587908e18958539a1e3f6875..f0b94a6d213bb97da63cadf98b559e5c59b81b57 100644 |
| --- a/content/browser/frame_host/render_frame_host_impl.cc |
| +++ b/content/browser/frame_host/render_frame_host_impl.cc |
| @@ -330,6 +330,7 @@ bool RenderFrameHostImpl::OnMessageReceived(const IPC::Message &msg) { |
| OnAccessibilityLocationChanges) |
| IPC_MESSAGE_HANDLER(AccessibilityHostMsg_FindInPageResult, |
| OnAccessibilityFindInPageResult) |
| + IPC_MESSAGE_HANDLER(FrameHostMsg_ToggleFullscreen, OnToggleFullscreen) |
| #if defined(OS_MACOSX) || defined(OS_ANDROID) |
| IPC_MESSAGE_HANDLER(FrameHostMsg_ShowPopup, OnShowPopup) |
| IPC_MESSAGE_HANDLER(FrameHostMsg_HidePopup, OnHidePopup) |
| @@ -1111,6 +1112,15 @@ void RenderFrameHostImpl::OnAccessibilityFindInPageResult( |
| } |
| } |
| +void RenderFrameHostImpl::OnToggleFullscreen(bool enter_fullscreen) { |
| + DCHECK_CURRENTLY_ON(BrowserThread::UI); |
|
Charlie Reis
2014/12/10 00:51:21
nit: This whole class is on the UI thread, so we d
mlamouri (slow - plz ping)
2014/12/10 15:47:02
Done.
mlamouri (slow - plz ping)
2014/12/10 15:47:02
Done.
|
| + |
| + if (enter_fullscreen) |
| + render_view_host_->EnterFullscreen(GetLastCommittedURL().GetOrigin()); |
| + else |
| + render_view_host_->ExitFullscreen(); |
| +} |
| + |
| #if defined(OS_MACOSX) || defined(OS_ANDROID) |
| void RenderFrameHostImpl::OnShowPopup( |
| const FrameHostMsg_ShowPopup_Params& params) { |