From 43a37637cfe687af2b02657e67c880eda236cbf1 Mon Sep 17 00:00:00 2001 From: alex-z Date: Thu, 19 May 2022 17:04:47 +0300 Subject: [PATCH] Display chat message inside the OS notification. Signed-off-by: alex-z --- src/gui/tray/usermodel.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/gui/tray/usermodel.cpp b/src/gui/tray/usermodel.cpp index d3117b07c..5907f00d5 100644 --- a/src/gui/tray/usermodel.cpp +++ b/src/gui/tray/usermodel.cpp @@ -121,7 +121,8 @@ void User::slotBuildNotificationDisplay(const ActivityList &list) qCInfo(lcActivity) << "Activity in blacklist, skip"; continue; } - const auto message = AccountManager::instance()->accounts().count() == 1 ? "" : activity._accName; + const auto message = activity._objectType == QStringLiteral("chat") + ? activity._message : AccountManager::instance()->accounts().count() == 1 ? "" : activity._accName; showDesktopNotification(activity._subject, message, activity._id); // We assigned the notif. id to the activity id _activityModel->addNotificationToActivityList(activity); } -- 2.30.2