summary refs log tree commit diff
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2022-02-17 00:42:57 +0100
committerNicolas Werner <nicolas.werner@hotmail.de>2022-02-17 00:42:57 +0100
commitc0f415238dbaefc5c88bbe875b9a9bd975180e8c (patch)
tree68cc040d696f4a4ce8fa248e2092ebf9823c3968
parentFix hover highlight when hovering hover menu (diff)
downloadnheko-c0f415238dbaefc5c88bbe875b9a9bd975180e8c.tar.xz
Fix images without size not showing (take5)
-rw-r--r--resources/qml/delegates/ImageMessage.qml4
1 files changed, 3 insertions, 1 deletions
diff --git a/resources/qml/delegates/ImageMessage.qml b/resources/qml/delegates/ImageMessage.qml

index fea3eaef..7664d6fd 100644 --- a/resources/qml/delegates/ImageMessage.qml +++ b/resources/qml/delegates/ImageMessage.qml
@@ -19,7 +19,9 @@ Item { required property string eventId property double divisor: isReply ? 5 : 3 - implicitWidth: Math.round(originalWidth*Math.min((timelineView.height/divisor)/(originalWidth*proportionalHeight), 1)) + property int tempWidth: originalWidth < 1? 400: originalWidth + + implicitWidth: Math.round(tempWidth*Math.min((timelineView.height/divisor)/(tempWidth*proportionalHeight), 1)) width: Math.min(parent.width,implicitWidth) height: width*proportionalHeight