OLD | NEW |
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/test/testing_profile.h" | 5 #include "chrome/test/testing_profile.h" |
6 | 6 |
7 #include "build/build_config.h" | 7 #include "build/build_config.h" |
8 | 8 |
9 #include "base/base_paths.h" | 9 #include "base/base_paths.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
167 } | 167 } |
168 | 168 |
169 TestingProfile::~TestingProfile() { | 169 TestingProfile::~TestingProfile() { |
170 NotificationService::current()->Notify( | 170 NotificationService::current()->Notify( |
171 NotificationType::PROFILE_DESTROYED, | 171 NotificationType::PROFILE_DESTROYED, |
172 Source<Profile>(static_cast<Profile*>(this)), | 172 Source<Profile>(static_cast<Profile*>(this)), |
173 NotificationService::NoDetails()); | 173 NotificationService::NoDetails()); |
174 | 174 |
175 profile_dependency_manager_->DestroyProfileServices(this); | 175 profile_dependency_manager_->DestroyProfileServices(this); |
176 | 176 |
| 177 if (host_content_settings_map_) |
| 178 host_content_settings_map_->ShutdownOnUIThread(); |
| 179 |
177 DestroyTopSites(); | 180 DestroyTopSites(); |
178 DestroyHistoryService(); | 181 DestroyHistoryService(); |
179 // FaviconService depends on HistoryServce so destroying it later. | 182 // FaviconService depends on HistoryServce so destroying it later. |
180 DestroyFaviconService(); | 183 DestroyFaviconService(); |
181 DestroyWebDataService(); | 184 DestroyWebDataService(); |
182 if (extension_service_.get()) { | 185 if (extension_service_.get()) { |
183 extension_service_.reset(); | 186 extension_service_.reset(); |
184 } | 187 } |
185 | 188 |
186 if (pref_proxy_config_tracker_.get()) | 189 if (pref_proxy_config_tracker_.get()) |
(...skipping 598 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
785 } | 788 } |
786 | 789 |
787 DerivedTestingProfile::DerivedTestingProfile(Profile* profile) | 790 DerivedTestingProfile::DerivedTestingProfile(Profile* profile) |
788 : original_profile_(profile) {} | 791 : original_profile_(profile) {} |
789 | 792 |
790 DerivedTestingProfile::~DerivedTestingProfile() {} | 793 DerivedTestingProfile::~DerivedTestingProfile() {} |
791 | 794 |
792 ProfileId DerivedTestingProfile::GetRuntimeId() { | 795 ProfileId DerivedTestingProfile::GetRuntimeId() { |
793 return original_profile_->GetRuntimeId(); | 796 return original_profile_->GetRuntimeId(); |
794 } | 797 } |
OLD | NEW |