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

Side by Side Diff: chrome/browser/chromeos/login/session/user_session_manager.cc

Issue 1818823004: Merge cros: Fix unexpected cryptohome failure UI (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2661
Patch Set: Created 4 years, 9 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/chromeos/login/session/user_session_manager.h" 5 #include "chrome/browser/chromeos/login/session/user_session_manager.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 1737 matching lines...) Expand 10 before | Expand all | Expand 10 after
1748 else 1748 else
1749 display = USER_PODS_DISPLAY_DISABLED_REGULAR; 1749 display = USER_PODS_DISPLAY_DISABLED_REGULAR;
1750 } 1750 }
1751 UMA_HISTOGRAM_ENUMERATION("UserSessionManager.UserPodsDisplay", display, 1751 UMA_HISTOGRAM_ENUMERATION("UserSessionManager.UserPodsDisplay", display,
1752 NUM_USER_PODS_DISPLAY); 1752 NUM_USER_PODS_DISPLAY);
1753 } 1753 }
1754 1754
1755 void UserSessionManager::OnOAuth2TokensFetched(UserContext context) { 1755 void UserSessionManager::OnOAuth2TokensFetched(UserContext context) {
1756 if (StartupUtils::IsWebviewSigninEnabled() && TokenHandlesEnabled()) { 1756 if (StartupUtils::IsWebviewSigninEnabled() && TokenHandlesEnabled()) {
1757 CreateTokenUtilIfMissing(); 1757 CreateTokenUtilIfMissing();
1758 if (token_handle_util_->ShouldObtainHandle(context.GetAccountId())) { 1758 if (!token_handle_util_->HasToken(context.GetAccountId())) {
1759 token_handle_fetcher_.reset(new TokenHandleFetcher( 1759 token_handle_fetcher_.reset(new TokenHandleFetcher(
1760 token_handle_util_.get(), context.GetAccountId())); 1760 token_handle_util_.get(), context.GetAccountId()));
1761 token_handle_fetcher_->FillForNewUser( 1761 token_handle_fetcher_->FillForNewUser(
1762 context.GetAccessToken(), 1762 context.GetAccessToken(),
1763 base::Bind(&UserSessionManager::OnTokenHandleObtained, 1763 base::Bind(&UserSessionManager::OnTokenHandleObtained,
1764 weak_factory_.GetWeakPtr())); 1764 weak_factory_.GetWeakPtr()));
1765 } 1765 }
1766 } 1766 }
1767 } 1767 }
1768 1768
(...skipping 27 matching lines...) Expand all
1796 token_handle_util_.reset(); 1796 token_handle_util_.reset();
1797 first_run::GoodiesDisplayer::Delete(); 1797 first_run::GoodiesDisplayer::Delete();
1798 } 1798 }
1799 1799
1800 void UserSessionManager::CreateTokenUtilIfMissing() { 1800 void UserSessionManager::CreateTokenUtilIfMissing() {
1801 if (!token_handle_util_.get()) 1801 if (!token_handle_util_.get())
1802 token_handle_util_.reset(new TokenHandleUtil()); 1802 token_handle_util_.reset(new TokenHandleUtil());
1803 } 1803 }
1804 1804
1805 } // namespace chromeos 1805 } // namespace chromeos
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698