drm cursor scaling

Summary:
Cursors are drawn low level, so need to go from global compositor space
to device space
(multiplied by the out scale)

Test Plan: Elements interacted underneath where the mouse was

Reviewers: #plasma

Subscribers: plasma-devel, kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D3499
This commit is contained in:
David Edmundson 2016-11-15 09:45:33 +00:00
parent 0dac5d6bfe
commit add93b3e36

View file

@ -108,7 +108,7 @@ void DrmOutput::showCursor(DrmBuffer *c)
void DrmOutput::moveCursor(const QPoint &globalPos)
{
const QPoint p = globalPos - m_globalPos;
const QPoint p = (globalPos - m_globalPos) * m_scale;
drmModeMoveCursor(m_backend->fd(), m_crtcId, p.x(), p.y());
}