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

Side by Side Diff: content/renderer/render_view_impl.cc

Issue 789533002: Fullscreen: make fullscreen requests come from RenderFrame (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: make try happy Created 5 years, 11 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
« no previous file with comments | « content/renderer/render_view_impl.h ('k') | content/shell/browser/shell.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/renderer/render_view_impl.h" 5 #include "content/renderer/render_view_impl.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "base/auto_reset.h" 10 #include "base/auto_reset.h"
(...skipping 2010 matching lines...) Expand 10 before | Expand all | Expand 10 after
2021 // timers so that we do not need to manage the shared timer in such a heavy 2021 // timers so that we do not need to manage the shared timer in such a heavy
2022 // handed manner. 2022 // handed manner.
2023 // 2023 //
2024 if (RenderThreadImpl::current()) // Will be NULL during unit tests. 2024 if (RenderThreadImpl::current()) // Will be NULL during unit tests.
2025 RenderThreadImpl::current()->DoNotSuspendWebKitSharedTimer(); 2025 RenderThreadImpl::current()->DoNotSuspendWebKitSharedTimer();
2026 2026
2027 SendAndRunNestedMessageLoop(new ViewHostMsg_RunModal( 2027 SendAndRunNestedMessageLoop(new ViewHostMsg_RunModal(
2028 routing_id_, opener_id_)); 2028 routing_id_, opener_id_));
2029 } 2029 }
2030 2030
2031 bool RenderViewImpl::enterFullScreen() {
2032 Send(new ViewHostMsg_ToggleFullscreen(routing_id_, true));
2033 return true;
2034 }
2035
2036 void RenderViewImpl::exitFullScreen() {
2037 Send(new ViewHostMsg_ToggleFullscreen(routing_id_, false));
2038 }
2039
2040 bool RenderViewImpl::requestPointerLock() { 2031 bool RenderViewImpl::requestPointerLock() {
2041 return mouse_lock_dispatcher_->LockMouse(webwidget_mouse_lock_target_.get()); 2032 return mouse_lock_dispatcher_->LockMouse(webwidget_mouse_lock_target_.get());
2042 } 2033 }
2043 2034
2044 void RenderViewImpl::requestPointerUnlock() { 2035 void RenderViewImpl::requestPointerUnlock() {
2045 mouse_lock_dispatcher_->UnlockMouse(webwidget_mouse_lock_target_.get()); 2036 mouse_lock_dispatcher_->UnlockMouse(webwidget_mouse_lock_target_.get());
2046 } 2037 }
2047 2038
2048 bool RenderViewImpl::isPointerLocked() { 2039 bool RenderViewImpl::isPointerLocked() {
2049 return mouse_lock_dispatcher_->IsMouseLockedTo( 2040 return mouse_lock_dispatcher_->IsMouseLockedTo(
(...skipping 2055 matching lines...) Expand 10 before | Expand all | Expand 10 after
4105 std::vector<gfx::Size> sizes; 4096 std::vector<gfx::Size> sizes;
4106 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); 4097 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes);
4107 if (!url.isEmpty()) 4098 if (!url.isEmpty())
4108 urls.push_back( 4099 urls.push_back(
4109 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); 4100 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes));
4110 } 4101 }
4111 SendUpdateFaviconURL(urls); 4102 SendUpdateFaviconURL(urls);
4112 } 4103 }
4113 4104
4114 } // namespace content 4105 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/render_view_impl.h ('k') | content/shell/browser/shell.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698