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

Side by Side Diff: chrome/browser/status_icons/desktop_notification_balloon.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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/status_icons/desktop_notification_balloon.h" 5 #include "chrome/browser/status_icons/desktop_notification_balloon.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/strings/string_number_conversions.h" 8 #include "base/strings/string_number_conversions.h"
9 #include "base/threading/thread_restrictions.h" 9 #include "base/threading/thread_restrictions.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 20 matching lines...) Expand all
31 const char kNotificationPrefix[] = "desktop_notification_balloon."; 31 const char kNotificationPrefix[] = "desktop_notification_balloon.";
32 32
33 // Timeout for automatically dismissing the notification balloon. 33 // Timeout for automatically dismissing the notification balloon.
34 const size_t kTimeoutSeconds = 6; 34 const size_t kTimeoutSeconds = 6;
35 35
36 class DummyNotificationDelegate : public NotificationDelegate { 36 class DummyNotificationDelegate : public NotificationDelegate {
37 public: 37 public:
38 explicit DummyNotificationDelegate(const std::string& id, Profile* profile) 38 explicit DummyNotificationDelegate(const std::string& id, Profile* profile)
39 : id_(kNotificationPrefix + id), profile_(profile) {} 39 : id_(kNotificationPrefix + id), profile_(profile) {}
40 40
41 virtual void Display() OVERRIDE { 41 virtual void Display() override {
42 base::MessageLoop::current()->PostDelayedTask( 42 base::MessageLoop::current()->PostDelayedTask(
43 FROM_HERE, 43 FROM_HERE,
44 base::Bind( 44 base::Bind(
45 &CloseBalloon, id(), NotificationUIManager::GetProfileID(profile_)), 45 &CloseBalloon, id(), NotificationUIManager::GetProfileID(profile_)),
46 base::TimeDelta::FromSeconds(kTimeoutSeconds)); 46 base::TimeDelta::FromSeconds(kTimeoutSeconds));
47 } 47 }
48 virtual void Error() OVERRIDE {} 48 virtual void Error() override {}
49 virtual void Close(bool by_user) OVERRIDE {} 49 virtual void Close(bool by_user) override {}
50 virtual void Click() OVERRIDE {} 50 virtual void Click() override {}
51 virtual std::string id() const OVERRIDE { return id_; } 51 virtual std::string id() const override { return id_; }
52 virtual content::WebContents* GetWebContents() const OVERRIDE { 52 virtual content::WebContents* GetWebContents() const override {
53 return NULL; 53 return NULL;
54 } 54 }
55 55
56 private: 56 private:
57 virtual ~DummyNotificationDelegate() {} 57 virtual ~DummyNotificationDelegate() {}
58 58
59 std::string id_; 59 std::string id_;
60 Profile* profile_; 60 Profile* profile_;
61 }; 61 };
62 62
(...skipping 25 matching lines...) Expand all
88 notification_id_ = DesktopNotificationService::AddIconNotification( 88 notification_id_ = DesktopNotificationService::AddIconNotification(
89 GURL(), 89 GURL(),
90 title, 90 title,
91 contents, 91 contents,
92 gfx::Image(icon), 92 gfx::Image(icon),
93 base::string16(), 93 base::string16(),
94 new DummyNotificationDelegate(base::IntToString(id_count_++), profile_), 94 new DummyNotificationDelegate(base::IntToString(id_count_++), profile_),
95 profile); 95 profile);
96 profile_ = profile; 96 profile_ = profile;
97 } 97 }
OLDNEW
« no previous file with comments | « chrome/browser/ssl/ssl_error_classification.h ('k') | chrome/browser/status_icons/status_icon_menu_model.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698