Update changelog ukui-notification4.0.1.2-ok1

This commit is contained in:
iaom 2023-11-16 09:23:06 +08:00 committed by openkylin-cibot
parent 10dbc51680
commit 7c166af91c
3 changed files with 60 additions and 0 deletions

8
debian/changelog vendored
View File

@ -1,3 +1,11 @@
ukui-notification (4.0.1.2-ok1) yangtze; urgency=medium
* Issues: 无
* 其他改动:
- 修复通知关闭时无关闭信号的问题
-- zhangpengfei <zhangpengfei@kylinos.cn> Thu, 16 Nov 2023 09:20:38 +0800
ukui-notification (4.0.1.2-ok0) yangtze; urgency=medium
* Issues: https://gitee.com/openkylin/ukui-control-center/issues/I80Y9K?from=project-issue

View File

@ -0,0 +1,51 @@
From: iaom <zhangpengfei@kylinos.cn>
Date: Thu, 16 Nov 2023 09:23:06 +0800
Subject: Update changelog ukui-notification4.0.1.2-ok1
---
libukui-notification/notification-client.cpp | 10 +++-------
notification-server/server.cpp | 1 +
2 files changed, 4 insertions(+), 7 deletions(-)
diff --git a/libukui-notification/notification-client.cpp b/libukui-notification/notification-client.cpp
index 070b8ce..e32e01e 100644
--- a/libukui-notification/notification-client.cpp
+++ b/libukui-notification/notification-client.cpp
@@ -31,11 +31,7 @@ NotificationClientPrivate::NotificationClientPrivate(NotificationClient *q) : QO
NotificationClientPrivate::~NotificationClientPrivate()
{
- if(m_notificationsInterface) {
- m_notificationsInterface->call(QDBus::NoBlock, QStringLiteral("UnRegisterClient"));
- delete m_notificationsInterface;
- m_notificationsInterface = nullptr;
- }
+ unregisterClient();
}
bool NotificationClientPrivate::init()
@@ -158,10 +154,10 @@ bool NotificationClientPrivate::closeNotification(uint id, NotificationCloseReas
if(!m_serverInterface) {
return false;
}
- QDBusMessage reply = m_serverInterface->callWithArgumentList(QDBus::NoBlock, QStringLiteral("CloseNotification"), {id, reason});
+ QDBusMessage reply = m_serverInterface->callWithArgumentList(QDBus::BlockWithGui, QStringLiteral("CloseNotification"), {id, static_cast<uint32_t>(reason)});
if (reply.type() == QDBusMessage::ErrorMessage) {
qWarning() << "Failed to call CloseNotification!" << QDBusConnection::sessionBus().lastError();
- return false;
+ return false;
}
return true;
}
diff --git a/notification-server/server.cpp b/notification-server/server.cpp
index 0e672bb..5528237 100644
--- a/notification-server/server.cpp
+++ b/notification-server/server.cpp
@@ -174,6 +174,7 @@ void ServerPrivate::CloseNotification(uint id, uint reason)
if(m_notificationsCache.contains(id)) {
m_notificationsCache.remove(id);
}
+ qDebug() << "CloseNotification" << id << reason;
Q_EMIT NotificationClosed(id, reason);
}

1
debian/patches/series vendored Normal file
View File

@ -0,0 +1 @@
0001-Update-changelog-ukui-notification4.0.1.2-ok1.patch