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

Unified Diff: chrome/browser/views/frame/browser_view.cc

Issue 28012: Fullscreen mode UI.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 11 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/views/frame/browser_view.h ('k') | chrome/browser/views/fullscreen_exit_bubble.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/views/frame/browser_view.cc
===================================================================
--- chrome/browser/views/frame/browser_view.cc (revision 10202)
+++ chrome/browser/views/frame/browser_view.cc (working copy)
@@ -22,6 +22,7 @@
#include "chrome/browser/views/clear_browsing_data.h"
#include "chrome/browser/views/download_shelf_view.h"
#include "chrome/browser/views/frame/browser_frame.h"
+#include "chrome/browser/views/fullscreen_exit_bubble.h"
#include "chrome/browser/views/html_dialog_view.h"
#include "chrome/browser/views/importer_view.h"
#include "chrome/browser/views/infobars/infobar_container.h"
@@ -577,7 +578,9 @@
if (bookmark_bar_view_.get())
bookmark_bar_view_->OnFullscreenToggled(fullscreen_);
- HWND hwnd = GetWidget()->GetHWND();
+ // Size/position/style window appropriately.
+ views::Widget* widget = GetWidget();
+ HWND hwnd = widget->GetHWND();
gfx::Rect new_rect;
if (fullscreen_) {
// Save current window information.
@@ -605,6 +608,10 @@
// This will cause the window to re-layout.
SetWindowPos(hwnd, NULL, new_rect.x(), new_rect.y(), new_rect.width(),
new_rect.height(), SWP_NOZORDER | SWP_NOACTIVATE | SWP_FRAMECHANGED);
+
+ // Turn fullscreen bubble on or off.
+ fullscreen_bubble_.reset(fullscreen_ ?
+ new FullscreenExitBubble(widget, browser_.get()) : NULL);
}
bool BrowserView::IsFullscreen() const {
« no previous file with comments | « chrome/browser/views/frame/browser_view.h ('k') | chrome/browser/views/fullscreen_exit_bubble.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698