mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-22 19:08:58 +03:00
Fix more anchors.centerIn
This commit is contained in:
parent
b43562d4f5
commit
fcc1358e6b
3 changed files with 15 additions and 4 deletions
|
@ -25,12 +25,11 @@ ImageButton {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
if (model.state == MtxEvent.Read)
|
if (model.state == MtxEvent.Read)
|
||||||
TimelineManager.timeline.readReceiptsAction(model.id);
|
TimelineManager.timeline.readReceiptsAction(model.id);
|
||||||
}
|
|
||||||
|
|
||||||
|
}
|
||||||
image: {
|
image: {
|
||||||
switch (model.state) {
|
switch (model.state) {
|
||||||
case MtxEvent.Failed:
|
case MtxEvent.Failed:
|
||||||
|
|
|
@ -8,7 +8,13 @@ Popup {
|
||||||
property var image
|
property var image
|
||||||
|
|
||||||
modal: true
|
modal: true
|
||||||
anchors.centerIn: parent
|
// 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;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Image {
|
Image {
|
||||||
|
|
|
@ -6,7 +6,13 @@ import im.nheko 1.0
|
||||||
|
|
||||||
Popup {
|
Popup {
|
||||||
modal: true
|
modal: true
|
||||||
anchors.centerIn: parent
|
// 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;
|
||||||
|
|
||||||
|
}
|
||||||
palette: colors
|
palette: colors
|
||||||
|
|
||||||
Component {
|
Component {
|
||||||
|
|
Loading…
Reference in a new issue