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

Side by Side Diff: chrome/browser/supervised_user/supervised_user_navigation_observer.cc

Issue 629603002: replace OVERRIDE and FINAL with override and final in chrome/browser/[r-z]* (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase on master Created 6 years, 2 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/supervised_user/supervised_user_navigation_observer.h" 5 #include "chrome/browser/supervised_user/supervised_user_navigation_observer.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/callback.h" 8 #include "base/callback.h"
9 #include "base/metrics/histogram.h" 9 #include "base/metrics/histogram.h"
10 #include "base/strings/string_util.h" 10 #include "base/strings/string_util.h"
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 public: 81 public:
82 // Creates a supervised user warning infobar and delegate and adds the infobar 82 // Creates a supervised user warning infobar and delegate and adds the infobar
83 // to |infobar_service|. Returns the infobar if it was successfully added. 83 // to |infobar_service|. Returns the infobar if it was successfully added.
84 static infobars::InfoBar* Create(InfoBarService* infobar_service); 84 static infobars::InfoBar* Create(InfoBarService* infobar_service);
85 85
86 private: 86 private:
87 SupervisedUserWarningInfoBarDelegate(); 87 SupervisedUserWarningInfoBarDelegate();
88 virtual ~SupervisedUserWarningInfoBarDelegate(); 88 virtual ~SupervisedUserWarningInfoBarDelegate();
89 89
90 // ConfirmInfoBarDelegate: 90 // ConfirmInfoBarDelegate:
91 virtual bool ShouldExpire(const NavigationDetails& details) const OVERRIDE; 91 virtual bool ShouldExpire(const NavigationDetails& details) const override;
92 virtual void InfoBarDismissed() OVERRIDE; 92 virtual void InfoBarDismissed() override;
93 virtual base::string16 GetMessageText() const OVERRIDE; 93 virtual base::string16 GetMessageText() const override;
94 virtual int GetButtons() const OVERRIDE; 94 virtual int GetButtons() const override;
95 virtual base::string16 GetButtonLabel(InfoBarButton button) const OVERRIDE; 95 virtual base::string16 GetButtonLabel(InfoBarButton button) const override;
96 virtual bool Accept() OVERRIDE; 96 virtual bool Accept() override;
97 97
98 DISALLOW_COPY_AND_ASSIGN(SupervisedUserWarningInfoBarDelegate); 98 DISALLOW_COPY_AND_ASSIGN(SupervisedUserWarningInfoBarDelegate);
99 }; 99 };
100 100
101 // static 101 // static
102 infobars::InfoBar* SupervisedUserWarningInfoBarDelegate::Create( 102 infobars::InfoBar* SupervisedUserWarningInfoBarDelegate::Create(
103 InfoBarService* infobar_service) { 103 InfoBarService* infobar_service) {
104 return infobar_service->AddInfoBar(ConfirmInfoBarDelegate::CreateInfoBar( 104 return infobar_service->AddInfoBar(ConfirmInfoBarDelegate::CreateInfoBar(
105 scoped_ptr<ConfirmInfoBarDelegate>( 105 scoped_ptr<ConfirmInfoBarDelegate>(
106 new SupervisedUserWarningInfoBarDelegate()))); 106 new SupervisedUserWarningInfoBarDelegate())));
(...skipping 136 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 history_service->AddPage(add_page_args); 243 history_service->AddPage(add_page_args);
244 244
245 scoped_ptr<NavigationEntry> entry(NavigationEntry::Create()); 245 scoped_ptr<NavigationEntry> entry(NavigationEntry::Create());
246 entry->SetVirtualURL(url); 246 entry->SetVirtualURL(url);
247 entry->SetTimestamp(timestamp); 247 entry->SetTimestamp(timestamp);
248 blocked_navigations_.push_back(entry.release()); 248 blocked_navigations_.push_back(entry.release());
249 SupervisedUserService* supervised_user_service = 249 SupervisedUserService* supervised_user_service =
250 SupervisedUserServiceFactory::GetForProfile(profile); 250 SupervisedUserServiceFactory::GetForProfile(profile);
251 supervised_user_service->DidBlockNavigation(web_contents()); 251 supervised_user_service->DidBlockNavigation(web_contents());
252 } 252 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698