Notification: pass tag to Show method
This commit is contained in:
parent
11685faffa
commit
59ed6ad413
8 changed files with 8 additions and 1 deletions
|
@ -88,6 +88,7 @@ LibnotifyNotification::~LibnotifyNotification() {
|
|||
|
||||
void LibnotifyNotification::Show(const base::string16& title,
|
||||
const base::string16& body,
|
||||
const std::string& tag,
|
||||
const GURL& icon_url,
|
||||
const SkBitmap& icon,
|
||||
const bool silent) {
|
||||
|
|
|
@ -22,6 +22,7 @@ class LibnotifyNotification : public Notification {
|
|||
// Notification:
|
||||
void Show(const base::string16& title,
|
||||
const base::string16& msg,
|
||||
const std::string& tag,
|
||||
const GURL& icon_url,
|
||||
const SkBitmap& icon,
|
||||
const bool silent) override;
|
||||
|
|
|
@ -22,6 +22,7 @@ class CocoaNotification : public Notification {
|
|||
// Notification:
|
||||
void Show(const base::string16& title,
|
||||
const base::string16& msg,
|
||||
const std::string& tag,
|
||||
const GURL& icon_url,
|
||||
const SkBitmap& icon,
|
||||
const bool silent) override;
|
||||
|
|
|
@ -30,6 +30,7 @@ CocoaNotification::~CocoaNotification() {
|
|||
|
||||
void CocoaNotification::Show(const base::string16& title,
|
||||
const base::string16& body,
|
||||
const std::string& tag,
|
||||
const GURL& icon_url,
|
||||
const SkBitmap& icon,
|
||||
const bool silent) {
|
||||
|
|
|
@ -21,6 +21,7 @@ class Notification {
|
|||
// Shows the notification.
|
||||
virtual void Show(const base::string16& title,
|
||||
const base::string16& msg,
|
||||
const std::string& tag,
|
||||
const GURL& icon_url,
|
||||
const SkBitmap& icon,
|
||||
const bool silent) = 0;
|
||||
|
|
|
@ -37,7 +37,7 @@ void OnWebNotificationAllowed(
|
|||
auto notification = presenter->CreateNotification(adapter.get());
|
||||
if (notification) {
|
||||
ignore_result(adapter.release()); // it will release itself automatically.
|
||||
notification->Show(data.title, data.body, data.icon, icon, data.silent);
|
||||
notification->Show(data.title, data.body, data.tag, data.icon, icon, data.silent);
|
||||
*cancel_callback = base::Bind(&RemoveNotification, notification);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -84,6 +84,7 @@ WindowsToastNotification::~WindowsToastNotification() {
|
|||
void WindowsToastNotification::Show(
|
||||
const base::string16& title,
|
||||
const base::string16& msg,
|
||||
const std::string& tag,
|
||||
const GURL& icon_url,
|
||||
const SkBitmap& icon,
|
||||
const bool silent) {
|
||||
|
|
|
@ -41,6 +41,7 @@ class WindowsToastNotification : public Notification {
|
|||
// Notification:
|
||||
void Show(const base::string16& title,
|
||||
const base::string16& msg,
|
||||
const std::string& tag,
|
||||
const GURL& icon_url,
|
||||
const SkBitmap& icon,
|
||||
const bool silent) override;
|
||||
|
|
Loading…
Reference in a new issue