summary refs log tree commit diff
path: root/resources/qml/delegates
diff options
context:
space:
mode:
Diffstat (limited to 'resources/qml/delegates')
-rw-r--r--resources/qml/delegates/ImageMessage.qml6
-rw-r--r--resources/qml/delegates/PlayableMediaMessage.qml6
-rw-r--r--resources/qml/delegates/TextMessage.qml2
3 files changed, 7 insertions, 7 deletions
diff --git a/resources/qml/delegates/ImageMessage.qml b/resources/qml/delegates/ImageMessage.qml

index 704af3fe..ce8e779c 100644 --- a/resources/qml/delegates/ImageMessage.qml +++ b/resources/qml/delegates/ImageMessage.qml
@@ -9,10 +9,10 @@ Item { property double tempWidth: Math.min(parent ? parent.width : undefined, model.data.width < 1 ? parent.width : model.data.width) property double tempHeight: tempWidth * model.data.proportionalHeight property double divisor: model.isReply ? 5 : 3 - property bool tooHigh: tempHeight > timelineRoot.height / divisor + property bool tooHigh: tempHeight > timelineView.height / divisor - height: Math.round(tooHigh ? timelineRoot.height / divisor : tempHeight) - width: Math.round(tooHigh ? (timelineRoot.height / divisor) / model.data.proportionalHeight : tempWidth) + height: Math.round(tooHigh ? timelineView.height / divisor : tempHeight) + width: Math.round(tooHigh ? (timelineView.height / divisor) / model.data.proportionalHeight : tempWidth) Image { id: blurhash diff --git a/resources/qml/delegates/PlayableMediaMessage.qml b/resources/qml/delegates/PlayableMediaMessage.qml
index 223c2a34..0234495d 100644 --- a/resources/qml/delegates/PlayableMediaMessage.qml +++ b/resources/qml/delegates/PlayableMediaMessage.qml
@@ -29,11 +29,11 @@ Rectangle { property double tempWidth: Math.min(parent ? parent.width : undefined, model.data.width < 1 ? 400 : model.data.width) property double tempHeight: tempWidth * model.data.proportionalHeight property double divisor: model.isReply ? 4 : 2 - property bool tooHigh: tempHeight > timelineRoot.height / divisor + property bool tooHigh: tempHeight > timelineView.height / divisor visible: model.data.type == MtxEvent.VideoMessage - height: tooHigh ? timelineRoot.height / divisor : tempHeight - width: tooHigh ? (timelineRoot.height / divisor) / model.data.proportionalHeight : tempWidth + height: tooHigh ? timelineView.height / divisor : tempHeight + width: tooHigh ? (timelineView.height / divisor) / model.data.proportionalHeight : tempWidth Image { anchors.fill: parent diff --git a/resources/qml/delegates/TextMessage.qml b/resources/qml/delegates/TextMessage.qml
index 810ee3d4..ae622480 100644 --- a/resources/qml/delegates/TextMessage.qml +++ b/resources/qml/delegates/TextMessage.qml
@@ -11,7 +11,7 @@ MatrixText { text: "<style type=\"text/css\">a { color:" + Nheko.colors.link + ";}\ncode { background-color: " + Nheko.colors.alternateBase + ";}</style>" + formatted.replace("<pre>", "<pre style='white-space: pre-wrap; background-color: " + Nheko.colors.alternateBase + "'>") width: parent ? parent.width : undefined - height: isReply ? Math.round(Math.min(timelineRoot.height / 8, implicitHeight)) : undefined + height: isReply ? Math.round(Math.min(timelineView.height / 8, implicitHeight)) : undefined clip: isReply selectByMouse: !Settings.mobileMode && !isReply font.pointSize: (Settings.enlargeEmojiOnlyMessages && model.data.isOnlyEmoji > 0 && model.data.isOnlyEmoji < 4) ? Settings.fontSize * 3 : Settings.fontSize