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

Unified Diff: chrome/browser/ui/tab_contents/tab_contents_wrapper.cc

Issue 9453035: Implement one click login. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Fixed commentary Created 8 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/tab_contents/tab_contents_wrapper.cc
===================================================================
--- chrome/browser/ui/tab_contents/tab_contents_wrapper.cc (revision 123466)
+++ chrome/browser/ui/tab_contents/tab_contents_wrapper.cc (working copy)
@@ -27,6 +27,8 @@
#include "chrome/browser/printing/print_view_manager.h"
#include "chrome/browser/safe_browsing/safe_browsing_tab_observer.h"
#include "chrome/browser/sessions/restore_tab_helper.h"
+#include "chrome/browser/signin/one_click_signin.h"
+#include "chrome/browser/signin/token_service.h"
#include "chrome/browser/tab_contents/tab_contents_ssl_helper.h"
#include "chrome/browser/tab_contents/thumbnail_generator.h"
#include "chrome/browser/translate/translate_tab_helper.h"
@@ -128,6 +130,13 @@
thumbnail_generation_observer_.reset(new ThumbnailGenerator);
thumbnail_generation_observer_->StartThumbnailing(web_contents_.get());
}
+
+ // If the profile is not already connected to a Google account and this is
+ // not an incognito window, setup to handle one-click login.
+#if !defined(OS_CHROMEOS)
+ if (OneClickSigninManager::CanOffer(contents))
+ one_click_signin_manager_.reset(new OneClickSigninManager(contents));
+#endif
}
TabContentsWrapper::~TabContentsWrapper() {

Powered by Google App Engine
This is Rietveld 408576698