Home
Phabricator
Search
Log In
Paste
P371
Masterwork From Distant Lands
Active
Public
Actions
Authored by
davidedmundson
on Apr 15 2019, 1:40 PM.
Edit Paste
Archive Paste
View Raw File
Subscribe
Mute Notifications
Award Token
Flag For Later
Tags
None
Subscribers
None
commit 02e01c1658f27a840a01ce4d6d87b856d5dfcae6
Author: Aleix Pol <aleixpol@kde.org>
Date: Mon Apr 15 14:31:52 2019 +0100
Don't rescale every output every time outputs change - DAVID VERSION
Summary:
Every time a display gets connected/disconnected, every output will be
reinitialized. We don't really need to reset the scaling to 1 every time
we don't know, especially since the setting has been set voluntarily.
Test Plan: When I disconnect the external display, my laptop doesn't
fallback to scale=1.
Reviewers: #plasma
Subscribers: davidedmundson, ngraham, kwin
Tags: #kwin
Differential Revision: https://phabricator.kde.org/D20521
diff --git a/abstract_output.cpp b/abstract_output.cpp
index e2f1598e2..a100bda98 100644
--- a/abstract_output.cpp
+++ b/abstract_output.cpp
@@ -163,6 +163,7 @@ void AbstractOutput::setWaylandMode(const QSize &size, int refreshRate)
m_xdgOutput->setLogicalSize(pixelSize() / scale());
m_xdgOutput->done();
}
+ emit modeChanged();
}
void AbstractOutput::createXdgOutput()
diff --git a/plugins/platforms/drm/drm_backend.cpp b/plugins/platforms/drm/drm_backend.cpp
index 4f07d8c4c..e43e5ff70 100644
--- a/plugins/platforms/drm/drm_backend.cpp
+++ b/plugins/platforms/drm/drm_backend.cpp
@@ -514,7 +514,8 @@ void DrmBackend::readOutputsConfiguration()
const auto outputConfig = configGroup.group((*it)->uuid());
(*it)->setGlobalPos(outputConfig.readEntry<QPoint>("Position", pos));
// TODO: add mode
- (*it)->setScale(outputConfig.readEntry("Scale", 1.0));
+ if (outputConfig.hasKey("Scale"))
+ (*it)->setScale(outputConfig.readEntry("Scale", 1.0));
pos.setX(pos.x() + (*it)->geometry().width());
}
}
davidedmundson
edited the content of this paste.
(Show Details)
Apr 15 2019, 1:40 PM
davidedmundson
changed the title of this paste from untitled to
Masterwork From Distant Lands
.
Log In to Comment