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

Unified Diff: chrome/browser/ui/extensions/shell_window.h

Issue 13609003: fullscreen in apps v2 ShellWindow via app.window.create. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: patch for landing Created 7 years, 8 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
Index: chrome/browser/ui/extensions/shell_window.h
diff --git a/chrome/browser/ui/extensions/shell_window.h b/chrome/browser/ui/extensions/shell_window.h
index 5d7e8f6362827f156d6e7b054aac147b4c1a612e..9204223366128f368076133b676e828583a47a37 100644
--- a/chrome/browser/ui/extensions/shell_window.h
+++ b/chrome/browser/ui/extensions/shell_window.h
@@ -100,6 +100,16 @@ class ShellWindow : public content::NotificationObserver,
// The process ID of the process that requested the create.
int32 creator_process_id;
+ enum State {
+ STATE_NORMAL,
+ STATE_FULLSCREEN,
+ STATE_MAXIMIZED,
+ STATE_MINIMIZED
+ };
+
+ // Initial state of the window.
+ State state;
+
// If true, don't show the window after creation.
bool hidden;
@@ -179,6 +189,13 @@ class ShellWindow : public content::NotificationObserver,
// callback. Also called externally for v1 apps using Ash Panels.
void UpdateAppIcon(const gfx::Image& image);
+ // Transitions window into fullscreen, maximized, minimized or restores based
+ // on chrome.app.window API.
+ void Fullscreen();
+ void Maximize();
+ void Minimize();
+ void Restore();
+
ShellWindowContents* shell_window_contents_for_test() {
return shell_window_contents_.get();
}
@@ -277,6 +294,11 @@ class ShellWindow : public content::NotificationObserver,
base::WeakPtrFactory<ShellWindow> image_loader_ptr_factory_;
+ // Fullscreen entered by app.window api.
+ bool fullscreen_for_window_api_;
+ // Fullscreen entered by HTML requestFullscreen.
+ bool fullscreen_for_tab_;
+
DISALLOW_COPY_AND_ASSIGN(ShellWindow);
};
« no previous file with comments | « chrome/browser/extensions/extension_function_histogram_value.h ('k') | chrome/browser/ui/extensions/shell_window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698