From a12eb8ee53a67f98a2412d055e1708e1fe71c4c5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Danielle=20For=C3=A9?= Date: Thu, 3 Sep 2026 15:01:45 -0700 Subject: [PATCH 1/2] NotificationList: find notification when removing, not entry --- src/Widgets/NotificationsList.vala | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/Widgets/NotificationsList.vala b/src/Widgets/NotificationsList.vala index d47b7c0b..499e75d2 100644 --- a/src/Widgets/NotificationsList.vala +++ b/src/Widgets/NotificationsList.vala @@ -158,12 +158,13 @@ public class Notifications.NotificationsList : Granite.Bin { } private void remove_notification (NotificationEntry notification_entry) { - var app_id = notification_entry.notification.desktop_id; + var notification = notification_entry.notification; + var app_id = notification.desktop_id; uint pos = -1; - if (list_store.find (notification_entry, out pos)) { + if (list_store.find (notification, out pos)) { list_store.remove (pos); - Session.get_instance ().remove_notification (notification_entry.notification); + Session.get_instance ().remove_notification (notification); } var items_for_appid = new Gtk.FilterListModel ( From 936e58e16c522d05056a28874b8ff339add1ac59 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Danielle=20For=C3=A9?= Date: Thu, 3 Sep 2026 17:44:02 -0700 Subject: [PATCH 2/2] fix review comment --- src/Widgets/NotificationsList.vala | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/src/Widgets/NotificationsList.vala b/src/Widgets/NotificationsList.vala index 3dd84f0d..6aff4129 100644 --- a/src/Widgets/NotificationsList.vala +++ b/src/Widgets/NotificationsList.vala @@ -107,7 +107,7 @@ public class Notifications.NotificationsList : Granite.Bin { var notification_entry = new NotificationEntry (); notification_entry.bind (notification); - notification_entry.remove.connect (remove_notification); + notification_entry.remove.connect (() => remove_notification (notification)); return notification_entry; } @@ -165,8 +165,7 @@ public class Notifications.NotificationsList : Granite.Bin { items_changed (); } - private void remove_notification (NotificationEntry notification_entry) { - var notification = notification_entry.notification; + private void remove_notification (Notification notification) { var app_id = notification.desktop_id; uint pos = -1;