summary refs log tree commit diff
path: root/resources/qml/TimelineRow.qml
diff options
context:
space:
mode:
Diffstat (limited to 'resources/qml/TimelineRow.qml')
-rw-r--r--resources/qml/TimelineRow.qml22
1 files changed, 11 insertions, 11 deletions
diff --git a/resources/qml/TimelineRow.qml b/resources/qml/TimelineRow.qml
index d9deefa0..07cb5ce2 100644
--- a/resources/qml/TimelineRow.qml
+++ b/resources/qml/TimelineRow.qml
@@ -54,7 +54,7 @@ AbstractButton {
     height: row.height+(reactionRow.height > 0 ? reactionRow.height-2 : 0 )+unreadRow.height
 
     Rectangle {
-        color: (Settings.messageHoverHighlight && hovered) ? Nheko.colors.alternateBase : "transparent"
+        color: (Settings.messageHoverHighlight && hovered) ? palette.alternateBase : "transparent"
         anchors.fill: parent
         // this looks better without margins
         TapHandler {
@@ -112,7 +112,7 @@ AbstractButton {
         Rectangle {
             id: threadLine
 
-            color: TimelineManager.userColor(threadId, Nheko.colors.base)
+            color: TimelineManager.userColor(threadId, palette.base)
             anchors.fill: parent
         }
 
@@ -133,8 +133,8 @@ AbstractButton {
         width: Settings.bubbles? Math.min(maxWidth,Math.max(reply.implicitWidth+8,contentItem.implicitWidth+metadata.width+20)) : maxWidth
         height: msg.height+msg.anchors.margins*2
 
-        property color userColor: TimelineManager.userColor(userId, Nheko.colors.base)
-        property color bgColor: Nheko.colors.base
+        property color userColor: TimelineManager.userColor(userId, palette.base)
+        property color bgColor: palette.base
         color: (Settings.bubbles && !isStateEvent) ? Qt.tint(bgColor, Qt.hsla(userColor.hslHue, 0.5, userColor.hslLightness, 0.2)) : "#00000000"
         radius: 4
         border.width: r.notificationlevel == MtxEvent.Highlight ? 1 : 0
@@ -169,7 +169,7 @@ AbstractButton {
                     return replyTo != "" ? room.dataById(replyTo, role, r.eventId) : null;
                 }
                 visible: replyTo
-                userColor: r.relatedEventCacheBuster, TimelineManager.userColor(userId, Nheko.colors.base)
+                userColor: r.relatedEventCacheBuster, TimelineManager.userColor(userId, palette.base)
                 blurhash: r.relatedEventCacheBuster, fromModel(Room.Blurhash) ?? ""
                 body: r.relatedEventCacheBuster, fromModel(Room.Body) ?? ""
                 formattedBody: r.relatedEventCacheBuster, fromModel(Room.FormattedBody) ?? ""
@@ -186,11 +186,11 @@ AbstractButton {
                 userId: r.relatedEventCacheBuster, fromModel(Room.UserId) ?? ""
                 userName: r.relatedEventCacheBuster, fromModel(Room.UserName) ?? ""
                 thumbnailUrl: r.relatedEventCacheBuster, fromModel(Room.ThumbnailUrl) ?? ""
-                duration: r.relatedEventCacheBuster, fromModel(Room.Duration) ?? ""
+                duration: r.relatedEventCacheBuster, fromModel(Room.Duration) ?? 0
                 roomTopic: r.relatedEventCacheBuster, fromModel(Room.RoomTopic) ?? ""
                 roomName: r.relatedEventCacheBuster, fromModel(Room.RoomName) ?? ""
                 callType: r.relatedEventCacheBuster, fromModel(Room.CallType) ?? ""
-                encryptionError: r.relatedEventCacheBuster, fromModel(Room.EncryptionError) ?? ""
+                encryptionError: r.relatedEventCacheBuster, fromModel(Room.EncryptionError) ?? 0
                 relatedEventCacheBuster: r.relatedEventCacheBuster, fromModel(Room.RelatedEventCacheBuster) ?? 0
             }
 
@@ -260,7 +260,7 @@ AbstractButton {
                     width: parent.iconSize
                     sourceSize.width: parent.iconSize * Screen.devicePixelRatio
                     sourceSize.height: parent.iconSize * Screen.devicePixelRatio
-                    source: "image://colorimage/:/icons/icons/ui/edit.svg?" + ((eventId == room.edit) ? Nheko.colors.highlight : Nheko.colors.buttonText)
+                    source: "image://colorimage/:/icons/icons/ui/edit.svg?" + ((eventId == room.edit) ? palette.highlight : palette.buttonText)
                     ToolTip.visible: editHovered.hovered
                     ToolTip.delay: Nheko.tooltipDelay
                     ToolTip.text: qsTr("Edited")
@@ -278,7 +278,7 @@ AbstractButton {
                     height: parent.iconSize
                     width: parent.iconSize
                     image: ":/icons/icons/ui/thread.svg"
-                    buttonTextColor: TimelineManager.userColor(threadId, Nheko.colors.base)
+                    buttonTextColor: TimelineManager.userColor(threadId, palette.base)
                     ToolTip.visible: hovered
                     ToolTip.delay: Nheko.tooltipDelay
                     ToolTip.text: qsTr("Part of a thread")
@@ -303,7 +303,7 @@ AbstractButton {
                     Layout.alignment: Qt.AlignRight | Qt.AlignTop
                     Layout.preferredWidth: implicitWidth
                     text: timestamp.toLocaleTimeString(Locale.ShortFormat)
-                    color: Nheko.inactiveColors.text
+                    color: palette.inactive.text
                     ToolTip.visible: ma.hovered
                     ToolTip.delay: Nheko.tooltipDelay
                     ToolTip.text: Qt.formatDateTime(timestamp, Qt.DefaultLocaleLongDate)
@@ -341,7 +341,7 @@ AbstractButton {
             left: parent.left
             right: parent.right
         }
-        color: Nheko.colors.highlight
+        color: palette.highlight
         
         visible: (r.index > 0 && (room.fullyReadEventId == r.eventId))
         height: visible ? 3 : 0