Verified Commit a3d8270e authored by Linus Jahn's avatar Linus Jahn

Revert "Workaround KWin screenshot bug by using screenArea manually"

This reverts commit a0b8a970.

The workaround didn't work anyway. - The bug also affects Qt/QScreen
...
parent a0b8a970
......@@ -22,10 +22,8 @@
#include <QDateTime>
#include <QDBusPendingReply>
#include <QDebug>
#include <QFile>
#include <QGuiApplication>
#include <QScreen>
#include <QDebug>
#include <QStandardPaths>
#include <QProcess>
#include <QtConcurrent/QtConcurrent>
......@@ -83,11 +81,7 @@ void PhonePanel::toggleTorch()
void PhonePanel::takeScreenshot()
{
auto *interface = new org::kde::kwin::Screenshot(QStringLiteral("org.kde.KWin"), QStringLiteral("/Screenshot"), QDBusConnection::sessionBus(), this);
// screenshot fullscreen currently doesn't work on all devices -> we need to use screenshot area
// this won't work with multiple screens
QSize screenSize = QGuiApplication::primaryScreen()->size();
QDBusPendingReply<QString> reply = interface->screenshotArea(0, 0, screenSize.width(), screenSize.height());
QDBusPendingReply<QString> reply = interface->screenshotFullscreen();
QDBusPendingCallWatcher *watcher = new QDBusPendingCallWatcher(reply, this);
connect(watcher, &QDBusPendingCallWatcher::finished, this, [=](QDBusPendingCallWatcher *watcher) {
......
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