summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJohan Klokkhammer Helsing <johan.helsing@qt.io>2017-04-12 10:13:07 +0200
committerJohan Helsing <johan.helsing@qt.io>2017-04-19 09:52:03 +0000
commita5dd3692697fcf905749b5686d5d7bfbf47969e1 (patch)
tree7561cbfa15026bba62c6ee39722e2e82bd57393b
parentdcff152a9b010455af1c1a29e5470f1350a48fe3 (diff)
Don't try to create zxdg_popup_v6s with incomplete positioners
A positioner without a size is considered incomplete, and creating a popup with an incomplete positioner is a protocol error. Change-Id: I5efdba0edfe6edc5f7b0a4908c1e43b93d35eea8 Reviewed-by: Pier Luigi Fiorini <pierluigi.fiorini@liri.io> Reviewed-by: Jan Arne Petersen <jan.petersen@kdab.com> Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
-rw-r--r--src/client/qwaylandxdgshellv6.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/client/qwaylandxdgshellv6.cpp b/src/client/qwaylandxdgshellv6.cpp
index 687973240..b50b6b1cf 100644
--- a/src/client/qwaylandxdgshellv6.cpp
+++ b/src/client/qwaylandxdgshellv6.cpp
@@ -199,6 +199,7 @@ void QWaylandXdgSurfaceV6::setPopup(QWaylandWindow *parent, QWaylandInputDevice
positioner->set_anchor_rect(transientPos.x(), transientPos.y(), 1, 1);
positioner->set_anchor(QtWayland::zxdg_positioner_v6::anchor_top | QtWayland::zxdg_positioner_v6::anchor_left);
positioner->set_gravity(QtWayland::zxdg_positioner_v6::gravity_bottom | QtWayland::zxdg_positioner_v6::gravity_right);
+ positioner->set_size(m_window->geometry().width(), m_window->geometry().height());
m_popup = new Popup(this, parentXdgSurface, positioner);
positioner->destroy();
delete positioner;