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

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

Issue 8590003: chrome: Remove 11 exit time destructors and 4 static initializers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: no gyp changes :-( Created 9 years, 1 month 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 <set> 5 #include <set>
6 6
7 #include "chrome/browser/profiles/profile_manager.h" 7 #include "chrome/browser/profiles/profile_manager.h"
8 8
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 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 #include "chrome/browser/chromeos/cros/cros_library.h" 46 #include "chrome/browser/chromeos/cros/cros_library.h"
47 #include "chrome/browser/chromeos/cros/cryptohome_library.h" 47 #include "chrome/browser/chromeos/cros/cryptohome_library.h"
48 #endif 48 #endif
49 49
50 using content::BrowserThread; 50 using content::BrowserThread;
51 51
52 namespace { 52 namespace {
53 53
54 // Profiles that should be deleted on shutdown. 54 // Profiles that should be deleted on shutdown.
55 std::vector<FilePath>& ProfilesToDelete() { 55 std::vector<FilePath>& ProfilesToDelete() {
56 static std::vector<FilePath> profiles_to_delete; 56 CR_DEFINE_STATIC_LOCAL(std::vector<FilePath>, profiles_to_delete, ());
57 return profiles_to_delete; 57 return profiles_to_delete;
58 } 58 }
59 59
60 // Simple task to log the size of the current profile. 60 // Simple task to log the size of the current profile.
61 class ProfileSizeTask : public Task { 61 class ProfileSizeTask : public Task {
62 public: 62 public:
63 explicit ProfileSizeTask(Profile* profile); 63 explicit ProfileSizeTask(Profile* profile);
64 virtual ~ProfileSizeTask() {} 64 virtual ~ProfileSizeTask() {}
65 65
66 virtual void Run(); 66 virtual void Run();
(...skipping 610 matching lines...) Expand 10 before | Expand all | Expand 10 after
677 ProfileManagerWithoutInit::ProfileManagerWithoutInit( 677 ProfileManagerWithoutInit::ProfileManagerWithoutInit(
678 const FilePath& user_data_dir) : ProfileManager(user_data_dir) { 678 const FilePath& user_data_dir) : ProfileManager(user_data_dir) {
679 } 679 }
680 680
681 void ProfileManager::RegisterTestingProfile(Profile* profile, 681 void ProfileManager::RegisterTestingProfile(Profile* profile,
682 bool add_to_cache) { 682 bool add_to_cache) {
683 RegisterProfile(profile, true); 683 RegisterProfile(profile, true);
684 if (add_to_cache) 684 if (add_to_cache)
685 AddProfileToCache(profile); 685 AddProfileToCache(profile);
686 } 686 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698