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

Side by Side Diff: chrome/browser/ui/auto_login_infobar_delegate.cc

Issue 900733003: Update {virtual,override,final} to follow C++11 style. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 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 unified diff | Download patch
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/ui/auto_login_infobar_delegate.h" 5 #include "chrome/browser/ui/auto_login_infobar_delegate.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/logging.h" 8 #include "base/logging.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "base/metrics/histogram.h" 10 #include "base/metrics/histogram.h"
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 42
43 // This class is created by the AutoLoginInfoBarDelegate when the user wishes to 43 // This class is created by the AutoLoginInfoBarDelegate when the user wishes to
44 // auto-login. It holds context information needed while re-issuing service 44 // auto-login. It holds context information needed while re-issuing service
45 // tokens using the OAuth2TokenService, gets the browser cookies with the 45 // tokens using the OAuth2TokenService, gets the browser cookies with the
46 // TokenAuth API, and finally redirects the user to the correct page. 46 // TokenAuth API, and finally redirects the user to the correct page.
47 class AutoLoginRedirector : public UbertokenConsumer, 47 class AutoLoginRedirector : public UbertokenConsumer,
48 public content::WebContentsObserver { 48 public content::WebContentsObserver {
49 public: 49 public:
50 AutoLoginRedirector(content::WebContents* web_contents, 50 AutoLoginRedirector(content::WebContents* web_contents,
51 const std::string& args); 51 const std::string& args);
52 virtual ~AutoLoginRedirector(); 52 ~AutoLoginRedirector() override;
53 53
54 private: 54 private:
55 // Overriden from UbertokenConsumer: 55 // Overriden from UbertokenConsumer:
56 virtual void OnUbertokenSuccess(const std::string& token) override; 56 void OnUbertokenSuccess(const std::string& token) override;
57 virtual void OnUbertokenFailure(const GoogleServiceAuthError& error) override; 57 void OnUbertokenFailure(const GoogleServiceAuthError& error) override;
58 58
59 // Implementation of content::WebContentsObserver 59 // Implementation of content::WebContentsObserver
60 virtual void WebContentsDestroyed() override; 60 void WebContentsDestroyed() override;
61 61
62 // Redirect tab to MergeSession URL, logging the user in and navigating 62 // Redirect tab to MergeSession URL, logging the user in and navigating
63 // to the desired page. 63 // to the desired page.
64 void RedirectToMergeSession(const std::string& token); 64 void RedirectToMergeSession(const std::string& token);
65 65
66 const std::string args_; 66 const std::string args_;
67 scoped_ptr<UbertokenFetcher> ubertoken_fetcher_; 67 scoped_ptr<UbertokenFetcher> ubertoken_fetcher_;
68 68
69 DISALLOW_COPY_AND_ASSIGN(AutoLoginRedirector); 69 DISALLOW_COPY_AND_ASSIGN(AutoLoginRedirector);
70 }; 70 };
(...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 RecordHistogramAction(REJECTED); 222 RecordHistogramAction(REJECTED);
223 button_pressed_ = true; 223 button_pressed_ = true;
224 return true; 224 return true;
225 } 225 }
226 226
227 void AutoLoginInfoBarDelegate::GoogleSignedOut( 227 void AutoLoginInfoBarDelegate::GoogleSignedOut(
228 const std::string& account_id, 228 const std::string& account_id,
229 const std::string& username) { 229 const std::string& username) {
230 infobar()->RemoveSelf(); 230 infobar()->RemoveSelf();
231 } 231 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/auto_login_infobar_delegate.h ('k') | chrome/browser/ui/screen_capture_notification_ui_stub.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698