Chromium Code Reviews| Index: chrome/browser/ui/browser_init.cc |
| diff --git a/chrome/browser/ui/browser_init.cc b/chrome/browser/ui/browser_init.cc |
| index cb1d46572b1b38c0850b215c6972484f3fdfacb9..4b223fa7a06ee6d17274a574041f7b13b2535850 100644 |
| --- a/chrome/browser/ui/browser_init.cc |
| +++ b/chrome/browser/ui/browser_init.cc |
| @@ -628,12 +628,12 @@ bool BrowserInit::LaunchWithProfile::OpenApplicationWindow(Profile* profile) { |
| const Extension* extension = |
| extensions_service->GetExtensionById(app_id, false); |
| - // The extension with |app_id| may have been uninstalled. |
| + // The extension with id |app_id| may have been uninstalled. |
| if (!extension) |
| return false; |
| - // Look at prefs to find the container in which an app should launch. |
| - // If no preference is set, launch in a window. |
| + // Look at preferences to find the right launch container. If no |
| + // preference is set, launch as a window. |
| extension_misc::LaunchContainer launch_container = |
| extensions_service->extension_prefs()->GetLaunchContainer( |
| extension, ExtensionPrefs::LAUNCH_WINDOW); |
| @@ -657,8 +657,11 @@ bool BrowserInit::LaunchWithProfile::OpenApplicationWindow(Profile* profile) { |
| ChildProcessSecurityPolicy::GetInstance(); |
| if (policy->IsWebSafeScheme(url.scheme()) || |
| url.SchemeIs(chrome::kFileScheme)) { |
| - Browser::OpenApplicationWindow(profile, url); |
| - return true; |
| + TabContents* app_window = Browser::OpenUrlAppShortcutWindow( |
|
Aaron Boodman
2010/12/06 23:45:24
app_widow -> app_tab?
Sam Kerner (Chrome)
2010/12/07 04:12:30
Done.
|
| + profile, |
| + url, |
| + true); // Update app info. |
| + return (app_window != NULL); |
| } |
| } |
| return false; |