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

Side by Side Diff: chrome/common/service_process_util_win.cc

Issue 7386002: Rename CommandLine::GetCommandLineString(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge. Created 9 years, 5 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 | « chrome/common/service_process_util_linux.cc ('k') | chrome/common/switch_utils_unittest.cc » ('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) 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/common/service_process_util.h" 5 #include "chrome/common/service_process_util.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/file_util.h" 8 #include "base/file_util.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
146 146
147 bool ServiceProcessState::AddToAutoRun() { 147 bool ServiceProcessState::AddToAutoRun() {
148 DCHECK(autorun_command_line_.get()); 148 DCHECK(autorun_command_line_.get());
149 // Remove the old autorun value first because we changed the naming scheme 149 // Remove the old autorun value first because we changed the naming scheme
150 // for the autorun value name. 150 // for the autorun value name.
151 base::win::RemoveCommandFromAutoRun( 151 base::win::RemoveCommandFromAutoRun(
152 HKEY_CURRENT_USER, UTF8ToWide(GetObsoleteServiceProcessAutoRunKey())); 152 HKEY_CURRENT_USER, UTF8ToWide(GetObsoleteServiceProcessAutoRunKey()));
153 return base::win::AddCommandToAutoRun( 153 return base::win::AddCommandToAutoRun(
154 HKEY_CURRENT_USER, 154 HKEY_CURRENT_USER,
155 UTF8ToWide(GetServiceProcessAutoRunKey()), 155 UTF8ToWide(GetServiceProcessAutoRunKey()),
156 autorun_command_line_->command_line_string()); 156 autorun_command_line_->GetCommandLineString());
157 } 157 }
158 158
159 bool ServiceProcessState::RemoveFromAutoRun() { 159 bool ServiceProcessState::RemoveFromAutoRun() {
160 // Remove the old autorun value first because we changed the naming scheme 160 // Remove the old autorun value first because we changed the naming scheme
161 // for the autorun value name. 161 // for the autorun value name.
162 base::win::RemoveCommandFromAutoRun( 162 base::win::RemoveCommandFromAutoRun(
163 HKEY_CURRENT_USER, UTF8ToWide(GetObsoleteServiceProcessAutoRunKey())); 163 HKEY_CURRENT_USER, UTF8ToWide(GetObsoleteServiceProcessAutoRunKey()));
164 return base::win::RemoveCommandFromAutoRun( 164 return base::win::RemoveCommandFromAutoRun(
165 HKEY_CURRENT_USER, UTF8ToWide(GetServiceProcessAutoRunKey())); 165 HKEY_CURRENT_USER, UTF8ToWide(GetServiceProcessAutoRunKey()));
166 } 166 }
167 167
168 void ServiceProcessState::TearDownState() { 168 void ServiceProcessState::TearDownState() {
169 delete state_; 169 delete state_;
170 state_ = NULL; 170 state_ = NULL;
171 } 171 }
OLDNEW
« no previous file with comments | « chrome/common/service_process_util_linux.cc ('k') | chrome/common/switch_utils_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698