Commit 2053b3ac authored by Ivan Čukić's avatar Ivan Čukić 👁
Browse files

Free the activity switcher from the shackles of data engines

Most of the activity switcher has been ported away from data engines
a long time ago. The only place where the data engines are used in
the main switcher applet is to call toggleActivityManager dbus method
in PlasmaShell.

This patch introduces the toggleActivityManager member function into
the activities applet backend and ports the main switcher applet to
use it instead of the data engine.
parent 5edb4fc9
......@@ -57,9 +57,7 @@ DND.DropArea {
MouseArea {
anchors.fill: parent
onClicked: {
var service = dataSource.serviceForSource(activeSource)
var operation = service.operationDescription("toggleActivityManager")
......@@ -28,6 +28,8 @@
#include <QX11Info>
#include <QTimer>
#include <QDateTime>
#include <QDBusMessage>
#include <QDBusConnection>
// Qml and QtQuick
#include <QQuickImageProvider>
......@@ -526,4 +528,15 @@ void SwitcherBackend::setDropMode(bool value)
void SwitcherBackend::toggleActivityManager()
auto message = QDBusMessage::createMethodCall(
QDBusConnection::sessionBus().call(message, QDBus::NoBlock);
......@@ -76,6 +76,8 @@ public Q_SLOTS:
void dropMove(QMimeData* mimeData, const QVariant &activityId);
bool dropEnabled() const;
void toggleActivityManager();
template <typename Handler>
inline void registerShortcut(const QString &actionName, const QString &name,
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment