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

Side by Side Diff: chrome/browser/browser_init.cc

Issue 1991009: Shorten several apps-related flags (Closed)
Patch Set: Created 10 years, 7 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 "chrome/browser/browser_init.h" 5 #include "chrome/browser/browser_init.h"
6 6
7 #include "app/l10n_util.h" 7 #include "app/l10n_util.h"
8 #include "app/resource_bundle.h" 8 #include "app/resource_bundle.h"
9 #include "base/event_recorder.h" 9 #include "base/event_recorder.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after
552 return true; 552 return true;
553 } 553 }
554 554
555 bool BrowserInit::LaunchWithProfile::IsAppLaunch(std::string* app_url, 555 bool BrowserInit::LaunchWithProfile::IsAppLaunch(std::string* app_url,
556 std::string* app_id) { 556 std::string* app_id) {
557 if (command_line_.HasSwitch(switches::kApp)) { 557 if (command_line_.HasSwitch(switches::kApp)) {
558 if (app_url) 558 if (app_url)
559 *app_url = command_line_.GetSwitchValueASCII(switches::kApp); 559 *app_url = command_line_.GetSwitchValueASCII(switches::kApp);
560 return true; 560 return true;
561 } 561 }
562 if (command_line_.HasSwitch(switches::kEnableExtensionApps) && 562 if (command_line_.HasSwitch(switches::kEnableApps) &&
563 command_line_.HasSwitch(switches::kAppId)) { 563 command_line_.HasSwitch(switches::kAppId)) {
564 if (app_id) 564 if (app_id)
565 *app_id = command_line_.GetSwitchValueASCII(switches::kAppId); 565 *app_id = command_line_.GetSwitchValueASCII(switches::kAppId);
566 return true; 566 return true;
567 } 567 }
568 return false; 568 return false;
569 } 569 }
570 570
571 bool BrowserInit::LaunchWithProfile::OpenApplicationWindow(Profile* profile) { 571 bool BrowserInit::LaunchWithProfile::OpenApplicationWindow(Profile* profile) {
572 std::string url_string, app_id; 572 std::string url_string, app_id;
(...skipping 483 matching lines...) Expand 10 before | Expand all | Expand 10 after
1056 scoped_refptr<AutomationProviderClass> automation = 1056 scoped_refptr<AutomationProviderClass> automation =
1057 new AutomationProviderClass(profile); 1057 new AutomationProviderClass(profile);
1058 automation->ConnectToChannel(channel_id); 1058 automation->ConnectToChannel(channel_id);
1059 automation->SetExpectedTabCount(expected_tabs); 1059 automation->SetExpectedTabCount(expected_tabs);
1060 1060
1061 AutomationProviderList* list = 1061 AutomationProviderList* list =
1062 g_browser_process->InitAutomationProviderList(); 1062 g_browser_process->InitAutomationProviderList();
1063 DCHECK(list); 1063 DCHECK(list);
1064 list->AddProvider(automation); 1064 list->AddProvider(automation);
1065 } 1065 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698