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

Side by Side Diff: chrome/browser/profiles/profile_manager.h

Issue 7780031: Fix sync test crashing when multiprofiles are enabled on Mac. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 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/browser/profiles/profile_manager.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 // This class keeps track of the currently-active profiles in the runtime. 5 // This class keeps track of the currently-active profiles in the runtime.
6 6
7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_MANAGER_H_ 7 #ifndef CHROME_BROWSER_PROFILES_PROFILE_MANAGER_H_
8 #define CHROME_BROWSER_PROFILES_PROFILE_MANAGER_H_ 8 #define CHROME_BROWSER_PROFILES_PROFILE_MANAGER_H_
9 #pragma once 9 #pragma once
10 10
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 // Returns a ProfileInfoCache object which can be used to get information 166 // Returns a ProfileInfoCache object which can be used to get information
167 // about profiles without having to load them from disk. 167 // about profiles without having to load them from disk.
168 ProfileInfoCache& GetProfileInfoCache(); 168 ProfileInfoCache& GetProfileInfoCache();
169 169
170 // Schedules the profile at the given path to be deleted on shutdown. 170 // Schedules the profile at the given path to be deleted on shutdown.
171 void ScheduleProfileForDeletion(const FilePath& profile_dir); 171 void ScheduleProfileForDeletion(const FilePath& profile_dir);
172 172
173 // Checks if multiple profiles is enabled. 173 // Checks if multiple profiles is enabled.
174 static bool IsMultipleProfilesEnabled(); 174 static bool IsMultipleProfilesEnabled();
175 175
176 // Register and add testing profile to the ProfileManager. Use ONLY in tests.
177 // This allows the creation of Profiles outside of the standard creation path
178 // for testing. If |addToCache|, add to ProfileInfoCache as well.
179 void RegisterTestingProfile(Profile* profile, bool addToCache);
180
176 protected: 181 protected:
177 // Does final initial actions. 182 // Does final initial actions.
178 virtual void DoFinalInit(Profile* profile, bool go_off_the_record); 183 virtual void DoFinalInit(Profile* profile, bool go_off_the_record);
179 184
180 private: 185 private:
181 friend class TestingProfileManager; 186 friend class TestingProfileManager;
182 187
183 // This struct contains information about profiles which are being loaded or 188 // This struct contains information about profiles which are being loaded or
184 // were loaded. 189 // were loaded.
185 struct ProfileInfo { 190 struct ProfileInfo {
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
255 // profile. This one is useful in unittests. 260 // profile. This one is useful in unittests.
256 class ProfileManagerWithoutInit : public ProfileManager { 261 class ProfileManagerWithoutInit : public ProfileManager {
257 public: 262 public:
258 explicit ProfileManagerWithoutInit(const FilePath& user_data_dir); 263 explicit ProfileManagerWithoutInit(const FilePath& user_data_dir);
259 264
260 protected: 265 protected:
261 virtual void DoFinalInit(Profile*, bool) {} 266 virtual void DoFinalInit(Profile*, bool) {}
262 }; 267 };
263 268
264 #endif // CHROME_BROWSER_PROFILES_PROFILE_MANAGER_H_ 269 #endif // CHROME_BROWSER_PROFILES_PROFILE_MANAGER_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/profiles/profile_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698