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

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

Issue 2149453004: Implement first version of OfflinePageSuggestionsProvider (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Remove separate build target for offline_page_suggestions Created 4 years, 5 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
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/profiles/profile_manager.h" 5 #include "chrome/browser/profiles/profile_manager.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
100 #endif 100 #endif
101 101
102 #if defined(ENABLE_SUPERVISED_USERS) 102 #if defined(ENABLE_SUPERVISED_USERS)
103 #include "chrome/browser/supervised_user/child_accounts/child_account_service.h" 103 #include "chrome/browser/supervised_user/child_accounts/child_account_service.h"
104 #include "chrome/browser/supervised_user/child_accounts/child_account_service_fa ctory.h" 104 #include "chrome/browser/supervised_user/child_accounts/child_account_service_fa ctory.h"
105 #include "chrome/browser/supervised_user/supervised_user_service.h" 105 #include "chrome/browser/supervised_user/supervised_user_service.h"
106 #include "chrome/browser/supervised_user/supervised_user_service_factory.h" 106 #include "chrome/browser/supervised_user/supervised_user_service_factory.h"
107 #endif 107 #endif
108 108
109 #if defined(OS_ANDROID) 109 #if defined(OS_ANDROID)
110 #include "chrome/browser/android/ntp/offline_page_suggestions_provider_factory.h "
110 #include "chrome/browser/ntp_snippets/content_suggestions_service_factory.h" 111 #include "chrome/browser/ntp_snippets/content_suggestions_service_factory.h"
111 #include "chrome/browser/ntp_snippets/ntp_snippets_service_factory.h" 112 #include "chrome/browser/ntp_snippets/ntp_snippets_service_factory.h"
112 #endif 113 #endif
113 114
114 #if defined(OS_CHROMEOS) 115 #if defined(OS_CHROMEOS)
115 #include "chrome/browser/browser_process_platform_part_chromeos.h" 116 #include "chrome/browser/browser_process_platform_part_chromeos.h"
116 #include "chrome/browser/chromeos/profiles/profile_helper.h" 117 #include "chrome/browser/chromeos/profiles/profile_helper.h"
117 #include "chromeos/chromeos_switches.h" 118 #include "chromeos/chromeos_switches.h"
118 #include "chromeos/dbus/cryptohome_client.h" 119 #include "chromeos/dbus/cryptohome_client.h"
119 #include "chromeos/dbus/dbus_thread_manager.h" 120 #include "chromeos/dbus/dbus_thread_manager.h"
(...skipping 1102 matching lines...) Expand 10 before | Expand all | Expand 10 after
1222 // which controls password management behaviour on Chrome and Android. After 1223 // which controls password management behaviour on Chrome and Android. After
1223 // migration will be performed for all users it's planned to remove the 1224 // migration will be performed for all users it's planned to remove the
1224 // migration code, rough time estimates are Q1 2016. 1225 // migration code, rough time estimates are Q1 2016.
1225 PasswordManagerSettingMigratorServiceFactory::GetForProfile(profile) 1226 PasswordManagerSettingMigratorServiceFactory::GetForProfile(profile)
1226 ->InitializeMigration(ProfileSyncServiceFactory::GetForProfile(profile)); 1227 ->InitializeMigration(ProfileSyncServiceFactory::GetForProfile(profile));
1227 1228
1228 #if defined(OS_ANDROID) 1229 #if defined(OS_ANDROID)
1229 // Service is responsible for fetching content snippets for the NTP. 1230 // Service is responsible for fetching content snippets for the NTP.
1230 ContentSuggestionsServiceFactory::GetForProfile(profile); 1231 ContentSuggestionsServiceFactory::GetForProfile(profile);
1231 NTPSnippetsServiceFactory::GetForProfile(profile); 1232 NTPSnippetsServiceFactory::GetForProfile(profile);
1233 OfflinePageSuggestionsProviderFactory::GetForProfile(profile);
1232 #endif 1234 #endif
1233 } 1235 }
1234 1236
1235 void ProfileManager::DoFinalInitLogging(Profile* profile) { 1237 void ProfileManager::DoFinalInitLogging(Profile* profile) {
1236 TRACE_EVENT0("browser", "ProfileManager::DoFinalInitLogging"); 1238 TRACE_EVENT0("browser", "ProfileManager::DoFinalInitLogging");
1237 // Count number of extensions in this profile. 1239 // Count number of extensions in this profile.
1238 int enabled_app_count = -1; 1240 int enabled_app_count = -1;
1239 #if defined(ENABLE_EXTENSIONS) 1241 #if defined(ENABLE_EXTENSIONS)
1240 enabled_app_count = GetEnabledAppCount(profile); 1242 enabled_app_count = GetEnabledAppCount(profile);
1241 #endif 1243 #endif
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after
1629 1631
1630 FinishDeletingProfile(profile_to_delete_path, new_active_profile_path); 1632 FinishDeletingProfile(profile_to_delete_path, new_active_profile_path);
1631 if (!original_callback.is_null()) 1633 if (!original_callback.is_null())
1632 original_callback.Run(loaded_profile, status); 1634 original_callback.Run(loaded_profile, status);
1633 } 1635 }
1634 #endif // !defined(OS_ANDROID) 1636 #endif // !defined(OS_ANDROID)
1635 1637
1636 ProfileManagerWithoutInit::ProfileManagerWithoutInit( 1638 ProfileManagerWithoutInit::ProfileManagerWithoutInit(
1637 const base::FilePath& user_data_dir) : ProfileManager(user_data_dir) { 1639 const base::FilePath& user_data_dir) : ProfileManager(user_data_dir) {
1638 } 1640 }
OLDNEW
« no previous file with comments | « chrome/browser/ntp_snippets/ntp_snippets_service_factory.h ('k') | chrome/browser/resources/snippets_internals.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698