From cbb4356b192d8401153d207ad14dbdbdaac2d6da Mon Sep 17 00:00:00 2001 From: Nicolas Werner Date: Sat, 25 Jul 2020 22:10:30 +0200 Subject: [PATCH] Fix more non integer heights --- resources/qml/delegates/ImageMessage.qml | 4 ++-- resources/qml/delegates/PlayableMediaMessage.qml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/qml/delegates/ImageMessage.qml b/resources/qml/delegates/ImageMessage.qml index 62d9de6..3885dda 100644 --- a/resources/qml/delegates/ImageMessage.qml +++ b/resources/qml/delegates/ImageMessage.qml @@ -9,8 +9,8 @@ Item { property double divisor: model.isReply ? 4 : 2 property bool tooHigh: tempHeight > timelineRoot.height / divisor - height: tooHigh ? timelineRoot.height / divisor : tempHeight - width: tooHigh ? (timelineRoot.height / divisor) / model.data.proportionalHeight : tempWidth + height: Math.round(tooHigh ? timelineRoot.height / divisor : tempHeight) + width: Math.round(tooHigh ? (timelineRoot.height / divisor) / model.data.proportionalHeight : tempWidth) Image { id: blurhash diff --git a/resources/qml/delegates/PlayableMediaMessage.qml b/resources/qml/delegates/PlayableMediaMessage.qml index bab524e..8d2fa8a 100644 --- a/resources/qml/delegates/PlayableMediaMessage.qml +++ b/resources/qml/delegates/PlayableMediaMessage.qml @@ -9,7 +9,7 @@ Rectangle { id: bg radius: 10 color: colors.dark - height: content.height + 24 + height: Math.round(content.height + 24) width: parent ? parent.width : undefined Column {