From 04d5ed25d82481a7d7a11092aeb289e68915644d Mon Sep 17 00:00:00 2001 From: Patrick Reynolds Date: Wed, 18 Dec 2013 23:13:33 -0600 Subject: [PATCH] call PostClose when notification closed by click --- brightray/browser/linux/notification_presenter_linux.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/brightray/browser/linux/notification_presenter_linux.cc b/brightray/browser/linux/notification_presenter_linux.cc index 6848ce5111c..f4be61af006 100644 --- a/brightray/browser/linux/notification_presenter_linux.cc +++ b/brightray/browser/linux/notification_presenter_linux.cc @@ -32,6 +32,8 @@ void closed_cb(NotifyNotification *notification, NotificationPresenterLinux *obj int render_process_id = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(notification), kRenderProcessIDKey)); int render_view_id = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(notification), kRenderViewIDKey)); int notification_id = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(notification), kNotificationIDKey)); + auto host = content::RenderViewHost::FromID(render_process_id, render_view_id); + if (host) host->DesktopNotificationPostClose(notification_id, false); LOG(INFO) << "closed_cb: process=" << render_process_id << " view=" << render_view_id << " notification=" << notification_id