diff options
author | rafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-04 16:08:29 +0000 |
---|---|---|
committer | rafaelw@chromium.org <rafaelw@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-02-04 16:08:29 +0000 |
commit | f298901fdf7b438d12b776407026eec114e3682b (patch) | |
tree | b0931bef4c62eca2a6b674d7f692d25694628edf /chrome/browser/browser_init.cc | |
parent | 3bd19b38ccaedafc2dd6dd8359b7a2083e7fdae7 (diff) | |
download | chromium_src-f298901fdf7b438d12b776407026eec114e3682b.zip chromium_src-f298901fdf7b438d12b776407026eec114e3682b.tar.gz chromium_src-f298901fdf7b438d12b776407026eec114e3682b.tar.bz2 |
Step 1 in Implementing/Prototyping App Panels.
In this first step we
1) Create a new Browser::Type::TYPE_APP_PANEL which is observed in various places
2) Create an AppPanelBrowserFrame which is created in BrowserFrameWin when the TYPE_APP_PANEL is observed. AppPanelBrowserFrame draws itself per glen's mocks and will ultimately behave substantially different from regular browser windows.
3) Create a temporary command switch called --app-launch-as-panel which can be used until we implement actual app launching.
Note that there is still work to be done "bit-twiddling" to match glen's mocks and to implement the "inactive" look for these windows.
Steps 2 through N may include: different sizing behavior (based either on the content size or an api call), different min/maximize behavior, docking to the os taskbar, auto order & placement of app panels.
A screen capture of the current implementation is attached to the bug.
BUG=32361
Review URL: http://codereview.chromium.org/553143
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@38107 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/browser_init.cc')
-rw-r--r-- | chrome/browser/browser_init.cc | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/chrome/browser/browser_init.cc b/chrome/browser/browser_init.cc index afef33e..4f9b2cb 100644 --- a/chrome/browser/browser_init.cc +++ b/chrome/browser/browser_init.cc @@ -506,6 +506,9 @@ bool BrowserInit::LaunchWithProfile::Launch(Profile* profile, bool BrowserInit::LaunchWithProfile::OpenApplicationURL(Profile* profile) { if (!command_line_.HasSwitch(switches::kApp)) return false; + bool launch_as_panel = + command_line_.HasSwitch(switches::kEnableExtensionApps) && + command_line_.HasSwitch(switches::kAppLaunchAsPanel); std::string url_string(command_line_.GetSwitchValueASCII(switches::kApp)); #if defined(OS_WIN) // Fix up Windows shortcuts. @@ -519,7 +522,7 @@ bool BrowserInit::LaunchWithProfile::OpenApplicationURL(Profile* profile) { ChildProcessSecurityPolicy::GetInstance(); if (policy->IsWebSafeScheme(url.scheme()) || url.SchemeIs(chrome::kFileScheme)) { - Browser::OpenApplicationWindow(profile, url); + Browser::OpenApplicationWindow(profile, url, launch_as_panel); return true; } } |