summaryrefslogtreecommitdiff
path: root/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
diff options
context:
space:
mode:
authorJohan Klokkhammer Helsing <johan.helsing@qt.io>2016-06-08 12:16:49 +0200
committerJohan Helsing <johan.helsing@qt.io>2016-06-08 12:26:42 +0000
commit78354b392beffbdebb86dcdc3af33dba05f378dd (patch)
treecb2308161094dfd5ef2eaa7e450fb9221c489df1 /src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
parentd9cef40ea3948e5d74120fb07909332503dc485b (diff)
downloadqtwayland-78354b392beffbdebb86dcdc3af33dba05f378dd.tar.gz
Fix content positioning relative to decoration on scaled outputs
Only the width and height were scaled previously, causing an incorrect offset from the lower left corner, resulting in a small transparent gap to form between the decoration and the content on the right and top. Change-Id: I0b253c05c9b260d9ff3a6ab5f8aea42370561959 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@gmail.com>
Diffstat (limited to 'src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp')
-rw-r--r--src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
index 18ed1d61..4599fa4c 100644
--- a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
+++ b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
@@ -200,7 +200,7 @@ public:
m_blitProgram->setAttributeArray(0, squareVertices, 2);
glBindTexture(GL_TEXTURE_2D, window->contentTexture());
QRect r = window->contentsRect();
- glViewport(r.x(), r.y(), r.width() * scale, r.height() * scale);
+ glViewport(r.x() * scale, r.y() * scale, r.width() * scale, r.height() * scale);
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
//Cleanup