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

Side by Side Diff: chrome/service/service_main.cc

Issue 3384001: The LSID for Cloud Print can now be supplied on the command line even if Clou... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/service/service_process.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "base/debug_util.h" 5 #include "base/debug_util.h"
6 #include "base/message_loop.h" 6 #include "base/message_loop.h"
7 #include "base/path_service.h" 7 #include "base/path_service.h"
8 #include "chrome/common/chrome_paths.h" 8 #include "chrome/common/chrome_paths.h"
9 #include "chrome/common/chrome_switches.h" 9 #include "chrome/common/chrome_switches.h"
10 #include "chrome/common/main_function_params.h" 10 #include "chrome/common/main_function_params.h"
(...skipping 11 matching lines...) Expand all
22 PlatformThread::SetName("CrServiceMain"); 22 PlatformThread::SetName("CrServiceMain");
23 23
24 #if defined(OS_WIN) 24 #if defined(OS_WIN)
25 sandbox::BrokerServices* broker_services = 25 sandbox::BrokerServices* broker_services =
26 parameters.sandbox_info_.BrokerServices(); 26 parameters.sandbox_info_.BrokerServices();
27 if (broker_services) 27 if (broker_services)
28 sandbox::InitBrokerServices(broker_services); 28 sandbox::InitBrokerServices(broker_services);
29 #endif // defined(OS_WIN) 29 #endif // defined(OS_WIN)
30 30
31 ServiceProcess service_process; 31 ServiceProcess service_process;
32 service_process.Initialize(&main_message_loop); 32 service_process.Initialize(&main_message_loop, parameters.command_line_);
33
34 // Enable Cloud Print if needed.
35 if (parameters.command_line_.HasSwitch(switches::kEnableCloudPrintProxy)) {
36 std::string lsid =
37 parameters.command_line_.GetSwitchValueASCII(
38 switches::kServiceAccountLsid);
39 service_process.GetCloudPrintProxy()->EnableForUser(lsid);
40 }
41 33
42 MessageLoop::current()->Run(); 34 MessageLoop::current()->Run();
43 service_process.Teardown(); 35 service_process.Teardown();
44 return 0; 36 return 0;
45 } 37 }
OLDNEW
« no previous file with comments | « no previous file | chrome/service/service_process.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698