| Index: chrome/browser/profiles/profile_impl.cc
|
| diff --git a/chrome/browser/profiles/profile_impl.cc b/chrome/browser/profiles/profile_impl.cc
|
| index 6b8fa17a0ac89e8ed8edf00d2aaffffc06d552b9..b6b66cecf584bbbe249997911c6a80d51528ff12 100644
|
| --- a/chrome/browser/profiles/profile_impl.cc
|
| +++ b/chrome/browser/profiles/profile_impl.cc
|
| @@ -159,6 +159,10 @@ static const char kReadmeText[] =
|
| const char* const kPrefExitTypeCrashed = "Crashed";
|
| const char* const kPrefExitTypeSessionEnded = "SessionEnded";
|
|
|
| +#if defined(OS_WIN)
|
| +const int kCurrentProfileIconVersion = 1;
|
| +#endif
|
| +
|
| // Helper method needed because PostTask cannot currently take a Callback
|
| // function with non-void return type.
|
| void CreateDirectoryAndSignal(const base::FilePath& path,
|
| @@ -733,6 +737,19 @@ void ProfileImpl::OnPrefsLoaded(bool success) {
|
| // Force this to true in case we fallback and use it.
|
| // TODO(sky): remove this in a couple of releases (m28ish).
|
| prefs_->SetBoolean(prefs::kSessionExitedCleanly, true);
|
| +#if defined(OS_WIN)
|
| + if (prefs_->GetInteger(prefs::kProfileIconVersion) <
|
| + kCurrentProfileIconVersion) {
|
| + // Ensure the profile's icon file has been created.
|
| + ProfileShortcutManager* profile_shortcut_manager =
|
| + g_browser_process->profile_manager()->profile_shortcut_manager();
|
| + if (profile_shortcut_manager) {
|
| + profile_shortcut_manager->CreateProfileIcon(GetPath());
|
| + prefs_->SetInteger(prefs::kProfileIconVersion,
|
| + kCurrentProfileIconVersion);
|
| + }
|
| + }
|
| +#endif
|
|
|
| BrowserContextDependencyManager::GetInstance()->CreateBrowserContextServices(
|
| this, false);
|
|
|