From 14cb3bfe10202e47ad7cdee749f4bcb88794abe7 Mon Sep 17 00:00:00 2001 From: Nicolas Werner Date: Tue, 12 Jan 2021 15:55:36 +0100 Subject: [PATCH] Don't use centerIn on popup on Qt < 5.12 --- resources/qml/voip/CallDevices.qml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/resources/qml/voip/CallDevices.qml b/resources/qml/voip/CallDevices.qml index 8b30c540..fd6b6005 100644 --- a/resources/qml/voip/CallDevices.qml +++ b/resources/qml/voip/CallDevices.qml @@ -5,9 +5,15 @@ import im.nheko 1.0 Popup { modal: true - anchors.centerIn: parent palette: colors + // only set the anchors on Qt 5.12 or higher + // see https://doc.qt.io/qt-5/qml-qtquick-controls2-popup.html#anchors.centerIn-prop + Component.onCompleted: { + if (anchors) + anchors.centerIn = parent; + } + ColumnLayout { spacing: 16