diff options
author | Joseph Donofry <joedonofry@gmail.com> | 2021-11-11 00:16:25 -0500 |
---|---|---|
committer | Joseph Donofry <joedonofry@gmail.com> | 2021-11-11 00:16:25 -0500 |
commit | c5e8b2da15a65622d1783c19afeeb0ad4aebc4b8 (patch) | |
tree | a70dfd9f085a628846c05bb721dbf48d50a8602d /resources/qml/delegates | |
parent | More player fixes (diff) | |
download | nheko-c5e8b2da15a65622d1783c19afeeb0ad4aebc4b8.tar.xz |
More refactoring and layout updates
Diffstat (limited to 'resources/qml/delegates')
-rw-r--r-- | resources/qml/delegates/PlayableMediaMessage.qml | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/resources/qml/delegates/PlayableMediaMessage.qml b/resources/qml/delegates/PlayableMediaMessage.qml index e6bcdcac..2b4c4d49 100644 --- a/resources/qml/delegates/PlayableMediaMessage.qml +++ b/resources/qml/delegates/PlayableMediaMessage.qml @@ -7,7 +7,7 @@ import "../ui/media" import QtMultimedia 5.15 import QtQuick 2.15 import QtQuick.Controls 2.15 -import QtQuick.Layouts 1.2 +import QtQuick.Layouts 1.15 import im.nheko 1.0 ColumnLayout { @@ -45,8 +45,8 @@ ColumnLayout { property bool tooHigh: tempHeight > timelineRoot.height / divisor color: type == MtxEvent.VideoMessage ? Nheko.colors.window : "transparent" - Layout.preferredHeight: type == MtxEvent.VideoMessage ? tooHigh ? timelineRoot.height / divisor : tempHeight : 40 - Layout.preferredWidth: tooHigh ? (timelineRoot.height / divisor) / proportionalHeight : tempWidth + Layout.preferredHeight: type == MtxEvent.VideoMessage ? tooHigh ? timelineRoot.height / divisor : tempHeight : 80 + Layout.preferredWidth: type == MtxEvent.VideoMessage ? tooHigh ? (timelineRoot.height / divisor) / proportionalHeight : tempWidth : 250 Image { anchors.fill: parent @@ -73,11 +73,11 @@ ColumnLayout { y: type == MtxEvent.VideoMessage ? videoOutput.contentRect.y : videoContainer.y width: type == MtxEvent.VideoMessage ? videoOutput.contentRect.width : videoContainer.width height: type == MtxEvent.VideoMessage ? videoOutput.contentRect.height : videoContainer.height + playingVideo: type == MtxEvent.VideoMessage positionValue: mxcmedia.position duration: mxcmedia.duration mediaLoaded: mxcmedia.loaded mediaState: mxcmedia.state - volumeOrientation: Qt.Vertical onPositionChanged: mxcmedia.position = position onPlayPauseActivated: mxcmedia.state == MediaPlayer.PlayingState ? mxcmedia.pause() : mxcmedia.play() onLoadActivated: mxcmedia.eventId = eventId |