| OLD | NEW |
| 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/test/base/testing_profile.h" | 5 #include "chrome/test/base/testing_profile.h" |
| 6 | 6 |
| 7 #include "base/base_paths.h" | 7 #include "base/base_paths.h" |
| 8 #include "base/command_line.h" | 8 #include "base/command_line.h" |
| 9 #include "base/files/file_util.h" | 9 #include "base/files/file_util.h" |
| 10 #include "base/message_loop/message_loop_proxy.h" | 10 #include "base/message_loop/message_loop_proxy.h" |
| (...skipping 214 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 225 history::HistoryService* history_service = new history::HistoryService( | 225 history::HistoryService* history_service = new history::HistoryService( |
| 226 ChromeHistoryClientFactory::GetForProfile(profile), | 226 ChromeHistoryClientFactory::GetForProfile(profile), |
| 227 scoped_ptr<history::VisitDelegate>( | 227 scoped_ptr<history::VisitDelegate>( |
| 228 new history::ContentVisitDelegate(profile))); | 228 new history::ContentVisitDelegate(profile))); |
| 229 return history_service; | 229 return history_service; |
| 230 } | 230 } |
| 231 | 231 |
| 232 KeyedService* BuildInMemoryURLIndex(content::BrowserContext* context) { | 232 KeyedService* BuildInMemoryURLIndex(content::BrowserContext* context) { |
| 233 Profile* profile = Profile::FromBrowserContext(context); | 233 Profile* profile = Profile::FromBrowserContext(context); |
| 234 InMemoryURLIndex* in_memory_url_index = new InMemoryURLIndex( | 234 InMemoryURLIndex* in_memory_url_index = new InMemoryURLIndex( |
| 235 BookmarkModelFactory::GetForProfile(profile), |
| 235 HistoryServiceFactory::GetForProfile(profile, | 236 HistoryServiceFactory::GetForProfile(profile, |
| 236 ServiceAccessType::IMPLICIT_ACCESS), | 237 ServiceAccessType::IMPLICIT_ACCESS), |
| 237 profile->GetPath(), | 238 profile->GetPath(), |
| 238 profile->GetPrefs()->GetString(prefs::kAcceptLanguages)); | 239 profile->GetPrefs()->GetString(prefs::kAcceptLanguages)); |
| 239 in_memory_url_index->Init(); | 240 in_memory_url_index->Init(); |
| 240 return in_memory_url_index; | 241 return in_memory_url_index; |
| 241 } | 242 } |
| 242 | 243 |
| 243 KeyedService* BuildBookmarkModel(content::BrowserContext* context) { | 244 KeyedService* BuildBookmarkModel(content::BrowserContext* context) { |
| 244 Profile* profile = static_cast<Profile*>(context); | 245 Profile* profile = static_cast<Profile*>(context); |
| (...skipping 877 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1122 #if defined(ENABLE_EXTENSIONS) | 1123 #if defined(ENABLE_EXTENSIONS) |
| 1123 extension_policy_, | 1124 extension_policy_, |
| 1124 #endif | 1125 #endif |
| 1125 pref_service_.Pass(), | 1126 pref_service_.Pass(), |
| 1126 original_profile, | 1127 original_profile, |
| 1127 guest_session_, | 1128 guest_session_, |
| 1128 supervised_user_id_, | 1129 supervised_user_id_, |
| 1129 policy_service_.Pass(), | 1130 policy_service_.Pass(), |
| 1130 testing_factories_); | 1131 testing_factories_); |
| 1131 } | 1132 } |
| OLD | NEW |