summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpeter <peter@chromium.org>2014-10-30 16:19:19 -0700
committerCommit bot <commit-bot@chromium.org>2014-10-30 23:19:57 +0000
commitcf29ede833a3acda53607f9050612bafe52f2321 (patch)
tree314f068ab38d23a4877554c366db2e384f4c63c2
parent50abe634af1d1aa8600dffaaabb15f3f35338fd6 (diff)
downloadchromium_src-cf29ede833a3acda53607f9050612bafe52f2321.zip
chromium_src-cf29ede833a3acda53607f9050612bafe52f2321.tar.gz
chromium_src-cf29ede833a3acda53607f9050612bafe52f2321.tar.bz2
Provide default implementations for NotificationDelegate methods.
Many implementations of the NotificationDelegate include empty overrides because of behavior they don't actually need to be informed of. Provide empty default implementations so that they don't have to. (And remove the associated TODO.) BUG=428370 Review URL: https://codereview.chromium.org/684253002 Cr-Commit-Position: refs/heads/master@{#302190}
-rw-r--r--ash/display/resolution_notification_controller.cc8
-rw-r--r--ash/system/chromeos/bluetooth/bluetooth_notification_controller.cc21
-rw-r--r--ash/system/chromeos/screen_security/screen_tray_item.cc12
-rw-r--r--ash/system/chromeos/screen_security/screen_tray_item.h4
-rw-r--r--ash/system/locale/locale_notification_controller.cc8
-rw-r--r--chrome/browser/background/background_contents_service.cc6
-rw-r--r--chrome/browser/chromeos/file_system_provider/notification_manager.cc4
-rw-r--r--chrome/browser/chromeos/first_run/drive_first_run_controller.cc4
-rw-r--r--chrome/browser/chromeos/policy/consumer_enrollment_handler.cc16
-rw-r--r--chrome/browser/chromeos/power/peripheral_battery_observer.cc4
-rw-r--r--chrome/browser/extensions/api/notifications/notifications_api.cc4
-rw-r--r--chrome/browser/local_discovery/privet_notifications.cc9
-rw-r--r--chrome/browser/local_discovery/privet_notifications.h3
-rw-r--r--chrome/browser/notifications/extension_welcome_notification.cc4
-rw-r--r--chrome/browser/notifications/extension_welcome_notification_unittest.cc6
-rw-r--r--chrome/browser/notifications/notification_test_util.h4
-rw-r--r--chrome/browser/signin/signin_error_notifier_ash.cc17
-rw-r--r--chrome/browser/status_icons/desktop_notification_balloon.cc3
-rw-r--r--chrome/browser/sync/sync_error_notifier_ash.cc18
-rw-r--r--chrome/browser/ui/ash/screenshot_taker.cc3
-rw-r--r--chrome/browser/ui/views/message_center/web_notification_tray_browsertest.cc4
-rw-r--r--ui/message_center/notification_delegate.cc38
-rw-r--r--ui/message_center/notification_delegate.h22
23 files changed, 18 insertions, 204 deletions
diff --git a/ash/display/resolution_notification_controller.cc b/ash/display/resolution_notification_controller.cc
index 35ee07b..82de8e03 100644
--- a/ash/display/resolution_notification_controller.cc
+++ b/ash/display/resolution_notification_controller.cc
@@ -40,8 +40,6 @@ class ResolutionChangeNotificationDelegate
private:
// message_center::NotificationDelegate overrides:
- virtual void Display() override;
- virtual void Error() override;
virtual void Close(bool by_user) override;
virtual void Click() override;
virtual bool HasClickedListener() override;
@@ -64,12 +62,6 @@ ResolutionChangeNotificationDelegate::ResolutionChangeNotificationDelegate(
ResolutionChangeNotificationDelegate::~ResolutionChangeNotificationDelegate() {
}
-void ResolutionChangeNotificationDelegate::Display() {
-}
-
-void ResolutionChangeNotificationDelegate::Error() {
-}
-
void ResolutionChangeNotificationDelegate::Close(bool by_user) {
if (by_user)
controller_->AcceptResolutionChange(false);
diff --git a/ash/system/chromeos/bluetooth/bluetooth_notification_controller.cc b/ash/system/chromeos/bluetooth/bluetooth_notification_controller.cc
index e64bc77..146be2c 100644
--- a/ash/system/chromeos/bluetooth/bluetooth_notification_controller.cc
+++ b/ash/system/chromeos/bluetooth/bluetooth_notification_controller.cc
@@ -58,12 +58,8 @@ class BluetoothPairingNotificationDelegate
virtual ~BluetoothPairingNotificationDelegate();
// message_center::NotificationDelegate overrides.
- virtual void Display() override;
- virtual void Error() override;
- virtual void Close(bool by_user) override;
- virtual bool HasClickedListener() override;
- virtual void Click() override;
- virtual void ButtonClick(int button_index) override;
+ void Close(bool by_user) override;
+ void ButtonClick(int button_index) override;
private:
// Buttons that appear in notifications.
@@ -93,12 +89,6 @@ BluetoothPairingNotificationDelegate::BluetoothPairingNotificationDelegate(
BluetoothPairingNotificationDelegate::~BluetoothPairingNotificationDelegate() {
}
-void BluetoothPairingNotificationDelegate::Display() {
-}
-
-void BluetoothPairingNotificationDelegate::Error() {
-}
-
void BluetoothPairingNotificationDelegate::Close(bool by_user) {
VLOG(1) << "Pairing notification closed. by_user = " << by_user;
// Ignore notification closes generated as a result of pairing completion.
@@ -111,13 +101,6 @@ void BluetoothPairingNotificationDelegate::Close(bool by_user) {
device->CancelPairing();
}
-bool BluetoothPairingNotificationDelegate::HasClickedListener() {
- return false;
-}
-
-void BluetoothPairingNotificationDelegate::Click() {
-}
-
void BluetoothPairingNotificationDelegate::ButtonClick(int button_index) {
VLOG(1) << "Pairing notification, button click: " << button_index;
// If the device object still exists, send the appropriate response either
diff --git a/ash/system/chromeos/screen_security/screen_tray_item.cc b/ash/system/chromeos/screen_security/screen_tray_item.cc
index f6ac38c..2b3667d 100644
--- a/ash/system/chromeos/screen_security/screen_tray_item.cc
+++ b/ash/system/chromeos/screen_security/screen_tray_item.cc
@@ -116,18 +116,6 @@ ScreenNotificationDelegate::ScreenNotificationDelegate(
ScreenNotificationDelegate::~ScreenNotificationDelegate() {
}
-void ScreenNotificationDelegate::Display() {
-}
-
-void ScreenNotificationDelegate::Error() {
-}
-
-void ScreenNotificationDelegate::Close(bool by_user) {
-}
-
-void ScreenNotificationDelegate::Click() {
-}
-
void ScreenNotificationDelegate::ButtonClick(int button_index) {
DCHECK_EQ(0, button_index);
screen_tray_->Stop();
diff --git a/ash/system/chromeos/screen_security/screen_tray_item.h b/ash/system/chromeos/screen_security/screen_tray_item.h
index 1cf9a68..59e0d35 100644
--- a/ash/system/chromeos/screen_security/screen_tray_item.h
+++ b/ash/system/chromeos/screen_security/screen_tray_item.h
@@ -73,10 +73,6 @@ class ScreenNotificationDelegate : public message_center::NotificationDelegate {
explicit ScreenNotificationDelegate(ScreenTrayItem* screen_tray);
// message_center::NotificationDelegate overrides:
- virtual void Display() override;
- virtual void Error() override;
- virtual void Close(bool by_user) override;
- virtual void Click() override;
virtual void ButtonClick(int button_index) override;
protected:
diff --git a/ash/system/locale/locale_notification_controller.cc b/ash/system/locale/locale_notification_controller.cc
index 63a4210..20351ad 100644
--- a/ash/system/locale/locale_notification_controller.cc
+++ b/ash/system/locale/locale_notification_controller.cc
@@ -32,8 +32,6 @@ class LocaleNotificationDelegate : public message_center::NotificationDelegate {
~LocaleNotificationDelegate() override;
// message_center::NotificationDelegate overrides:
- void Display() override;
- void Error() override;
void Close(bool by_user) override;
bool HasClickedListener() override;
void Click() override;
@@ -54,12 +52,6 @@ LocaleNotificationDelegate::LocaleNotificationDelegate(
LocaleNotificationDelegate::~LocaleNotificationDelegate() {
}
-void LocaleNotificationDelegate::Display() {
-}
-
-void LocaleNotificationDelegate::Error() {
-}
-
void LocaleNotificationDelegate::Close(bool by_user) {
delegate_->AcceptLocaleChange();
}
diff --git a/chrome/browser/background/background_contents_service.cc b/chrome/browser/background/background_contents_service.cc
index 016e429..3b87006 100644
--- a/chrome/browser/background/background_contents_service.cc
+++ b/chrome/browser/background/background_contents_service.cc
@@ -104,12 +104,6 @@ class CrashNotificationDelegate : public NotificationDelegate {
extension_id_(extension->id()) {
}
- void Display() override {}
-
- void Error() override {}
-
- void Close(bool by_user) override {}
-
void Click() override {
// http://crbug.com/247790 involves a crash notification balloon being
// clicked while the extension isn't in the TERMINATED state. In that case,
diff --git a/chrome/browser/chromeos/file_system_provider/notification_manager.cc b/chrome/browser/chromeos/file_system_provider/notification_manager.cc
index 487e68a..db0a03b 100644
--- a/chrome/browser/chromeos/file_system_provider/notification_manager.cc
+++ b/chrome/browser/chromeos/file_system_provider/notification_manager.cc
@@ -36,16 +36,12 @@ class ProviderNotificationDelegate
notification_manager_->OnButtonClick(button_index);
}
- virtual void Display() override {}
-
virtual void Error() override { notification_manager_->OnError(); }
virtual void Close(bool by_user) override {
notification_manager_->OnClose();
}
- virtual void Click() override {}
-
private:
virtual ~ProviderNotificationDelegate() {}
NotificationManager* notification_manager_; // Not owned.
diff --git a/chrome/browser/chromeos/first_run/drive_first_run_controller.cc b/chrome/browser/chromeos/first_run/drive_first_run_controller.cc
index 5154e08..29271ed 100644
--- a/chrome/browser/chromeos/first_run/drive_first_run_controller.cc
+++ b/chrome/browser/chromeos/first_run/drive_first_run_controller.cc
@@ -85,10 +85,6 @@ class DriveOfflineNotificationDelegate
: profile_(profile) {}
// message_center::NotificationDelegate overrides:
- virtual void Display() override {}
- virtual void Error() override {}
- virtual void Close(bool by_user) override {}
- virtual void Click() override {}
virtual void ButtonClick(int button_index) override;
protected:
diff --git a/chrome/browser/chromeos/policy/consumer_enrollment_handler.cc b/chrome/browser/chromeos/policy/consumer_enrollment_handler.cc
index aa1238e..97c29709 100644
--- a/chrome/browser/chromeos/policy/consumer_enrollment_handler.cc
+++ b/chrome/browser/chromeos/policy/consumer_enrollment_handler.cc
@@ -75,11 +75,7 @@ class DesktopNotificationDelegate : public NotificationDelegate {
// NotificationDelegate:
virtual std::string id() const override;
- virtual void Display() override;
virtual void ButtonClick(int button_index) override;
- virtual void Error() override;
- virtual void Close(bool by_user) override;
- virtual void Click() override;
private:
virtual ~DesktopNotificationDelegate();
@@ -103,22 +99,10 @@ std::string DesktopNotificationDelegate::id() const {
return id_;
}
-void DesktopNotificationDelegate::Display() {
-}
-
void DesktopNotificationDelegate::ButtonClick(int button_index) {
button_click_callback_.Run();
}
-void DesktopNotificationDelegate::Error() {
-}
-
-void DesktopNotificationDelegate::Close(bool by_user) {
-}
-
-void DesktopNotificationDelegate::Click() {
-}
-
} // namespace
namespace policy {
diff --git a/chrome/browser/chromeos/power/peripheral_battery_observer.cc b/chrome/browser/chromeos/power/peripheral_battery_observer.cc
index 2c6cf5a..36385a3 100644
--- a/chrome/browser/chromeos/power/peripheral_battery_observer.cc
+++ b/chrome/browser/chromeos/power/peripheral_battery_observer.cc
@@ -74,10 +74,6 @@ class PeripheralBatteryNotificationDelegate : public NotificationDelegate {
: id_(id) {}
// Overridden from NotificationDelegate:
- virtual void Display() override {}
- virtual void Error() override {}
- virtual void Close(bool by_user) override {}
- virtual void Click() override {}
virtual std::string id() const override { return id_; }
private:
diff --git a/chrome/browser/extensions/api/notifications/notifications_api.cc b/chrome/browser/extensions/api/notifications/notifications_api.cc
index 5350ba4..3830a7c 100644
--- a/chrome/browser/extensions/api/notifications/notifications_api.cc
+++ b/chrome/browser/extensions/api/notifications/notifications_api.cc
@@ -85,10 +85,6 @@ class NotificationsApiDelegate : public NotificationDelegate {
DCHECK(api_function_.get());
}
- void Display() override {}
-
- void Error() override {}
-
void Close(bool by_user) override {
EventRouter::UserGestureState gesture =
by_user ? EventRouter::USER_GESTURE_ENABLED
diff --git a/chrome/browser/local_discovery/privet_notifications.cc b/chrome/browser/local_discovery/privet_notifications.cc
index cc7d65b..d308441 100644
--- a/chrome/browser/local_discovery/privet_notifications.cc
+++ b/chrome/browser/local_discovery/privet_notifications.cc
@@ -370,19 +370,10 @@ std::string PrivetNotificationDelegate::id() const {
return kPrivetNotificationID;
}
-void PrivetNotificationDelegate::Display() {
-}
-
void PrivetNotificationDelegate::Error() {
LOG(ERROR) << "Error displaying privet notification";
}
-void PrivetNotificationDelegate::Close(bool by_user) {
-}
-
-void PrivetNotificationDelegate::Click() {
-}
-
void PrivetNotificationDelegate::ButtonClick(int button_index) {
if (button_index == 0) {
ReportPrivetUmaEvent(PRIVET_NOTIFICATION_CLICKED);
diff --git a/chrome/browser/local_discovery/privet_notifications.h b/chrome/browser/local_discovery/privet_notifications.h
index f71f71b..974ab9b 100644
--- a/chrome/browser/local_discovery/privet_notifications.h
+++ b/chrome/browser/local_discovery/privet_notifications.h
@@ -134,10 +134,7 @@ class PrivetNotificationDelegate : public NotificationDelegate {
// NotificationDelegate implementation.
std::string id() const override;
- void Display() override;
void Error() override;
- void Close(bool by_user) override;
- void Click() override;
void ButtonClick(int button_index) override;
private:
diff --git a/chrome/browser/notifications/extension_welcome_notification.cc b/chrome/browser/notifications/extension_welcome_notification.cc
index c061dd8..335ebb8 100644
--- a/chrome/browser/notifications/extension_welcome_notification.cc
+++ b/chrome/browser/notifications/extension_welcome_notification.cc
@@ -47,9 +47,6 @@ class NotificationCallbacks
}
// Overridden from NotificationDelegate:
- void Display() override {}
- void Error() override {}
-
void Close(bool by_user) override {
if (by_user) {
// Setting the preference here may cause the notification erasing
@@ -60,7 +57,6 @@ class NotificationCallbacks
}
}
- void Click() override {}
void ButtonClick(int index) override {
if (index == 0) {
OpenNotificationLearnMoreTab();
diff --git a/chrome/browser/notifications/extension_welcome_notification_unittest.cc b/chrome/browser/notifications/extension_welcome_notification_unittest.cc
index d4ecf2d..ce5c40f 100644
--- a/chrome/browser/notifications/extension_welcome_notification_unittest.cc
+++ b/chrome/browser/notifications/extension_welcome_notification_unittest.cc
@@ -205,12 +205,6 @@ class ExtensionWelcomeNotificationTest : public testing::Test {
explicit TestNotificationDelegate(const std::string& id) : id_(id) {}
// Overridden from NotificationDelegate:
- void Display() override {}
- void Error() override {}
- void Close(bool by_user) override {}
- void Click() override {}
- void ButtonClick(int index) override {}
-
std::string id() const override { return id_; }
private:
diff --git a/chrome/browser/notifications/notification_test_util.h b/chrome/browser/notifications/notification_test_util.h
index eba7834..1ad1b76 100644
--- a/chrome/browser/notifications/notification_test_util.h
+++ b/chrome/browser/notifications/notification_test_util.h
@@ -22,10 +22,6 @@ class MockNotificationDelegate : public NotificationDelegate {
explicit MockNotificationDelegate(const std::string& id);
// NotificationDelegate interface.
- void Display() override {}
- void Error() override {}
- void Close(bool by_user) override {}
- void Click() override {}
std::string id() const override;
private:
diff --git a/chrome/browser/signin/signin_error_notifier_ash.cc b/chrome/browser/signin/signin_error_notifier_ash.cc
index d1f9f58..a7d663e 100644
--- a/chrome/browser/signin/signin_error_notifier_ash.cc
+++ b/chrome/browser/signin/signin_error_notifier_ash.cc
@@ -50,10 +50,6 @@ class SigninNotificationDelegate : public NotificationDelegate {
Profile* profile);
// NotificationDelegate:
- void Display() override;
- void Error() override;
- void Close(bool by_user) override;
- bool HasClickedListener() override;
void Click() override;
void ButtonClick(int button_index) override;
std::string id() const override;
@@ -82,19 +78,6 @@ SigninNotificationDelegate::SigninNotificationDelegate(
SigninNotificationDelegate::~SigninNotificationDelegate() {
}
-void SigninNotificationDelegate::Display() {
-}
-
-void SigninNotificationDelegate::Error() {
-}
-
-void SigninNotificationDelegate::Close(bool by_user) {
-}
-
-bool SigninNotificationDelegate::HasClickedListener() {
- return false;
-}
-
void SigninNotificationDelegate::Click() {
FixSignIn();
}
diff --git a/chrome/browser/status_icons/desktop_notification_balloon.cc b/chrome/browser/status_icons/desktop_notification_balloon.cc
index 25162b3..1974b64 100644
--- a/chrome/browser/status_icons/desktop_notification_balloon.cc
+++ b/chrome/browser/status_icons/desktop_notification_balloon.cc
@@ -45,9 +45,6 @@ class DummyNotificationDelegate : public NotificationDelegate {
&CloseBalloon, id(), NotificationUIManager::GetProfileID(profile_)),
base::TimeDelta::FromSeconds(kTimeoutSeconds));
}
- void Error() override {}
- void Close(bool by_user) override {}
- void Click() override {}
std::string id() const override { return id_; }
private:
diff --git a/chrome/browser/sync/sync_error_notifier_ash.cc b/chrome/browser/sync/sync_error_notifier_ash.cc
index 01e5dd2..4af01aa 100644
--- a/chrome/browser/sync/sync_error_notifier_ash.cc
+++ b/chrome/browser/sync/sync_error_notifier_ash.cc
@@ -45,10 +45,6 @@ class SyncNotificationDelegate : public NotificationDelegate {
Profile* profile);
// NotificationDelegate:
- void Display() override;
- void Error() override;
- void Close(bool by_user) override;
- bool HasClickedListener() override;
void Click() override;
void ButtonClick(int button_index) override;
std::string id() const override;
@@ -76,20 +72,6 @@ SyncNotificationDelegate::SyncNotificationDelegate(
SyncNotificationDelegate::~SyncNotificationDelegate() {
}
-
-void SyncNotificationDelegate::Display() {
-}
-
-void SyncNotificationDelegate::Error() {
-}
-
-void SyncNotificationDelegate::Close(bool by_user) {
-}
-
-bool SyncNotificationDelegate::HasClickedListener() {
- return false;
-}
-
void SyncNotificationDelegate::Click() {
ShowSyncSetup();
}
diff --git a/chrome/browser/ui/ash/screenshot_taker.cc b/chrome/browser/ui/ash/screenshot_taker.cc
index 0f6dfd7..6cac097 100644
--- a/chrome/browser/ui/ash/screenshot_taker.cc
+++ b/chrome/browser/ui/ash/screenshot_taker.cc
@@ -127,9 +127,6 @@ class ScreenshotTakerNotificationDelegate : public NotificationDelegate {
}
// Overridden from NotificationDelegate:
- void Display() override {}
- void Error() override {}
- void Close(bool by_user) override {}
void Click() override {
if (!success_)
return;
diff --git a/chrome/browser/ui/views/message_center/web_notification_tray_browsertest.cc b/chrome/browser/ui/views/message_center/web_notification_tray_browsertest.cc
index b3d5fd1..5e8ea3b 100644
--- a/chrome/browser/ui/views/message_center/web_notification_tray_browsertest.cc
+++ b/chrome/browser/ui/views/message_center/web_notification_tray_browsertest.cc
@@ -47,10 +47,6 @@ class WebNotificationTrayTest : public InProcessBrowserTest {
class TestNotificationDelegate : public ::NotificationDelegate {
public:
explicit TestNotificationDelegate(std::string id) : id_(id) {}
- void Display() override {}
- void Error() override {}
- void Close(bool by_user) override {}
- void Click() override {}
std::string id() const override { return id_; }
private:
diff --git a/ui/message_center/notification_delegate.cc b/ui/message_center/notification_delegate.cc
index 09ef959..8d23bb5 100644
--- a/ui/message_center/notification_delegate.cc
+++ b/ui/message_center/notification_delegate.cc
@@ -8,8 +8,16 @@ namespace message_center {
// NotificationDelegate:
+void NotificationDelegate::Display() {}
+
+void NotificationDelegate::Error() {}
+
+void NotificationDelegate::Close(bool by_user) {}
+
bool NotificationDelegate::HasClickedListener() { return false; }
+void NotificationDelegate::Click() {}
+
void NotificationDelegate::ButtonClick(int button_index) {}
// HandleNotificationClickedDelegate:
@@ -19,17 +27,7 @@ HandleNotificationClickedDelegate::HandleNotificationClickedDelegate(
: closure_(closure) {
}
-HandleNotificationClickedDelegate::~HandleNotificationClickedDelegate() {
-}
-
-void HandleNotificationClickedDelegate::Display() {
-}
-
-void HandleNotificationClickedDelegate::Error() {
-}
-
-void HandleNotificationClickedDelegate::Close(bool by_user) {
-}
+HandleNotificationClickedDelegate::~HandleNotificationClickedDelegate() {}
bool HandleNotificationClickedDelegate::HasClickedListener() {
return !closure_.is_null();
@@ -40,9 +38,6 @@ void HandleNotificationClickedDelegate::Click() {
closure_.Run();
}
-void HandleNotificationClickedDelegate::ButtonClick(int button_index) {
-}
-
// HandleNotificationButtonClickDelegate:
HandleNotificationButtonClickDelegate::HandleNotificationButtonClickDelegate(
@@ -51,20 +46,7 @@ HandleNotificationButtonClickDelegate::HandleNotificationButtonClickDelegate(
}
HandleNotificationButtonClickDelegate::
- ~HandleNotificationButtonClickDelegate() {
-}
-
-void HandleNotificationButtonClickDelegate::Display() {
-}
-
-void HandleNotificationButtonClickDelegate::Error() {
-}
-
-void HandleNotificationButtonClickDelegate::Close(bool by_user) {
-}
-
-void HandleNotificationButtonClickDelegate::Click() {
-}
+ ~HandleNotificationButtonClickDelegate() {}
void HandleNotificationButtonClickDelegate::ButtonClick(int button_index) {
if (!button_callback_.is_null())
diff --git a/ui/message_center/notification_delegate.h b/ui/message_center/notification_delegate.h
index f870fcb..93526ba 100644
--- a/ui/message_center/notification_delegate.h
+++ b/ui/message_center/notification_delegate.h
@@ -24,25 +24,23 @@ class MESSAGE_CENTER_EXPORT NotificationDelegate
: public base::RefCountedThreadSafe<NotificationDelegate> {
public:
// To be called when the desktop notification is actually shown.
- virtual void Display() = 0;
+ virtual void Display();
// To be called when the desktop notification cannot be shown due to an
// error.
- virtual void Error() = 0;
+ virtual void Error();
// To be called when the desktop notification is closed. If closed by a
// user explicitly (as opposed to timeout/script), |by_user| should be true.
- virtual void Close(bool by_user) = 0;
+ virtual void Close(bool by_user);
// Returns true if the delegate can handle click event.
virtual bool HasClickedListener();
// To be called when a desktop notification is clicked.
- virtual void Click() = 0;
+ virtual void Click();
- // To be called when the user clicks a button in a notification. TODO(miket):
- // consider providing default implementations of the pure virtuals of this
- // interface, to avoid pinging so many OWNERs each time we enhance it.
+ // To be called when the user clicks a button in a notification.
virtual void ButtonClick(int button_index);
protected:
@@ -59,12 +57,8 @@ class MESSAGE_CENTER_EXPORT HandleNotificationClickedDelegate
explicit HandleNotificationClickedDelegate(const base::Closure& closure);
// message_center::NotificationDelegate overrides:
- void Display() override;
- void Error() override;
- void Close(bool by_user) override;
- bool HasClickedListener() override;
void Click() override;
- void ButtonClick(int button_index) override;
+ bool HasClickedListener() override;
protected:
~HandleNotificationClickedDelegate() override;
@@ -87,10 +81,6 @@ class MESSAGE_CENTER_EXPORT HandleNotificationButtonClickDelegate
const ButtonClickCallback& button_callback);
// message_center::NotificationDelegate overrides:
- void Display() override;
- void Error() override;
- void Close(bool by_user) override;
- void Click() override;
void ButtonClick(int button_index) override;
protected: