summaryrefslogtreecommitdiffstats
path: root/kcontrol/hwmanager/hwdevicetray.cpp
diff options
context:
space:
mode:
authorSlávek Banko <slavek.banko@axis.cz>2023-02-16 15:54:07 +0100
committerSlávek Banko <slavek.banko@axis.cz>2023-02-16 15:57:20 +0100
commit68c1810b9ee1f895e3129ca1629bc6b47f3946aa (patch)
treeb4a5120881e4d4ba7f49e52b38eb2f6537e29621 /kcontrol/hwmanager/hwdevicetray.cpp
parentd88a72a5bc138dd06b7d5763a68014667d47ecba (diff)
downloadtdebase-68c1810b9ee1f895e3129ca1629bc6b47f3946aa.tar.gz
tdebase-68c1810b9ee1f895e3129ca1629bc6b47f3946aa.zip
hwmanager: Do not open a popup window when clicking on a notification,
if automatic opening of popup windows is enabled.
Diffstat (limited to 'kcontrol/hwmanager/hwdevicetray.cpp')
-rw-r--r--kcontrol/hwmanager/hwdevicetray.cpp7
1 files changed, 7 insertions, 0 deletions
diff --git a/kcontrol/hwmanager/hwdevicetray.cpp b/kcontrol/hwmanager/hwdevicetray.cpp
index d48738256..859c86fed 100644
--- a/kcontrol/hwmanager/hwdevicetray.cpp
+++ b/kcontrol/hwmanager/hwdevicetray.cpp
@@ -699,6 +699,13 @@ void HwDeviceSystemTray::deviceChanged(TDEGenericDevice* device)
void HwDeviceSystemTray::devicePopupClicked(KPassivePopup* popup, TQPoint point, TQString uuid) {
TDEGenericDevice *hwdevice;
if (uuid.startsWith("ADD: ")) {
+ TDEConfig config("mediamanagerrc");
+ config.setGroup("Global");
+ if (config.readBoolEntry("NotificationPopupsEnabled", true))
+ {
+ return;
+ }
+
uuid = uuid.right(uuid.length() - strlen("ADD: "));
if (uuid != "") {
TDEHardwareDevices *hwdevices = TDEGlobal::hardwareDevices();