- pull in upstream branch fixes - re-order patches so upstream applied first, then downstreamepel9
parent
365cf85207
commit
1f7a0b191a
@ -0,0 +1,65 @@
|
||||
From 99e5f4316c5ac1045d6a4c97e51a18a69a1ead06 Mon Sep 17 00:00:00 2001
|
||||
From: Gabriel Craciunescu <crazy@frugalware.org>
|
||||
Date: Tue, 4 Oct 2016 11:05:57 +0100
|
||||
Subject: [PATCH 05/19] Fix usage of qdbus variable in startkde
|
||||
|
||||
$qdbus is a full path to the qdbus binary, not relying on it being in
|
||||
$PATH
|
||||
|
||||
It was completely unset in startplasma and startkde made a call to
|
||||
ksplash using qdbus assuming it's in the path
|
||||
|
||||
Reviewed-by: David Edmundson
|
||||
---
|
||||
startkde/startkde.cmake | 2 +-
|
||||
startkde/startplasma.cmake | 14 +++++++++++++-
|
||||
2 files changed, 14 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/startkde/startkde.cmake b/startkde/startkde.cmake
|
||||
index b320234..ddd3663 100644
|
||||
--- a/startkde/startkde.cmake
|
||||
+++ b/startkde/startkde.cmake
|
||||
@@ -359,7 +359,7 @@ if test $? -ne 0; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
-qdbus org.kde.KSplash /KSplash org.kde.KSplash.setStage kinit
|
||||
+$qdbus org.kde.KSplash /KSplash org.kde.KSplash.setStage kinit
|
||||
|
||||
# finally, give the session control to the session manager
|
||||
# see kdebase/ksmserver for the description of the rest of the startup sequence
|
||||
diff --git a/startkde/startplasma.cmake b/startkde/startplasma.cmake
|
||||
index fa20ef4..2904e8f 100644
|
||||
--- a/startkde/startplasma.cmake
|
||||
+++ b/startkde/startplasma.cmake
|
||||
@@ -49,6 +49,18 @@ if test -z "$dl"; then
|
||||
esac
|
||||
fi
|
||||
|
||||
+# in case we have been started with full pathname spec without being in PATH
|
||||
+bindir=`echo "$0" | sed -n 's,^\(/.*\)/[^/][^/]*$,\1,p'`
|
||||
+if [ -n "$bindir" ]; then
|
||||
+ qbindir=`qtpaths --binaries-dir`
|
||||
+ qdbus=$qbindir/qdbus
|
||||
+ case $PATH in
|
||||
+ $bindir|$bindir:*|*:$bindir|*:$bindir:*) ;;
|
||||
+ *) PATH=$bindir:$PATH; export PATH;;
|
||||
+ esac
|
||||
+else
|
||||
+ qdbus=qdbus
|
||||
+fi
|
||||
|
||||
# Activate the kde font directories.
|
||||
#
|
||||
@@ -128,7 +140,7 @@ if test $? -ne 0; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
-qdbus org.kde.KSplash /KSplash org.kde.KSplash.setStage kinit
|
||||
+$qdbus org.kde.KSplash /KSplash org.kde.KSplash.setStage kinit
|
||||
|
||||
# finally, give the session control to the session manager
|
||||
# see kdebase/ksmserver for the description of the rest of the startup sequence
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,62 @@
|
||||
From 3fbc9aad103d684efb0cb7b86fdc2965c4746adc Mon Sep 17 00:00:00 2001
|
||||
From: Marco Martin <notmart@gmail.com>
|
||||
Date: Wed, 5 Oct 2016 09:56:39 +0200
|
||||
Subject: [PATCH 06/19] always connect to "Local" source
|
||||
|
||||
Summary:
|
||||
We need Local to be *always* present, even if not disaplayed as
|
||||
it's used for formatting in ToolTip.dateTimeChanged()
|
||||
this makes sure local is always in the connected sources, even if
|
||||
it's not explicitly shown to the user
|
||||
|
||||
Test Plan:
|
||||
tested, local timezone is not shown in clock/tooltip when
|
||||
selected, and no warnings from dateTimeChanged()
|
||||
|
||||
Reviewers: #plasma, davidedmundson
|
||||
|
||||
Reviewed By: #plasma, davidedmundson
|
||||
|
||||
Subscribers: plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2936
|
||||
---
|
||||
applets/digital-clock/package/contents/ui/main.qml | 17 ++++++++++++++++-
|
||||
1 file changed, 16 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/applets/digital-clock/package/contents/ui/main.qml b/applets/digital-clock/package/contents/ui/main.qml
|
||||
index ca22e05..f117ea4 100644
|
||||
--- a/applets/digital-clock/package/contents/ui/main.qml
|
||||
+++ b/applets/digital-clock/package/contents/ui/main.qml
|
||||
@@ -56,10 +56,25 @@ Item {
|
||||
source: "Tooltip.qml"
|
||||
}
|
||||
|
||||
+ //We need Local to be *always* present, even if not disaplayed as
|
||||
+ //it's used for formatting in ToolTip.dateTimeChanged()
|
||||
+ property var allTimezones
|
||||
+ Connections {
|
||||
+ target: plasmoid.configuration
|
||||
+ onSelectedTimeZonesChanged: {
|
||||
+ var tz = Array()
|
||||
+ if (plasmoid.configuration.selectedTimeZones.indexOf("Local") === -1) {
|
||||
+ tz.push("Local");
|
||||
+ }
|
||||
+ root.allTimezones = tz.concat(plasmoid.configuration.selectedTimeZones);
|
||||
+
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
PlasmaCore.DataSource {
|
||||
id: dataSource
|
||||
engine: "time"
|
||||
- connectedSources: plasmoid.configuration.selectedTimeZones
|
||||
+ connectedSources: allTimezones
|
||||
interval: plasmoid.configuration.showSeconds ? 1000 : 60000
|
||||
intervalAlignment: plasmoid.configuration.showSeconds ? PlasmaCore.Types.NoAlignment : PlasmaCore.Types.AlignToMinute
|
||||
}
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,45 @@
|
||||
From 27274d4c913d0b7b5cfece0f5e5b14c278f063f9 Mon Sep 17 00:00:00 2001
|
||||
From: Kai Uwe Broulik <kde@privat.broulik.de>
|
||||
Date: Wed, 5 Oct 2016 15:26:25 +0200
|
||||
Subject: [PATCH 08/19] [Digital Clock] Silence warning
|
||||
|
||||
BUG: 369734
|
||||
FIXED-IN: 5.8.1
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2922
|
||||
---
|
||||
applets/digital-clock/package/contents/ui/Tooltip.qml | 9 +++++++--
|
||||
1 file changed, 7 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/applets/digital-clock/package/contents/ui/Tooltip.qml b/applets/digital-clock/package/contents/ui/Tooltip.qml
|
||||
index 8436796..889e038 100644
|
||||
--- a/applets/digital-clock/package/contents/ui/Tooltip.qml
|
||||
+++ b/applets/digital-clock/package/contents/ui/Tooltip.qml
|
||||
@@ -36,6 +36,11 @@ Item {
|
||||
LayoutMirroring.childrenInherit: true
|
||||
|
||||
function timeForZone(zone) {
|
||||
+ var compactRepresentationItem = plasmoid.compactRepresentationItem;
|
||||
+ if (!compactRepresentationItem) {
|
||||
+ return "";
|
||||
+ }
|
||||
+
|
||||
// get the time for the given timezone from the dataengine
|
||||
var now = dataSource.data[zone]["DateTime"];
|
||||
// get current UTC time
|
||||
@@ -43,10 +48,10 @@ Item {
|
||||
// add the dataengine TZ offset to it
|
||||
var dateTime = new Date(msUTC + (dataSource.data[zone]["Offset"] * 1000));
|
||||
|
||||
- var formattedTime = Qt.formatTime(dateTime, plasmoid.compactRepresentationItem.timeFormat);
|
||||
+ var formattedTime = Qt.formatTime(dateTime, compactRepresentationItem.timeFormat);
|
||||
|
||||
if (dateTime.getDay() != dataSource.data["Local"]["DateTime"].getDay()) {
|
||||
- formattedTime += " (" + Qt.formatDate(dateTime, plasmoid.compactRepresentationItem.dateFormat) + ")";
|
||||
+ formattedTime += " (" + Qt.formatDate(dateTime, compactRepresentationItem.dateFormat) + ")";
|
||||
}
|
||||
|
||||
return formattedTime;
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,45 @@
|
||||
From d3fc0c18787100d1795a9115588acf91b0cd3bb3 Mon Sep 17 00:00:00 2001
|
||||
From: David Edmundson <kde@davidedmundson.co.uk>
|
||||
Date: Wed, 5 Oct 2016 15:53:32 +0100
|
||||
Subject: [PATCH 09/19] Set explicit minimum size on panelSpacer so that
|
||||
AppletContainer doesn't set one
|
||||
|
||||
Summary:
|
||||
Commit 8e1339887a01e078b04fb18ff575c16998447665 in Plasma 5.8 removed a
|
||||
minimum size on the panel spacer, which is what we want, however if no
|
||||
minimum size is set on an applet in a panel the panel's AppletContainer
|
||||
sets the minmimum width to be the same as the height.
|
||||
|
||||
This was preventing people having tiny panel spacers.
|
||||
|
||||
BUG: 369823
|
||||
|
||||
Test Plan: Reporter tested the patch
|
||||
|
||||
Reviewers: #plasma
|
||||
|
||||
Subscribers: plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2938
|
||||
---
|
||||
applets/panelspacer/contents/ui/main.qml | 2 ++
|
||||
1 file changed, 2 insertions(+)
|
||||
|
||||
diff --git a/applets/panelspacer/contents/ui/main.qml b/applets/panelspacer/contents/ui/main.qml
|
||||
index 0418e8a..4d4302f 100644
|
||||
--- a/applets/panelspacer/contents/ui/main.qml
|
||||
+++ b/applets/panelspacer/contents/ui/main.qml
|
||||
@@ -33,6 +33,8 @@ Item {
|
||||
Layout.fillWidth: plasmoid.configuration.expanding
|
||||
Layout.fillHeight: plasmoid.configuration.expanding
|
||||
|
||||
+ Layout.minimumWidth: 1
|
||||
+ Layout.minimumHeight: 1
|
||||
Layout.preferredWidth: horizontal ? plasmoid.configuration.length : 0
|
||||
Layout.preferredHeight: horizontal ? 0 : plasmoid.configuration.length
|
||||
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,58 @@
|
||||
From eb6223bbe650551157417615a5f564a2928fd0e7 Mon Sep 17 00:00:00 2001
|
||||
From: David Edmundson <kde@davidedmundson.co.uk>
|
||||
Date: Wed, 5 Oct 2016 15:54:05 +0100
|
||||
Subject: [PATCH 10/19] Fix kcminit phase 1 and 2
|
||||
|
||||
Summary:
|
||||
The current code registers the session bus *after* app->exec() this
|
||||
effectively means it won't work.
|
||||
|
||||
This causes ksmserver to be unable to deliver the calls to start kcminit
|
||||
modules at remaining init phases.
|
||||
|
||||
Any KCMinit module which are at X-KDE-Init-Phase=1 or 2 will now get
|
||||
run. It also means kcminit_startup closes, instead of lingersing on
|
||||
startup doing nothing until it times out 5 minutes later.
|
||||
|
||||
Test Plan: Confirmed kcminit_startup now exits properly.
|
||||
|
||||
Reviewers: #plasma, apol
|
||||
|
||||
Reviewed By: apol
|
||||
|
||||
Subscribers: plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2887
|
||||
---
|
||||
startkde/kcminit/main.cpp | 6 ++++--
|
||||
1 file changed, 4 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/startkde/kcminit/main.cpp b/startkde/kcminit/main.cpp
|
||||
index 3f67b46..0633abd 100644
|
||||
--- a/startkde/kcminit/main.cpp
|
||||
+++ b/startkde/kcminit/main.cpp
|
||||
@@ -212,6 +212,10 @@ KCMInit::KCMInit( const QCommandLineParser& args )
|
||||
|
||||
sendReady();
|
||||
QTimer::singleShot( 300 * 1000, qApp, &QCoreApplication::quit); // just in case
|
||||
+
|
||||
+ QDBusConnection::sessionBus().registerObject(QStringLiteral("/kcminit"), this, QDBusConnection::ExportScriptableContents);
|
||||
+ QDBusConnection::sessionBus().registerService(QStringLiteral("org.kde.kcminit"));
|
||||
+
|
||||
qApp->exec(); // wait for runPhase1() and runPhase2()
|
||||
}
|
||||
else
|
||||
@@ -266,8 +270,6 @@ extern "C" Q_DECL_EXPORT int kdemain(int argc, char *argv[])
|
||||
about.processCommandLine(&parser);
|
||||
|
||||
KCMInit kcminit( parser );
|
||||
- QDBusConnection::sessionBus().registerObject(QStringLiteral("/kcminit"), &kcminit, QDBusConnection::ExportScriptableContents);
|
||||
- QDBusConnection::sessionBus().registerService(QStringLiteral("org.kde.kcminit"));
|
||||
return 0;
|
||||
}
|
||||
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,72 @@
|
||||
From 4e5d70d8b5d1d4595ad0975c77b06ef2cb6fa0e1 Mon Sep 17 00:00:00 2001
|
||||
From: Marco Martin <notmart@gmail.com>
|
||||
Date: Wed, 5 Oct 2016 15:52:39 +0200
|
||||
Subject: [PATCH 11/19] make sure allTimezones is set
|
||||
|
||||
Summary:
|
||||
on Qt 5.6/5.7 changed signal was emitted at startup as well,
|
||||
triggering plasmoid.configuration.onSelectedTimeZonesChanged
|
||||
in Qt 5.8 this doesn't happen, giving an empty clock at startup
|
||||
this makes sure allTimezones gets built
|
||||
|
||||
Test Plan: with Qt 5.8 the clock is shown correctly
|
||||
|
||||
Reviewers: #plasma, broulik
|
||||
|
||||
Reviewed By: #plasma, broulik
|
||||
|
||||
Subscribers: broulik, plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2946
|
||||
---
|
||||
applets/digital-clock/package/contents/ui/main.qml | 18 ++++++++++--------
|
||||
1 file changed, 10 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/applets/digital-clock/package/contents/ui/main.qml b/applets/digital-clock/package/contents/ui/main.qml
|
||||
index f117ea4..66e8420 100644
|
||||
--- a/applets/digital-clock/package/contents/ui/main.qml
|
||||
+++ b/applets/digital-clock/package/contents/ui/main.qml
|
||||
@@ -41,6 +41,14 @@ Item {
|
||||
return new Date(msUTC + (dataSource.data[plasmoid.configuration.lastSelectedTimezone]["Offset"] * 1000));
|
||||
}
|
||||
|
||||
+ function initTimezones() {
|
||||
+ var tz = Array()
|
||||
+ if (plasmoid.configuration.selectedTimeZones.indexOf("Local") === -1) {
|
||||
+ tz.push("Local");
|
||||
+ }
|
||||
+ root.allTimezones = tz.concat(plasmoid.configuration.selectedTimeZones);
|
||||
+ }
|
||||
+
|
||||
Plasmoid.preferredRepresentation: Plasmoid.compactRepresentation
|
||||
Plasmoid.compactRepresentation: DigitalClock { }
|
||||
Plasmoid.fullRepresentation: CalendarView { }
|
||||
@@ -61,14 +69,7 @@ Item {
|
||||
property var allTimezones
|
||||
Connections {
|
||||
target: plasmoid.configuration
|
||||
- onSelectedTimeZonesChanged: {
|
||||
- var tz = Array()
|
||||
- if (plasmoid.configuration.selectedTimeZones.indexOf("Local") === -1) {
|
||||
- tz.push("Local");
|
||||
- }
|
||||
- root.allTimezones = tz.concat(plasmoid.configuration.selectedTimeZones);
|
||||
-
|
||||
- }
|
||||
+ onSelectedTimeZonesChanged: root.initTimezones();
|
||||
}
|
||||
|
||||
PlasmaCore.DataSource {
|
||||
@@ -98,6 +99,7 @@ Item {
|
||||
}
|
||||
|
||||
Component.onCompleted: {
|
||||
+ root.initTimezones();
|
||||
if (KCMShell.authorize("clock.desktop").length > 0) {
|
||||
plasmoid.setAction("clockkcm", i18n("Adjust Date and Time..."), "preferences-system-time");
|
||||
}
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,36 @@
|
||||
From fcc806c09859faee0942186dafa2904b3365cf0b Mon Sep 17 00:00:00 2001
|
||||
From: Kai Uwe Broulik <kde@privat.broulik.de>
|
||||
Date: Thu, 6 Oct 2016 10:59:50 +0200
|
||||
Subject: [PATCH 12/19] [Notification Data Engine] Don't group notification if
|
||||
it should replace an existing one
|
||||
|
||||
If an application explicitly requests a notification to replace another one (replaces_id set),
|
||||
don't group it with another notification.
|
||||
|
||||
When creating a KNotification object and then updating it by calling e.g. setText it would
|
||||
just append it to the already shown notification.
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2954
|
||||
---
|
||||
dataengines/notifications/notificationsengine.cpp | 3 +--
|
||||
1 file changed, 1 insertion(+), 2 deletions(-)
|
||||
|
||||
diff --git a/dataengines/notifications/notificationsengine.cpp b/dataengines/notifications/notificationsengine.cpp
|
||||
index 6c7e286..2bc4dc2 100644
|
||||
--- a/dataengines/notifications/notificationsengine.cpp
|
||||
+++ b/dataengines/notifications/notificationsengine.cpp
|
||||
@@ -193,10 +193,9 @@ uint NotificationsEngine::Notify(const QString &app_name, uint replaces_id,
|
||||
|
||||
// group notifications that have the same title coming from the same app
|
||||
// or if they are on the "blacklist", honor the skipGrouping hint sent
|
||||
- if (m_activeNotifications.values().contains(app_name + summary) && !skipGrouping && !m_alwaysReplaceAppsList.contains(app_name)) {
|
||||
+ if (!replaces_id && m_activeNotifications.values().contains(app_name + summary) && !skipGrouping && !m_alwaysReplaceAppsList.contains(app_name)) {
|
||||
// cut off the "notification " from the source name
|
||||
partOf = m_activeNotifications.key(app_name + summary).midRef(13).toUInt();
|
||||
-
|
||||
}
|
||||
|
||||
qDebug() << "Currrent active notifications:" << m_activeNotifications;
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,172 @@
|
||||
From 77aaa88eb2a148f0955eb35b3043d3f0f81fae5b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Martin=20Gr=C3=A4=C3=9Flin?= <mgraesslin@kde.org>
|
||||
Date: Wed, 5 Oct 2016 09:07:08 +0200
|
||||
Subject: [PATCH 13/19] [klipper] Move notification from tray to Klipper
|
||||
|
||||
Summary:
|
||||
Klipper shows a notification when the shortcuts next/prev history item
|
||||
gets triggered. This notification used to be implemented in the class
|
||||
KlipperTray. With the switch from SNI based clipper to a Plasmoid the
|
||||
notification got lost as the Plasmoid doesn't use the KlipperTray class
|
||||
at all.
|
||||
|
||||
This change moves the notification handling from KlipperTray to Klipper
|
||||
so that it gets emitted for both SNI and Plasmoid based klipper.
|
||||
|
||||
BUG: 368808
|
||||
FIXED-IN: 5.8.1
|
||||
|
||||
Test Plan: Set the shortcuts, triggered them and verified the notification gets shown.
|
||||
|
||||
Reviewers: #plasma
|
||||
|
||||
Subscribers: plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2942
|
||||
---
|
||||
klipper/CMakeLists.txt | 1 +
|
||||
klipper/klipper.cpp | 12 ++++++++++++
|
||||
klipper/klipper.h | 3 +++
|
||||
klipper/tray.cpp | 13 -------------
|
||||
klipper/tray.h | 5 -----
|
||||
5 files changed, 16 insertions(+), 18 deletions(-)
|
||||
|
||||
diff --git a/klipper/CMakeLists.txt b/klipper/CMakeLists.txt
|
||||
index d152d0f..d9538fd 100644
|
||||
--- a/klipper/CMakeLists.txt
|
||||
+++ b/klipper/CMakeLists.txt
|
||||
@@ -82,6 +82,7 @@ target_link_libraries(plasma_engine_clipboard
|
||||
KF5::IconThemes
|
||||
KF5::KIOWidgets # PreviewJob
|
||||
KF5::Plasma
|
||||
+ KF5::Notifications
|
||||
KF5::Service
|
||||
KF5::TextWidgets # KTextEdit
|
||||
KF5::WidgetsAddons # KMessageBox
|
||||
diff --git a/klipper/klipper.cpp b/klipper/klipper.cpp
|
||||
index 79060d8..8de19fb 100644
|
||||
--- a/klipper/klipper.cpp
|
||||
+++ b/klipper/klipper.cpp
|
||||
@@ -36,6 +36,7 @@
|
||||
|
||||
#include <KGlobalAccel>
|
||||
#include <KMessageBox>
|
||||
+#include <KNotification>
|
||||
#include <KActionCollection>
|
||||
#include <KToggleAction>
|
||||
#include <KTextEdit>
|
||||
@@ -227,6 +228,17 @@ Klipper::Klipper(QObject* parent, const KSharedConfigPtr& config, KlipperMode mo
|
||||
if (m_mode == KlipperMode::Standalone) {
|
||||
connect(qApp, &QGuiApplication::commitDataRequest, this, &Klipper::saveSession);
|
||||
}
|
||||
+
|
||||
+ connect(this, &Klipper::passivePopup, this,
|
||||
+ [this] (const QString &caption, const QString &text) {
|
||||
+ if (m_notification) {
|
||||
+ m_notification->setTitle(caption);
|
||||
+ m_notification->setText(text);
|
||||
+ } else {
|
||||
+ m_notification = KNotification::event(KNotification::Notification, caption, text, QStringLiteral("klipper"));
|
||||
+ }
|
||||
+ }
|
||||
+ );
|
||||
}
|
||||
|
||||
Klipper::~Klipper()
|
||||
diff --git a/klipper/klipper.h b/klipper/klipper.h
|
||||
index f6e5da6..99c71f3 100644
|
||||
--- a/klipper/klipper.h
|
||||
+++ b/klipper/klipper.h
|
||||
@@ -26,6 +26,7 @@
|
||||
#include <QTime>
|
||||
#include <QTimer>
|
||||
#include <QClipboard>
|
||||
+#include <QPointer>
|
||||
|
||||
#include "urlgrabber.h"
|
||||
|
||||
@@ -39,6 +40,7 @@ class QAction;
|
||||
class QMenu;
|
||||
class QMimeData;
|
||||
class HistoryItem;
|
||||
+class KNotification;
|
||||
|
||||
enum class KlipperMode {
|
||||
Standalone,
|
||||
@@ -207,6 +209,7 @@ private:
|
||||
KActionCollection* m_collection;
|
||||
KlipperMode m_mode;
|
||||
QTimer *m_saveFileTimer = nullptr;
|
||||
+ QPointer<KNotification> m_notification;
|
||||
};
|
||||
|
||||
#endif
|
||||
diff --git a/klipper/tray.cpp b/klipper/tray.cpp
|
||||
index 48a9661..75fbe7f 100644
|
||||
--- a/klipper/tray.cpp
|
||||
+++ b/klipper/tray.cpp
|
||||
@@ -23,7 +23,6 @@
|
||||
#include "tray.h"
|
||||
|
||||
#include <KLocalizedString>
|
||||
-#include <KNotification>
|
||||
|
||||
#include "klipper.h"
|
||||
#include "history.h"
|
||||
@@ -46,7 +45,6 @@ KlipperTray::KlipperTray()
|
||||
setAssociatedWidget( m_klipper->popup() );
|
||||
connect( m_klipper->history(), &History::changed, this, &KlipperTray::slotSetToolTipFromHistory);
|
||||
slotSetToolTipFromHistory();
|
||||
- connect(m_klipper, &Klipper::passivePopup, this, &KlipperTray::slotPassivePopup);
|
||||
}
|
||||
|
||||
void KlipperTray::slotSetToolTipFromHistory()
|
||||
@@ -64,15 +62,4 @@ void KlipperTray::slotSetToolTipFromHistory()
|
||||
}
|
||||
}
|
||||
|
||||
-void KlipperTray::slotPassivePopup(const QString& caption, const QString& text)
|
||||
-{
|
||||
- if (m_notification) {
|
||||
- m_notification->setTitle(caption);
|
||||
- m_notification->setText(text);
|
||||
- } else {
|
||||
- m_notification = KNotification::event(KNotification::Notification, caption, text,
|
||||
- QIcon::fromTheme(QStringLiteral("klipper")).pixmap(QSize(16, 16)));
|
||||
- }
|
||||
-}
|
||||
-
|
||||
|
||||
diff --git a/klipper/tray.h b/klipper/tray.h
|
||||
index 388674c..d4b0716 100644
|
||||
--- a/klipper/tray.h
|
||||
+++ b/klipper/tray.h
|
||||
@@ -20,11 +20,8 @@
|
||||
#ifndef TRAY_H
|
||||
#define TRAY_H
|
||||
|
||||
-#include <QPointer>
|
||||
-
|
||||
#include <KStatusNotifierItem>
|
||||
|
||||
-class KNotification;
|
||||
class Klipper;
|
||||
|
||||
class KlipperTray : public KStatusNotifierItem
|
||||
@@ -36,11 +33,9 @@ public:
|
||||
|
||||
public Q_SLOTS:
|
||||
void slotSetToolTipFromHistory();
|
||||
- void slotPassivePopup(const QString& caption, const QString& text);
|
||||
|
||||
private:
|
||||
Klipper* m_klipper;
|
||||
- QPointer<KNotification> m_notification;
|
||||
};
|
||||
|
||||
#endif
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,52 @@
|
||||
From 53b2a407af9d1d60cfbb1a42af8546ab0a156d38 Mon Sep 17 00:00:00 2001
|
||||
From: Marco Martin <notmart@gmail.com>
|
||||
Date: Thu, 6 Oct 2016 15:50:05 +0200
|
||||
Subject: [PATCH 15/19] save the containment only aftyer switch
|
||||
|
||||
Summary:
|
||||
during a type switch
|
||||
if the new containment gets saved before getting a view,
|
||||
it will get lastScreen=-1 so the next boot
|
||||
it will create a new containment
|
||||
|
||||
Test Plan:
|
||||
switched repeatedly between desktop and folderview
|
||||
the config file always got with the correct lastScreen=0 entry
|
||||
|
||||
Reviewers: #plasma
|
||||
|
||||
Subscribers: plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2966
|
||||
---
|
||||
shell/shellcorona.cpp | 5 +++--
|
||||
1 file changed, 3 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/shell/shellcorona.cpp b/shell/shellcorona.cpp
|
||||
index 1d08cd1..74f6ded 100644
|
||||
--- a/shell/shellcorona.cpp
|
||||
+++ b/shell/shellcorona.cpp
|
||||
@@ -1562,8 +1562,6 @@ Plasma::Containment *ShellCorona::setContainmentTypeForScreen(int screen, const
|
||||
newCg.writeEntry("activityId", oldContainment->activity());
|
||||
newContainment->restore(newCg);
|
||||
newContainment->updateConstraints(Plasma::Types::StartupCompletedConstraint);
|
||||
- newContainment->save(newCg);
|
||||
- requestConfigSync();
|
||||
newContainment->flushPendingConstraintsEvents();
|
||||
emit containmentAdded(newContainment);
|
||||
|
||||
@@ -1588,6 +1586,9 @@ Plasma::Containment *ShellCorona::setContainmentTypeForScreen(int screen, const
|
||||
view->rootObject()->setFocus(true, Qt::MouseFocusReason);
|
||||
QTimer::singleShot(2500, oldContainment, &Plasma::Applet::destroy);
|
||||
|
||||
+ //Save now as we now have a screen, so lastScreen will not be -1
|
||||
+ newContainment->save(newCg);
|
||||
+ requestConfigSync();
|
||||
emit availableScreenRectChanged();
|
||||
|
||||
return newContainment;
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,59 @@
|
||||
From 9c94cd136006959d881a614754a0811ae69f03cc Mon Sep 17 00:00:00 2001
|
||||
From: Bhushan Shah <bhush94@gmail.com>
|
||||
Date: Thu, 6 Oct 2016 16:29:07 +0530
|
||||
Subject: [PATCH 16/19] [shell] Fix non-interactive panelview on non-primary
|
||||
screen
|
||||
|
||||
Summary:
|
||||
If we don't pass the current screen to QCursor::pos, it will return
|
||||
position relative to primary screen, which obviously won't be in panel
|
||||
geometry.
|
||||
|
||||
Instead pass it currentScreen, this way we don't filter out the mouse
|
||||
events for panel.
|
||||
|
||||
BUG: 368790
|
||||
FIXED-IN: 5.8.1
|
||||
|
||||
Test Plan:
|
||||
added debug statements and verified that I get correct screen position
|
||||
and as well, panel is now interactive on secondary screen.
|
||||
|
||||
Reviewers: mart, graesslin, #plasma, sebas
|
||||
|
||||
Reviewed By: graesslin, #plasma, sebas
|
||||
|
||||
Subscribers: sebas, plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2960
|
||||
---
|
||||
shell/panelview.cpp | 4 ++--
|
||||
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/shell/panelview.cpp b/shell/panelview.cpp
|
||||
index 45914f4..8ec7a8a 100644
|
||||
--- a/shell/panelview.cpp
|
||||
+++ b/shell/panelview.cpp
|
||||
@@ -567,7 +567,7 @@ void PanelView::restoreAutoHide()
|
||||
(containment()->status() < Plasma::Types::RequiresAttentionStatus
|
||||
|| containment()->status() == Plasma::Types::HiddenStatus)
|
||||
)
|
||||
- && !geometry().contains(QCursor::pos())
|
||||
+ && !geometry().contains(QCursor::pos(screenToFollow()))
|
||||
);
|
||||
}
|
||||
|
||||
@@ -734,7 +734,7 @@ bool PanelView::event(QEvent *e)
|
||||
|
||||
//first, don't mess with position if the cursor is actually outside the view:
|
||||
//somebody is doing a click and drag that must not break when the cursor i outside
|
||||
- if (geometry().contains(QCursor::pos())) {
|
||||
+ if (geometry().contains(QCursor::pos(screenToFollow()))) {
|
||||
if (!containmentContainsPosition(me->windowPos())) {
|
||||
auto me2 = new QMouseEvent(me->type(),
|
||||
positionAdjustedForContainment(me->windowPos()),
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,58 @@
|
||||
From 5cfb957c87994df3cb9c8aa081ad42e67038a7d8 Mon Sep 17 00:00:00 2001
|
||||
From: Bhushan Shah <bhush94@gmail.com>
|
||||
Date: Thu, 6 Oct 2016 22:37:10 +0530
|
||||
Subject: [PATCH 17/19] [shell] Fix crash when moving panel between two
|
||||
monitors
|
||||
|
||||
Summary:
|
||||
When moving panel between two screens there is time when panel is on
|
||||
edge of screen and screenToFollow is null, at this point if any of the
|
||||
resize or position operation gets triggered, it will attempt to get
|
||||
screenToFollow's size or geometry and will result in crash as for
|
||||
sometime screenToFollow is null.
|
||||
|
||||
This is quite a timing related bug, if you manage to move panel in time
|
||||
there would be no crash otherwise there are 3-4 different crashes are
|
||||
possible.
|
||||
|
||||
To solve this we avoid setting null values for screenToFollow, this
|
||||
should not happen ideally, but setting breakpoint on setScreenToFollow
|
||||
shows that null value is set from QML and should be investigated.
|
||||
|
||||
BUG: 369228
|
||||
|
||||
Test Plan:
|
||||
moved panel around like crazy, can't reproduce crash on
|
||||
QScreen::size or QScreen::geometry, without patch it would crash 100%
|
||||
|
||||
Reviewers: mart, #plasma, davidedmundson
|
||||
|
||||
Reviewed By: #plasma, davidedmundson
|
||||
|
||||
Subscribers: plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2970
|
||||
---
|
||||
shell/panelview.cpp | 4 ++++
|
||||
1 file changed, 4 insertions(+)
|
||||
|
||||
diff --git a/shell/panelview.cpp b/shell/panelview.cpp
|
||||
index 8ec7a8a..f3c3cd0 100644
|
||||
--- a/shell/panelview.cpp
|
||||
+++ b/shell/panelview.cpp
|
||||
@@ -682,6 +682,10 @@ void PanelView::setScreenToFollow(QScreen *screen)
|
||||
return;
|
||||
}
|
||||
|
||||
+ if (!screen) {
|
||||
+ return;
|
||||
+ }
|
||||
+
|
||||
/*connect(screen, &QObject::destroyed, this, [this]() {
|
||||
if (PanelView::screen()) {
|
||||
m_screenToFollow = PanelView::screen();
|
||||
--
|
||||
2.7.4
|
||||
|
@ -0,0 +1,45 @@
|
||||
From 921722093048702f5e0ec3c0435f14117fcd9111 Mon Sep 17 00:00:00 2001
|
||||
From: Marco Martin <notmart@gmail.com>
|
||||
Date: Fri, 7 Oct 2016 13:00:44 +0200
|
||||
Subject: [PATCH 18/19] delete containments upon activity deletion
|
||||
|
||||
Summary:
|
||||
after the latest activities refactor, containments weren't
|
||||
deleted anymore upon activity deletion.
|
||||
|
||||
Test Plan:
|
||||
created and deleted activities while monitoring how appletsrc file
|
||||
was updated
|
||||
|
||||
Reviewers: ivan, #plasma, davidedmundson
|
||||
|
||||
Reviewed By: #plasma, davidedmundson
|
||||
|
||||
Subscribers: davidedmundson, plasma-devel
|
||||
|
||||
Tags: #plasma
|
||||
|
||||
Differential Revision: https://phabricator.kde.org/D2967
|
||||
---
|
||||
shell/shellcorona.cpp | 5 +++++
|
||||
1 file changed, 5 insertions(+)
|
||||
|
||||
diff --git a/shell/shellcorona.cpp b/shell/shellcorona.cpp
|
||||
index 74f6ded..152ffeb 100644
|
||||
--- a/shell/shellcorona.cpp
|
||||
+++ b/shell/shellcorona.cpp
|
||||
@@ -1463,6 +1463,11 @@ void ShellCorona::activityAdded(const QString &id)
|
||||
void ShellCorona::activityRemoved(const QString &id)
|
||||
{
|
||||
m_activityContainmentPlugins.remove(id);
|
||||
+ if (m_desktopContainments.contains(id)) {
|
||||
+ for (auto cont : m_desktopContainments.value(id)) {
|
||||
+ cont->destroy();
|
||||
+ }
|
||||
+ }
|
||||
}
|
||||
|
||||
void ShellCorona::insertActivity(const QString &id, const QString &plugin)
|
||||
--
|
||||
2.7.4
|
||||
|
Loading…
Reference in new issue