mirror of
https://gitdl.cn/https://github.com/chakralinux/core.git
synced 2025-02-05 14:57:15 +08:00
20 lines
803 B
Diff
20 lines
803 B
Diff
--- ./plasma/generic/applets/systemtray/protocols/notifications/dbusnotificationprotocol.cpp 2010-01-27 00:42:02.818333858 +0100
|
|
+++ ./plasma/generic/applets/systemtray/protocols/notifications/dbusnotificationprotocol.cpp 2010-01-27 00:45:29.450821186 +0100
|
|
@@ -24,6 +24,7 @@
|
|
|
|
#include <KConfigGroup>
|
|
#include <KIcon>
|
|
+#include <KIconLoader>
|
|
|
|
#include <plasma/dataenginemanager.h>
|
|
#include <plasma/service.h>
|
|
@@ -95,6 +96,9 @@
|
|
|
|
if (data.contains("image")) {
|
|
QImage image = qvariant_cast<QImage>(data.value("image"));
|
|
+ if (qMax(image.width(), image.height()) > KIconLoader::SizeHuge) {
|
|
+ image = image.scaled(KIconLoader::SizeHuge, KIconLoader::SizeHuge, Qt::KeepAspectRatio, Qt::SmoothTransformation);
|
|
+ }
|
|
notification->setImage(image);
|
|
}
|