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

Side by Side Diff: chrome/browser/service/service_process_control.cc

Issue 9034032: And now NewRunnableMethod(), you die. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix chrome_frame_automation Created 8 years, 11 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
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/service/service_process_control.h" 5 #include "chrome/browser/service/service_process_control.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/file_path.h" 10 #include "base/file_path.h"
(...skipping 238 matching lines...) Expand 10 before | Expand all | Expand 10 after
249 bool ret = Send(new ServiceMsg_Shutdown()); 249 bool ret = Send(new ServiceMsg_Shutdown());
250 channel_.reset(); 250 channel_.reset();
251 return ret; 251 return ret;
252 } 252 }
253 253
254 // static 254 // static
255 ServiceProcessControl* ServiceProcessControl::GetInstance() { 255 ServiceProcessControl* ServiceProcessControl::GetInstance() {
256 return Singleton<ServiceProcessControl>::get(); 256 return Singleton<ServiceProcessControl>::get();
257 } 257 }
258 258
259 DISABLE_RUNNABLE_METHOD_REFCOUNT(ServiceProcessControl);
260
261 ServiceProcessControl::Launcher::Launcher(ServiceProcessControl* process, 259 ServiceProcessControl::Launcher::Launcher(ServiceProcessControl* process,
262 CommandLine* cmd_line) 260 CommandLine* cmd_line)
263 : process_(process), 261 : process_(process),
264 cmd_line_(cmd_line), 262 cmd_line_(cmd_line),
265 launched_(false), 263 launched_(false),
266 retry_count_(0) { 264 retry_count_(0) {
267 } 265 }
268 266
269 // Execute the command line to start the process asynchronously. 267 // Execute the command line to start the process asynchronously.
270 // After the command is executed, |task| is called with the process handle on 268 // After the command is executed, |task| is called with the process handle on
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after
314 if (base::LaunchProcess(*cmd_line_, options, NULL)) { 312 if (base::LaunchProcess(*cmd_line_, options, NULL)) {
315 BrowserThread::PostTask( 313 BrowserThread::PostTask(
316 BrowserThread::IO, FROM_HERE, 314 BrowserThread::IO, FROM_HERE,
317 base::Bind(&Launcher::DoDetectLaunched, this)); 315 base::Bind(&Launcher::DoDetectLaunched, this));
318 } else { 316 } else {
319 BrowserThread::PostTask( 317 BrowserThread::PostTask(
320 BrowserThread::UI, FROM_HERE, base::Bind(&Launcher::Notify, this)); 318 BrowserThread::UI, FROM_HERE, base::Bind(&Launcher::Notify, this));
321 } 319 }
322 } 320 }
323 #endif // !OS_MACOSX 321 #endif // !OS_MACOSX
OLDNEW
« no previous file with comments | « chrome/browser/net/predictor.cc ('k') | chrome/browser/service/service_process_control_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698