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

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

Issue 100573002: Move directory creation functions to base namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/first_run/first_run.h" 5 #include "chrome/browser/first_run/first_run.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
(...skipping 157 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 DoDelayedInstallExtensions(); 168 DoDelayedInstallExtensions();
169 } 169 }
170 } 170 }
171 171
172 base::FilePath GetDefaultPrefFilePath(bool create_profile_dir, 172 base::FilePath GetDefaultPrefFilePath(bool create_profile_dir,
173 const base::FilePath& user_data_dir) { 173 const base::FilePath& user_data_dir) {
174 base::FilePath default_pref_dir = 174 base::FilePath default_pref_dir =
175 profiles::GetDefaultProfileDir(user_data_dir); 175 profiles::GetDefaultProfileDir(user_data_dir);
176 if (create_profile_dir) { 176 if (create_profile_dir) {
177 if (!base::PathExists(default_pref_dir)) { 177 if (!base::PathExists(default_pref_dir)) {
178 if (!file_util::CreateDirectory(default_pref_dir)) 178 if (!base::CreateDirectory(default_pref_dir))
179 return base::FilePath(); 179 return base::FilePath();
180 } 180 }
181 } 181 }
182 return profiles::GetProfilePrefsPath(default_pref_dir); 182 return profiles::GetProfilePrefsPath(default_pref_dir);
183 } 183 }
184 184
185 // Sets the |items| bitfield according to whether the import data specified by 185 // Sets the |items| bitfield according to whether the import data specified by
186 // |import_type| should be be auto imported or not. 186 // |import_type| should be be auto imported or not.
187 void SetImportItem(PrefService* user_prefs, 187 void SetImportItem(PrefService* user_prefs,
188 const char* pref_path, 188 const char* pref_path,
(...skipping 635 matching lines...) Expand 10 before | Expand all | Expand 10 after
824 SetShouldDoPersonalDataManagerFirstRun(); 824 SetShouldDoPersonalDataManagerFirstRun();
825 825
826 internal::DoPostImportPlatformSpecificTasks(profile); 826 internal::DoPostImportPlatformSpecificTasks(profile);
827 } 827 }
828 828
829 uint16 auto_import_state() { 829 uint16 auto_import_state() {
830 return g_auto_import_state; 830 return g_auto_import_state;
831 } 831 }
832 832
833 } // namespace first_run 833 } // namespace first_run
OLDNEW
« no previous file with comments | « chrome/browser/extensions/webstore_installer.cc ('k') | chrome/browser/first_run/first_run_internal_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698