mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-26 04:58:49 +03:00
Don't use centerIn on popup on Qt < 5.12
This commit is contained in:
parent
826a5cfb14
commit
14cb3bfe10
1 changed files with 7 additions and 1 deletions
|
@ -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
|
||||
|
||||
|
|
Loading…
Reference in a new issue