summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2021-12-19 09:34:50 +0100
committerNicolas Werner <nicolas.werner@hotmail.de>2021-12-19 09:36:00 +0100
commit9b25ef3c0d3b8399c133926fe4b1aa317998d2d2 (patch)
treeb40b941dd1d1ad7424e22b0eb69e7dbd13053869 /src
parentMake Nheko show up in system notification settings on Linux (diff)
downloadnheko-9b25ef3c0d3b8399c133926fe4b1aa317998d2d2.tar.xz
Set notification category
Diffstat (limited to 'src')
-rw-r--r--src/Cache.cpp2
-rw-r--r--src/notifications/ManagerLinux.cpp1
2 files changed, 3 insertions, 0 deletions
diff --git a/src/Cache.cpp b/src/Cache.cpp
index f22afc7f..dd26157c 100644
--- a/src/Cache.cpp
+++ b/src/Cache.cpp
@@ -1527,6 +1527,8 @@ Cache::saveState(const mtx::responses::Sync &res)
                 if (auto fr = std::get_if<
                       mtx::events::AccountDataEvent<mtx::events::account_data::FullyRead>>(&evt)) {
                     nhlog::db()->debug("Fully read: {}", fr->content.event_id);
+                    emit removeNotification(QString::fromStdString(room.first),
+                                            QString::fromStdString(fr->content.event_id));
                 }
             }
         }
diff --git a/src/notifications/ManagerLinux.cpp b/src/notifications/ManagerLinux.cpp
index 14021b96..a3a2dbe8 100644
--- a/src/notifications/ManagerLinux.cpp
+++ b/src/notifications/ManagerLinux.cpp
@@ -147,6 +147,7 @@ NotificationsManager::systemPostNotification(const QString &room_id,
     hints["image-data"]    = icon;
     hints["sound-name"]    = "message-new-instant";
     hints["desktop-entry"] = "nheko";
+    hints["category"]      = "im.received";
 
     QList<QVariant> argumentList;
     argumentList << "nheko";  // app_name