pmaports/temp/plasma-workspace/D27968.patch
Bart Ribbers 8a2e7e251d
temp/plasma-workspace: fix notifications location (!1050)
Fixes an issue where notifications aren't centered on the screen
2020-03-13 11:34:23 +01:00

24 lines
1 KiB
Diff

diff --git a/applets/notifications/package/contents/ui/global/Globals.qml b/applets/notifications/package/contents/ui/global/Globals.qml
--- a/applets/notifications/package/contents/ui/global/Globals.qml
+++ b/applets/notifications/package/contents/ui/global/Globals.qml
@@ -26,6 +26,7 @@
import org.kde.plasma.core 2.0 as PlasmaCore
import org.kde.plasma.components 2.0 as Components
import org.kde.kquickcontrolsaddons 2.0
+import org.kde.kirigami 2.11 as Kirigami
import org.kde.notificationmanager 1.0 as NotificationManager
import org.kde.taskmanager 0.1 as TaskManager
@@ -90,6 +91,11 @@
property var plasmoids: []
property int popupLocation: {
+ // if we are on mobile, we can ignore the settings totally and just
+ // align it to top left
+ if (Kirigami.Settings.isMobile) {
+ return Qt.AlignTop | Qt.AlignHCenter;
+ }
switch (notificationSettings.popupPosition) {
// Auto-determine location based on plasmoid location
case NotificationManager.Settings.CloseToWidget: