diff options
5 files changed, 10 insertions, 8 deletions
diff --git a/chrome/browser/bug_report_util.cc b/chrome/browser/bug_report_util.cc index 04db543..6571d95 100644 --- a/chrome/browser/bug_report_util.cc +++ b/chrome/browser/bug_report_util.cc @@ -75,7 +75,7 @@ class FeedbackNotification { IDR_STATUSBAR_FEEDBACK, l10n_util::GetStringUTF16( IDS_BUGREPORT_NOTIFICATION_TITLE))); - notification_->Show(message, urgent); + notification_->Show(message, urgent, false); } private: diff --git a/chrome/browser/chromeos/low_battery_observer.cc b/chrome/browser/chromeos/low_battery_observer.cc index 41f2552..0513cc2 100644 --- a/chrome/browser/chromeos/low_battery_observer.cc +++ b/chrome/browser/chromeos/low_battery_observer.cc @@ -72,7 +72,7 @@ void LowBatteryObserver::PowerChanged(PowerLibrary* object) { void LowBatteryObserver::Show(base::TimeDelta remaining, bool urgent) { notification_.Show(l10n_util::GetStringFUTF16(IDS_LOW_BATTERY_MESSAGE, - TimeFormat::TimeRemaining(remaining)), urgent); + TimeFormat::TimeRemaining(remaining)), urgent, true); remaining_ = remaining.InMinutes(); } @@ -81,4 +81,3 @@ void LowBatteryObserver::Hide() { } } // namespace chromeos - diff --git a/chrome/browser/chromeos/network_message_observer.cc b/chrome/browser/chromeos/network_message_observer.cc index 3c1daca..c87a21b 100644 --- a/chrome/browser/chromeos/network_message_observer.cc +++ b/chrome/browser/chromeos/network_message_observer.cc @@ -118,7 +118,7 @@ void NetworkMessageObserver::NetworkChanged(NetworkLibrary* obj) { notification_.Hide(); notification_.Show(l10n_util::GetStringFUTF16( IDS_NETWORK_CONNECTION_ERROR_MESSAGE, - ASCIIToUTF16(new_failed_network)), false); + ASCIIToUTF16(new_failed_network)), false, true); } // Show login box if necessary. diff --git a/chrome/browser/chromeos/notifications/system_notification.cc b/chrome/browser/chromeos/notifications/system_notification.cc index b4e5d95..28ef884 100644 --- a/chrome/browser/chromeos/notifications/system_notification.cc +++ b/chrome/browser/chromeos/notifications/system_notification.cc @@ -39,7 +39,9 @@ SystemNotification::~SystemNotification() { Hide(); } -void SystemNotification::Show(const string16& message, bool urgent) { +void SystemNotification::Show(const string16& message, + bool urgent, + bool sticky) { Notification notify = SystemNotificationFactory::Create(icon_, title_, message, delegate_.get()); if (visible_) { @@ -50,7 +52,8 @@ void SystemNotification::Show(const string16& message, bool urgent) { collection_->UpdateNotification(notify); } } else { - collection_->AddSystemNotification(notify, profile_, true /* sticky */, + collection_->AddSystemNotification(notify, profile_, + sticky, false /* no controls */); } visible_ = true; diff --git a/chrome/browser/chromeos/notifications/system_notification.h b/chrome/browser/chromeos/notifications/system_notification.h index fdb2afb..a5ac224 100644 --- a/chrome/browser/chromeos/notifications/system_notification.h +++ b/chrome/browser/chromeos/notifications/system_notification.h @@ -30,12 +30,12 @@ class SystemNotification { SystemNotification(Profile* profile, std::string id, int icon_resource_id, string16 title); - ~SystemNotification(); + virtual ~SystemNotification(); // Show will show or update the message for this notification // on a transition to urgent, the notification will be shown if it was // previously hidden or minimized by the user. - void Show(const string16& message, bool urgent); + void Show(const string16& message, bool urgent, bool sticky); // Hide will dismiss the notification, if the notification is already // hidden it does nothing |