mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-25 12:38:48 +03:00
Fix palette access and QMediaPlayer errors
This commit is contained in:
parent
e85a1d4aeb
commit
54e2295c21
88 changed files with 426 additions and 480 deletions
|
@ -24,7 +24,7 @@ AbstractButton {
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
id: bg
|
id: bg
|
||||||
radius: Settings.avatarCircles ? height / 2 : height / 8
|
radius: Settings.avatarCircles ? height / 2 : height / 8
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
|
@ -39,7 +39,7 @@ AbstractButton {
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
visible: img.status != Image.Ready && !Settings.useIdenticon
|
visible: img.status != Image.Ready && !Settings.useIdenticon
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Image {
|
Image {
|
||||||
|
@ -109,7 +109,7 @@ AbstractButton {
|
||||||
}
|
}
|
||||||
|
|
||||||
Ripple {
|
Ripple {
|
||||||
color: Qt.rgba(Nheko.colors.alternateBase.r, Nheko.colors.alternateBase.g, Nheko.colors.alternateBase.b, 0.5)
|
color: Qt.rgba(palette.alternateBase.r, palette.alternateBase.g, palette.alternateBase.b, 0.5)
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,7 @@ import QtQml 2.15
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: chatPage
|
id: chatPage
|
||||||
|
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
|
@ -78,11 +78,11 @@ Page {
|
||||||
delegate: ItemDelegate {
|
delegate: ItemDelegate {
|
||||||
id: communityItem
|
id: communityItem
|
||||||
|
|
||||||
property color backgroundColor: Nheko.colors.window
|
property color backgroundColor: palette.window
|
||||||
property color importantText: Nheko.colors.text
|
property color importantText: palette.text
|
||||||
property color unimportantText: Nheko.colors.buttonText
|
property color unimportantText: palette.buttonText
|
||||||
property color bubbleBackground: Nheko.colors.highlight
|
property color bubbleBackground: palette.highlight
|
||||||
property color bubbleText: Nheko.colors.highlightedText
|
property color bubbleText: palette.highlightedText
|
||||||
required property var model
|
required property var model
|
||||||
|
|
||||||
height: avatarSize + 2 * Nheko.paddingMedium
|
height: avatarSize + 2 * Nheko.paddingMedium
|
||||||
|
@ -100,11 +100,11 @@ Page {
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: communityItem
|
target: communityItem
|
||||||
backgroundColor: Nheko.colors.dark
|
backgroundColor: palette.dark
|
||||||
importantText: Nheko.colors.brightText
|
importantText: palette.brightText
|
||||||
unimportantText: Nheko.colors.brightText
|
unimportantText: palette.brightText
|
||||||
bubbleBackground: Nheko.colors.highlight
|
bubbleBackground: palette.highlight
|
||||||
bubbleText: Nheko.colors.highlightedText
|
bubbleText: palette.highlightedText
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
|
@ -114,11 +114,11 @@ Page {
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: communityItem
|
target: communityItem
|
||||||
backgroundColor: Nheko.colors.highlight
|
backgroundColor: palette.highlight
|
||||||
importantText: Nheko.colors.highlightedText
|
importantText: palette.highlightedText
|
||||||
unimportantText: Nheko.colors.highlightedText
|
unimportantText: palette.highlightedText
|
||||||
bubbleBackground: Nheko.colors.highlightedText
|
bubbleBackground: palette.highlightedText
|
||||||
bubbleText: Nheko.colors.highlight
|
bubbleText: palette.highlight
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -127,8 +127,8 @@ Control {
|
||||||
|
|
||||||
ListView.delayRemove: true
|
ListView.delayRemove: true
|
||||||
|
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlight : Nheko.colors.base
|
color: model.index == popup.currentIndex ? palette.highlight : palette.base
|
||||||
height: chooser.child.implicitHeight + 2 * popup.rowMargin
|
height: (chooser.child?.implicitHeight ?? 0) + 2 * popup.rowMargin
|
||||||
implicitWidth: fullWidth ? ListView.view.width : chooser.child.implicitWidth + 4
|
implicitWidth: fullWidth ? ListView.view.width : chooser.child.implicitWidth + 4
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
|
@ -146,7 +146,7 @@ Control {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Ripple {
|
Ripple {
|
||||||
color: Qt.rgba(Nheko.colors.base.r, Nheko.colors.base.g, Nheko.colors.base.b, 0.5)
|
color: Qt.rgba(palette.base.r, palette.base.g, palette.base.b, 0.5)
|
||||||
}
|
}
|
||||||
|
|
||||||
DelegateChooser {
|
DelegateChooser {
|
||||||
|
@ -177,12 +177,12 @@ Control {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: model.displayName
|
text: model.displayName
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: "(" + model.userid + ")"
|
text: "(" + model.userid + ")"
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.buttonText
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.buttonText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -201,7 +201,7 @@ Control {
|
||||||
Label {
|
Label {
|
||||||
visible: !!model.unicode
|
visible: !!model.unicode
|
||||||
text: model.unicode
|
text: model.unicode
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
|
||||||
font: Settings.emojiFont
|
font: Settings.emojiFont
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -220,12 +220,12 @@ Control {
|
||||||
Layout.leftMargin: Nheko.paddingSmall
|
Layout.leftMargin: Nheko.paddingSmall
|
||||||
Layout.rightMargin: Nheko.paddingSmall
|
Layout.rightMargin: Nheko.paddingSmall
|
||||||
text: model.shortcode
|
text: model.shortcode
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: "(" + model.packname + ")"
|
text: "(" + model.packname + ")"
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.buttonText
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.buttonText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -243,13 +243,13 @@ Control {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: model.name
|
text: model.name
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
|
||||||
font.bold: true
|
font.bold: true
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: model.description
|
text: model.description
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.buttonText
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.buttonText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -277,7 +277,7 @@ Control {
|
||||||
Label {
|
Label {
|
||||||
text: model.roomName
|
text: model.roomName
|
||||||
font.pixelSize: popup.avatarHeight * 0.5
|
font.pixelSize: popup.avatarHeight * 0.5
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
|
||||||
font.italic: model.isTombstoned
|
font.italic: model.isTombstoned
|
||||||
textFormat: Text.RichText
|
textFormat: Text.RichText
|
||||||
}
|
}
|
||||||
|
@ -306,14 +306,14 @@ Control {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: model.roomName
|
text: model.roomName
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
|
||||||
font.italic: model.isTombstoned
|
font.italic: model.isTombstoned
|
||||||
textFormat: Text.RichText
|
textFormat: Text.RichText
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: "(" + model.roomAlias + ")"
|
text: "(" + model.roomAlias + ")"
|
||||||
color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.buttonText
|
color: model.index == popup.currentIndex ? palette.highlightedText : palette.buttonText
|
||||||
textFormat: Text.RichText
|
textFormat: Text.RichText
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -329,8 +329,8 @@ Control {
|
||||||
|
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.base
|
color: palette.base
|
||||||
border.color: Nheko.colors.mid
|
border.color: palette.mid
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,7 @@ Label {
|
||||||
property alias elideWidth: metrics.elideWidth
|
property alias elideWidth: metrics.elideWidth
|
||||||
property int fullTextWidth: Math.ceil(metrics.advanceWidth)
|
property int fullTextWidth: Math.ceil(metrics.advanceWidth)
|
||||||
|
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: (textFormat == Text.PlainText) ? metrics.elidedText : TimelineManager.escapeEmoji(metrics.elidedText)
|
text: (textFormat == Text.PlainText) ? metrics.elidedText : TimelineManager.escapeEmoji(metrics.elidedText)
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
|
|
|
@ -43,7 +43,7 @@ Image {
|
||||||
case Crypto.Verified:
|
case Crypto.Verified:
|
||||||
return sourceUrl + Nheko.theme.green;
|
return sourceUrl + Nheko.theme.green;
|
||||||
case Crypto.TOFU:
|
case Crypto.TOFU:
|
||||||
return sourceUrl + Nheko.colors.buttonText;
|
return sourceUrl + palette.buttonText;
|
||||||
default:
|
default:
|
||||||
return sourceUrl + Nheko.theme.error;
|
return sourceUrl + Nheko.theme.error;
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,7 +19,6 @@ Popup {
|
||||||
x: Math.round(parent.width / 2 - width / 2)
|
x: Math.round(parent.width / 2 - width / 2)
|
||||||
y: Math.round(parent.height / 4)
|
y: Math.round(parent.height / 4)
|
||||||
modal: true
|
modal: true
|
||||||
palette: Nheko.colors
|
|
||||||
parent: Overlay.overlay
|
parent: Overlay.overlay
|
||||||
width: timelineRoot.width * 0.8
|
width: timelineRoot.width * 0.8
|
||||||
leftPadding: 10
|
leftPadding: 10
|
||||||
|
@ -39,7 +38,7 @@ Popup {
|
||||||
text: qsTr("Forward Message")
|
text: qsTr("Forward Message")
|
||||||
font.bold: true
|
font.bold: true
|
||||||
bottomPadding: 10
|
bottomPadding: 10
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Reply {
|
Reply {
|
||||||
|
@ -50,7 +49,7 @@ Popup {
|
||||||
|
|
||||||
width: parent.width
|
width: parent.width
|
||||||
|
|
||||||
userColor: TimelineManager.userColor(modelData.userId, Nheko.colors.window)
|
userColor: TimelineManager.userColor(modelData.userId, palette.window)
|
||||||
blurhash: modelData.blurhash ?? ""
|
blurhash: modelData.blurhash ?? ""
|
||||||
body: modelData.body ?? ""
|
body: modelData.body ?? ""
|
||||||
formattedBody: modelData.formattedBody ?? ""
|
formattedBody: modelData.formattedBody ?? ""
|
||||||
|
@ -72,7 +71,7 @@ Popup {
|
||||||
id: roomTextInput
|
id: roomTextInput
|
||||||
|
|
||||||
width: forwardMessagePopup.width - forwardMessagePopup.leftPadding * 2
|
width: forwardMessagePopup.width - forwardMessagePopup.leftPadding * 2
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
onTextEdited: {
|
onTextEdited: {
|
||||||
completerPopup.completer.searchString = text;
|
completerPopup.completer.searchString = text;
|
||||||
}
|
}
|
||||||
|
@ -123,11 +122,11 @@ Popup {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
}
|
}
|
||||||
|
|
||||||
Overlay.modal: Rectangle {
|
Overlay.modal: Rectangle {
|
||||||
color: Qt.rgba(Nheko.colors.window.r, Nheko.colors.window.g, Nheko.colors.window.b, 0.7)
|
color: Qt.rgba(palette.window.r, palette.window.g, palette.window.b, 0.7)
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,8 +12,8 @@ AbstractButton {
|
||||||
|
|
||||||
property alias cursor: mouseArea.cursorShape
|
property alias cursor: mouseArea.cursorShape
|
||||||
property string image: undefined
|
property string image: undefined
|
||||||
property color highlightColor: Nheko.colors.highlight
|
property color highlightColor: palette.highlight
|
||||||
property color buttonTextColor: Nheko.colors.buttonText
|
property color buttonTextColor: palette.buttonText
|
||||||
property bool changeColorOnHover: true
|
property bool changeColorOnHover: true
|
||||||
property bool ripple: true
|
property bool ripple: true
|
||||||
|
|
||||||
|
|
|
@ -18,7 +18,7 @@ TextEdit {
|
||||||
selectByMouse: !Settings.mobileMode
|
selectByMouse: !Settings.mobileMode
|
||||||
// this always has to be enabled, otherwise you can't click links anymore!
|
// this always has to be enabled, otherwise you can't click links anymore!
|
||||||
//enabled: selectByMouse
|
//enabled: selectByMouse
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
onLinkActivated: Nheko.openLink(link)
|
onLinkActivated: Nheko.openLink(link)
|
||||||
ToolTip.visible: hoveredLink || false
|
ToolTip.visible: hoveredLink || false
|
||||||
ToolTip.text: hoveredLink
|
ToolTip.text: hoveredLink
|
||||||
|
|
|
@ -10,7 +10,7 @@ import im.nheko 1.0
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: c
|
id: c
|
||||||
property color backgroundColor: Nheko.colors.base
|
property color backgroundColor: palette.base
|
||||||
property alias color: labelC.color
|
property alias color: labelC.color
|
||||||
property alias textPadding: input.padding
|
property alias textPadding: input.padding
|
||||||
property alias text: input.text
|
property alias text: input.text
|
||||||
|
@ -61,8 +61,7 @@ ColumnLayout {
|
||||||
y: contentHeight + input.padding + Nheko.paddingSmall
|
y: contentHeight + input.padding + Nheko.paddingSmall
|
||||||
enabled: false
|
enabled: false
|
||||||
|
|
||||||
palette: Nheko.colors
|
color: palette.text
|
||||||
color: Nheko.colors.text
|
|
||||||
font.pixelSize: input.font.pixelSize
|
font.pixelSize: input.font.pixelSize
|
||||||
font.weight: Font.DemiBold
|
font.weight: Font.DemiBold
|
||||||
font.letterSpacing: input.font.pixelSize * 0.02
|
font.letterSpacing: input.font.pixelSize * 0.02
|
||||||
|
@ -114,7 +113,6 @@ ColumnLayout {
|
||||||
id: input
|
id: input
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
palette: Nheko.colors
|
|
||||||
color: labelC.color
|
color: labelC.color
|
||||||
opacity: labelC.text ? 0 : 1
|
opacity: labelC.text ? 0 : 1
|
||||||
focus: true
|
focus: true
|
||||||
|
@ -156,7 +154,7 @@ ColumnLayout {
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
color: Nheko.colors.highlight
|
color: palette.highlight
|
||||||
height: 1
|
height: 1
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
@ -166,7 +164,7 @@ ColumnLayout {
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
height: parent.height*2
|
height: parent.height*2
|
||||||
width: 0
|
width: 0
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
states: State {
|
states: State {
|
||||||
name: "focused"
|
name: "focused"
|
||||||
|
|
|
@ -16,7 +16,7 @@ Rectangle {
|
||||||
|
|
||||||
readonly property string text: messageInput.text
|
readonly property string text: messageInput.text
|
||||||
|
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: row.implicitHeight
|
Layout.preferredHeight: row.implicitHeight
|
||||||
Layout.minimumHeight: 40
|
Layout.minimumHeight: 40
|
||||||
|
@ -90,7 +90,7 @@ Rectangle {
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
visible: room && room.input.uploading
|
visible: room && room.input.uploading
|
||||||
|
|
||||||
Spinner {
|
Spinner {
|
||||||
|
@ -144,8 +144,8 @@ Rectangle {
|
||||||
|
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
placeholderText: qsTr("Write a message...")
|
placeholderText: qsTr("Write a message...")
|
||||||
placeholderTextColor: Nheko.colors.buttonText
|
placeholderTextColor: palette.buttonText
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
width: textInput.width
|
width: textInput.width
|
||||||
verticalAlignment: TextEdit.AlignVCenter
|
verticalAlignment: TextEdit.AlignVCenter
|
||||||
wrapMode: TextEdit.Wrap
|
wrapMode: TextEdit.Wrap
|
||||||
|
@ -192,8 +192,8 @@ Rectangle {
|
||||||
onSelectionStartChanged: room.input.updateState(selectionStart, selectionEnd, cursorPosition, text)
|
onSelectionStartChanged: room.input.updateState(selectionStart, selectionEnd, cursorPosition, text)
|
||||||
onSelectionEndChanged: room.input.updateState(selectionStart, selectionEnd, cursorPosition, text)
|
onSelectionEndChanged: room.input.updateState(selectionStart, selectionEnd, cursorPosition, text)
|
||||||
// Ensure that we get escape key press events first.
|
// Ensure that we get escape key press events first.
|
||||||
Keys.onShortcutOverride: event.accepted = (popup.opened && (event.key === Qt.Key_Escape || event.key === Qt.Key_Tab || event.key === Qt.Key_Enter || event.key === Qt.Key_Space))
|
Keys.onShortcutOverride: (event) => event.accepted = (popup.opened && (event.key === Qt.Key_Escape || event.key === Qt.Key_Tab || event.key === Qt.Key_Enter || event.key === Qt.Key_Space))
|
||||||
Keys.onPressed: {
|
Keys.onPressed: (event) => {
|
||||||
if (event.matches(StandardKey.Paste)) {
|
if (event.matches(StandardKey.Paste)) {
|
||||||
event.accepted = room.input.tryPasteAttachment(false);
|
event.accepted = room.input.tryPasteAttachment(false);
|
||||||
} else if (event.key == Qt.Key_Space) {
|
} else if (event.key == Qt.Key_Space) {
|
||||||
|
@ -438,7 +438,6 @@ Rectangle {
|
||||||
StickerPicker {
|
StickerPicker {
|
||||||
id: stickerPopup
|
id: stickerPopup
|
||||||
|
|
||||||
colors: Nheko.colors
|
|
||||||
emoji: false
|
emoji: false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -463,7 +462,6 @@ Rectangle {
|
||||||
StickerPicker {
|
StickerPicker {
|
||||||
id: emojiPopup
|
id: emojiPopup
|
||||||
|
|
||||||
colors: Nheko.colors
|
|
||||||
emoji: true
|
emoji: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -489,7 +487,6 @@ Rectangle {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
visible: room ? (!room.permissions.canSend(MtxEvent.TextMessage)) : false
|
visible: room ? (!room.permissions.canSend(MtxEvent.TextMessage)) : false
|
||||||
text: qsTr("You don't have permission to send messages in this room")
|
text: qsTr("You don't have permission to send messages in this room")
|
||||||
color: Nheko.colors.text
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,7 +16,7 @@ Rectangle {
|
||||||
implicitHeight: visible ? warningDisplay.implicitHeight + 4 * Nheko.paddingSmall : 0
|
implicitHeight: visible ? warningDisplay.implicitHeight + 4 * Nheko.paddingSmall : 0
|
||||||
height: implicitHeight
|
height: implicitHeight
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.window // required to hide the timeline behind this warning
|
color: palette.window // required to hide the timeline behind this warning
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: warningRect
|
id: warningRect
|
||||||
|
@ -37,7 +37,6 @@ Rectangle {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.margins: Nheko.paddingSmall
|
anchors.margins: Nheko.paddingSmall
|
||||||
color: Nheko.colors.text
|
|
||||||
text: warningRoot.text
|
text: warningRoot.text
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
}
|
}
|
||||||
|
|
|
@ -91,8 +91,8 @@ Item {
|
||||||
z: 10
|
z: 10
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.colors.buttonText
|
border.color: palette.buttonText
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: padding
|
radius: padding
|
||||||
}
|
}
|
||||||
|
@ -113,8 +113,8 @@ Item {
|
||||||
|
|
||||||
required property string modelData
|
required property string modelData
|
||||||
|
|
||||||
property color highlightColor: Nheko.colors.highlight
|
property color highlightColor: palette.highlight
|
||||||
property color buttonTextColor: Nheko.colors.buttonText
|
property color buttonTextColor: palette.buttonText
|
||||||
property bool showImage: modelData.startsWith("mxc://")
|
property bool showImage: modelData.startsWith("mxc://")
|
||||||
|
|
||||||
//Layout.preferredHeight: fontMetrics.height
|
//Layout.preferredHeight: fontMetrics.height
|
||||||
|
@ -170,7 +170,7 @@ Item {
|
||||||
|
|
||||||
ImageButton {
|
ImageButton {
|
||||||
visible: !!row.model && row.model.isEditable
|
visible: !!row.model && row.model.isEditable
|
||||||
buttonTextColor: Nheko.colors.buttonText
|
buttonTextColor: palette.buttonText
|
||||||
width: 16
|
width: 16
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
image: ":/icons/icons/ui/edit.svg"
|
image: ":/icons/icons/ui/edit.svg"
|
||||||
|
@ -223,7 +223,7 @@ Item {
|
||||||
|
|
||||||
ImageButton {
|
ImageButton {
|
||||||
visible: !!row.model && filteredTimeline.filterByContent
|
visible: !!row.model && filteredTimeline.filterByContent
|
||||||
buttonTextColor: Nheko.colors.buttonText
|
buttonTextColor: palette.buttonText
|
||||||
width: 16
|
width: 16
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
image: ":/icons/icons/ui/go-to.svg"
|
image: ":/icons/icons/ui/go-to.svg"
|
||||||
|
@ -354,7 +354,7 @@ Item {
|
||||||
anchors.horizontalCenter: parent ? parent.horizontalCenter : undefined
|
anchors.horizontalCenter: parent ? parent.horizontalCenter : undefined
|
||||||
visible: room && previousMessageDay !== day
|
visible: room && previousMessageDay !== day
|
||||||
text: room ? room.formatDateSeparator(timestamp) : ""
|
text: room ? room.formatDateSeparator(timestamp) : ""
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
height: Math.round(fontMetrics.height * 1.4)
|
height: Math.round(fontMetrics.height * 1.4)
|
||||||
width: contentWidth * 1.2
|
width: contentWidth * 1.2
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
|
@ -362,7 +362,7 @@ Item {
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
radius: parent.height / 2
|
radius: parent.height / 2
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -404,7 +404,7 @@ Item {
|
||||||
contentItem: ElidedLabel {
|
contentItem: ElidedLabel {
|
||||||
id: userName_
|
id: userName_
|
||||||
fullText: userName
|
fullText: userName
|
||||||
color: TimelineManager.userColor(userId, Nheko.colors.base)
|
color: TimelineManager.userColor(userId, palette.base)
|
||||||
textFormat: Text.RichText
|
textFormat: Text.RichText
|
||||||
elideWidth: Math.min(userInfo.remainingWidth-Math.min(statusMsg.implicitWidth,userInfo.remainingWidth/3), userName_.fullTextWidth)
|
elideWidth: Math.min(userInfo.remainingWidth-Math.min(statusMsg.implicitWidth,userInfo.remainingWidth/3), userName_.fullTextWidth)
|
||||||
}
|
}
|
||||||
|
@ -427,7 +427,7 @@ Item {
|
||||||
Label {
|
Label {
|
||||||
id: statusMsg
|
id: statusMsg
|
||||||
anchors.baseline: userNameButton.baseline
|
anchors.baseline: userNameButton.baseline
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
text: userStatus.replace(/\n/g, " ")
|
text: userStatus.replace(/\n/g, " ")
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
|
@ -580,7 +580,7 @@ Item {
|
||||||
visible: true
|
visible: true
|
||||||
z: 1
|
z: 1
|
||||||
enabled: false
|
enabled: false
|
||||||
color: Nheko.colors.highlight
|
color: palette.highlight
|
||||||
|
|
||||||
states: State {
|
states: State {
|
||||||
name: "revealed"
|
name: "revealed"
|
||||||
|
@ -646,7 +646,7 @@ Item {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
anchors.margins: Nheko.paddingLarge
|
anchors.margins: Nheko.paddingLarge
|
||||||
running: (room && room.paginationInProgress) || chat.filteringInProgress
|
running: (room && room.paginationInProgress) || chat.filteringInProgress
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
z: 3
|
z: 3
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -892,9 +892,9 @@ Item {
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: toEndButton.down ? Nheko.colors.highlight : Nheko.colors.button
|
color: toEndButton.down ? palette.highlight : palette.button
|
||||||
opacity: enabled ? 1 : 0.3
|
opacity: enabled ? 1 : 0.3
|
||||||
border.color: toEndButton.hovered ? Nheko.colors.highlight : Nheko.colors.buttonText
|
border.color: toEndButton.hovered ? palette.highlight : palette.buttonText
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: toEndButton.radius
|
radius: toEndButton.radius
|
||||||
}
|
}
|
||||||
|
@ -915,7 +915,7 @@ Item {
|
||||||
id: buttonImg
|
id: buttonImg
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Nheko.paddingMedium
|
anchors.margins: Nheko.paddingMedium
|
||||||
source: "image://colorimage/:/icons/icons/ui/download.svg?" + (toEndButton.down ? Nheko.colors.highlightedText : Nheko.colors.buttonText)
|
source: "image://colorimage/:/icons/icons/ui/download.svg?" + (toEndButton.down ? palette.highlightedText : palette.buttonText)
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,6 @@ Popup {
|
||||||
modal: true
|
modal: true
|
||||||
closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutside
|
closePolicy: Popup.CloseOnEscape | Popup.CloseOnPressOutside
|
||||||
parent: Overlay.overlay
|
parent: Overlay.overlay
|
||||||
palette: Nheko.colors
|
|
||||||
onOpened: {
|
onOpened: {
|
||||||
roomTextInput.forceActiveFocus();
|
roomTextInput.forceActiveFocus();
|
||||||
}
|
}
|
||||||
|
@ -35,7 +34,7 @@ Popup {
|
||||||
|
|
||||||
width: parent.width
|
width: parent.width
|
||||||
font.pixelSize: Math.ceil(quickSwitcher.textHeight * 0.6)
|
font.pixelSize: Math.ceil(quickSwitcher.textHeight * 0.6)
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
onTextEdited: {
|
onTextEdited: {
|
||||||
completerPopup.completer.searchString = text;
|
completerPopup.completer.searchString = text;
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,8 +12,8 @@ Flow {
|
||||||
id: reactionFlow
|
id: reactionFlow
|
||||||
|
|
||||||
// lower-contrast colors to avoid distracting from text & to enhance hover effect
|
// lower-contrast colors to avoid distracting from text & to enhance hover effect
|
||||||
property color gentleHighlight: Qt.hsla(Nheko.colors.highlight.hslHue, Nheko.colors.highlight.hslSaturation, Nheko.colors.highlight.hslLightness, 0.8)
|
property color gentleHighlight: Qt.hsla(palette.highlight.hslHue, palette.highlight.hslSaturation, palette.highlight.hslLightness, 0.8)
|
||||||
property color gentleText: Qt.hsla(Nheko.colors.text.hslHue, Nheko.colors.text.hslSaturation, Nheko.colors.text.hslLightness, 0.6)
|
property color gentleText: Qt.hsla(palette.text.hslHue, palette.text.hslSaturation, palette.text.hslLightness, 0.6)
|
||||||
property string eventId
|
property string eventId
|
||||||
property alias reactions: repeater.model
|
property alias reactions: repeater.model
|
||||||
|
|
||||||
|
@ -69,7 +69,7 @@ Flow {
|
||||||
return textMetrics.elidedText;
|
return textMetrics.elidedText;
|
||||||
}
|
}
|
||||||
font.family: Settings.emojiFont
|
font.family: Settings.emojiFont
|
||||||
color: (reaction.hovered || modelData.selfReactedEvent !== '') ? Nheko.colors.highlightedText: Nheko.colors.text
|
color: (reaction.hovered || modelData.selfReactedEvent !== '') ? palette.highlightedText: palette.text
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
visible: !modelData.key.startsWith("mxc://")
|
visible: !modelData.key.startsWith("mxc://")
|
||||||
}
|
}
|
||||||
|
@ -87,7 +87,7 @@ Flow {
|
||||||
|
|
||||||
height: Math.floor(reactionCounter.implicitHeight * 1.4)
|
height: Math.floor(reactionCounter.implicitHeight * 1.4)
|
||||||
width: 1
|
width: 1
|
||||||
color: reaction.hovered ? Nheko.colors.text: gentleText
|
color: reaction.hovered ? palette.text: gentleText
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
@ -96,7 +96,7 @@ Flow {
|
||||||
anchors.verticalCenter: divider.verticalCenter
|
anchors.verticalCenter: divider.verticalCenter
|
||||||
text: modelData.count
|
text: modelData.count
|
||||||
font: reaction.font
|
font: reaction.font
|
||||||
color: (reaction.hovered || modelData.selfReactedEvent !== '') ? Nheko.colors.highlightedText: Nheko.colors.windowText
|
color: (reaction.hovered || modelData.selfReactedEvent !== '') ? palette.highlightedText: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -105,8 +105,8 @@ Flow {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
implicitWidth: reaction.implicitWidth
|
implicitWidth: reaction.implicitWidth
|
||||||
implicitHeight: reaction.implicitHeight
|
implicitHeight: reaction.implicitHeight
|
||||||
border.color: reaction.hovered ? Nheko.colors.text: gentleText
|
border.color: reaction.hovered ? palette.text: gentleText
|
||||||
color: reaction.hovered ? Nheko.colors.highlight : (modelData.selfReactedEvent !== '' ? gentleHighlight : Nheko.colors.window)
|
color: reaction.hovered ? palette.highlight : (modelData.selfReactedEvent !== '' ? gentleHighlight : palette.window)
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: reaction.height / 2
|
radius: reaction.height / 2
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,7 +15,7 @@ Rectangle {
|
||||||
visible: room && (room.reply || room.edit || room.thread)
|
visible: room && (room.reply || room.edit || room.thread)
|
||||||
// Height of child, plus margins, plus border
|
// Height of child, plus margins, plus border
|
||||||
implicitHeight: (room && room.reply ? replyPreview.height : Math.max(closeEditButton.height, closeThreadButton.height)) + Nheko.paddingSmall
|
implicitHeight: (room && room.reply ? replyPreview.height : Math.max(closeEditButton.height, closeThreadButton.height)) + Nheko.paddingSmall
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
z: 3
|
z: 3
|
||||||
|
|
||||||
Reply {
|
Reply {
|
||||||
|
@ -31,7 +31,7 @@ Rectangle {
|
||||||
anchors.rightMargin: replyPopup.width < 450? 2*(22+16) : 3*(22+16)
|
anchors.rightMargin: replyPopup.width < 450? 2*(22+16) : 3*(22+16)
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: Nheko.paddingSmall
|
anchors.topMargin: Nheko.paddingSmall
|
||||||
userColor: TimelineManager.userColor(modelData.userId, Nheko.colors.window)
|
userColor: TimelineManager.userColor(modelData.userId, palette.window)
|
||||||
blurhash: modelData.blurhash ?? ""
|
blurhash: modelData.blurhash ?? ""
|
||||||
body: modelData.body ?? ""
|
body: modelData.body ?? ""
|
||||||
formattedBody: modelData.formattedBody ?? ""
|
formattedBody: modelData.formattedBody ?? ""
|
||||||
|
@ -46,7 +46,7 @@ Rectangle {
|
||||||
isOnlyEmoji: modelData.isOnlyEmoji ?? false
|
isOnlyEmoji: modelData.isOnlyEmoji ?? false
|
||||||
userId: modelData.userId ?? ""
|
userId: modelData.userId ?? ""
|
||||||
userName: modelData.userName ?? ""
|
userName: modelData.userName ?? ""
|
||||||
encryptionError: modelData.encryptionError ?? ""
|
encryptionError: modelData.encryptionError ?? 0
|
||||||
width: parent.width
|
width: parent.width
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -90,7 +90,7 @@ Rectangle {
|
||||||
anchors.margins: 8
|
anchors.margins: 8
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
buttonTextColor: room ? TimelineManager.userColor(room.thread, Nheko.colors.base) : Nheko.colors.buttonText
|
buttonTextColor: room ? TimelineManager.userColor(room.thread, palette.base) : palette.buttonText
|
||||||
image: ":/icons/icons/ui/dismiss_thread.svg"
|
image: ":/icons/icons/ui/dismiss_thread.svg"
|
||||||
width: 22
|
width: 22
|
||||||
height: 22
|
height: 22
|
||||||
|
|
|
@ -97,8 +97,7 @@ Page {
|
||||||
width: 420
|
width: 420
|
||||||
minimumWidth: 150
|
minimumWidth: 150
|
||||||
minimumHeight: 150
|
minimumHeight: 150
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
title: room.plainRoomName
|
title: room.plainRoomName
|
||||||
//flags: Qt.Window | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
//flags: Qt.Window | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
|
@ -197,8 +196,8 @@ Page {
|
||||||
|
|
||||||
Instantiator {
|
Instantiator {
|
||||||
model: Communities.tagsWithDefault
|
model: Communities.tagsWithDefault
|
||||||
onObjectAdded: tagsMenu.insertItem(index, object)
|
onObjectAdded: (index, object) => tagsMenu.insertItem(index, object)
|
||||||
onObjectRemoved: tagsMenu.removeItem(object)
|
onObjectRemoved: (index, object) => tagsMenu.removeItem(object)
|
||||||
|
|
||||||
delegate: Platform.MenuItem {
|
delegate: Platform.MenuItem {
|
||||||
property string t: modelData
|
property string t: modelData
|
||||||
|
@ -241,11 +240,11 @@ Page {
|
||||||
delegate: ItemDelegate {
|
delegate: ItemDelegate {
|
||||||
id: roomItem
|
id: roomItem
|
||||||
|
|
||||||
property color backgroundColor: Nheko.colors.window
|
property color backgroundColor: palette.window
|
||||||
property color importantText: Nheko.colors.text
|
property color importantText: palette.text
|
||||||
property color unimportantText: Nheko.colors.buttonText
|
property color unimportantText: palette.buttonText
|
||||||
property color bubbleBackground: Nheko.colors.highlight
|
property color bubbleBackground: palette.highlight
|
||||||
property color bubbleText: Nheko.colors.highlightedText
|
property color bubbleText: palette.highlightedText
|
||||||
required property string roomName
|
required property string roomName
|
||||||
required property string roomId
|
required property string roomId
|
||||||
required property string avatarUrl
|
required property string avatarUrl
|
||||||
|
@ -261,7 +260,7 @@ Page {
|
||||||
required property string directChatOtherUserId
|
required property string directChatOtherUserId
|
||||||
|
|
||||||
Ripple {
|
Ripple {
|
||||||
color: Qt.rgba(Nheko.colors.dark.r, Nheko.colors.dark.g, Nheko.colors.dark.b, 0.5)
|
color: Qt.rgba(palette.dark.r, palette.dark.g, palette.dark.b, 0.5)
|
||||||
}
|
}
|
||||||
|
|
||||||
height: avatarSize + 2 * Nheko.paddingMedium
|
height: avatarSize + 2 * Nheko.paddingMedium
|
||||||
|
@ -290,11 +289,11 @@ Page {
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: roomItem
|
target: roomItem
|
||||||
backgroundColor: Nheko.colors.dark
|
backgroundColor: palette.dark
|
||||||
importantText: Nheko.colors.brightText
|
importantText: palette.brightText
|
||||||
unimportantText: Nheko.colors.brightText
|
unimportantText: palette.brightText
|
||||||
bubbleBackground: Nheko.colors.highlight
|
bubbleBackground: palette.highlight
|
||||||
bubbleText: Nheko.colors.highlightedText
|
bubbleText: palette.highlightedText
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
|
@ -304,11 +303,11 @@ Page {
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: roomItem
|
target: roomItem
|
||||||
backgroundColor: Nheko.colors.highlight
|
backgroundColor: palette.highlight
|
||||||
importantText: Nheko.colors.highlightedText
|
importantText: palette.highlightedText
|
||||||
unimportantText: Nheko.colors.highlightedText
|
unimportantText: palette.highlightedText
|
||||||
bubbleBackground: Nheko.colors.highlightedText
|
bubbleBackground: palette.highlightedText
|
||||||
bubbleText: Nheko.colors.highlight
|
bubbleText: palette.highlight
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -450,7 +449,7 @@ Page {
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
height: parent.height - Nheko.paddingSmall * 2
|
height: parent.height - Nheko.paddingSmall * 2
|
||||||
width: 3
|
width: 3
|
||||||
color: Nheko.colors.highlight
|
color: palette.highlight
|
||||||
visible: hasUnreadMessages
|
visible: hasUnreadMessages
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -491,7 +490,7 @@ Page {
|
||||||
padding: Nheko.paddingMedium
|
padding: Nheko.paddingMedium
|
||||||
Layout.minimumHeight: 40
|
Layout.minimumHeight: 40
|
||||||
|
|
||||||
background: Rectangle {color: Nheko.colors.window}
|
background: Rectangle {color: palette.window}
|
||||||
|
|
||||||
InputDialog {
|
InputDialog {
|
||||||
id: statusDialog
|
id: statusDialog
|
||||||
|
@ -572,7 +571,7 @@ Page {
|
||||||
|
|
||||||
ElidedLabel {
|
ElidedLabel {
|
||||||
Layout.alignment: Qt.AlignTop
|
Layout.alignment: Qt.AlignTop
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
font.pointSize: fontMetrics.font.pointSize * 0.9
|
font.pointSize: fontMetrics.font.pointSize * 0.9
|
||||||
elideWidth: col.width
|
elideWidth: col.width
|
||||||
fullText: userInfoGrid.profile ? userInfoGrid.profile.userid : ""
|
fullText: userInfoGrid.profile ? userInfoGrid.profile.userid : ""
|
||||||
|
@ -627,7 +626,7 @@ Page {
|
||||||
|
|
||||||
Layout.margins: Nheko.paddingMedium
|
Layout.margins: Nheko.paddingMedium
|
||||||
Layout.rightMargin: Nheko.paddingSmall
|
Layout.rightMargin: Nheko.paddingSmall
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: {
|
text: {
|
||||||
switch (SelfVerificationStatus.status) {
|
switch (SelfVerificationStatus.status) {
|
||||||
|
@ -711,7 +710,7 @@ Page {
|
||||||
horizontalPadding: Nheko.paddingMedium
|
horizontalPadding: Nheko.paddingMedium
|
||||||
verticalPadding: 0
|
verticalPadding: 0
|
||||||
|
|
||||||
background: Rectangle {color: Nheko.colors.window}
|
background: Rectangle {color: palette.window}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
id: buttonRow
|
id: buttonRow
|
||||||
|
|
||||||
|
|
|
@ -20,7 +20,6 @@ import im.nheko.EmojiModel 1.0
|
||||||
Pane {
|
Pane {
|
||||||
id: timelineRoot
|
id: timelineRoot
|
||||||
|
|
||||||
palette: Nheko.colors
|
|
||||||
background: null
|
background: null
|
||||||
padding: 0
|
padding: 0
|
||||||
|
|
||||||
|
|
|
@ -37,7 +37,7 @@ Item {
|
||||||
Layout.maximumWidth: (Overlay.overlay ? Overlay.overlay.width : 400) - Nheko.paddingMedium * 4
|
Layout.maximumWidth: (Overlay.overlay ? Overlay.overlay.width : 400) - Nheko.paddingMedium * 4
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: qsTr("This is your recovery key. You will need it to restore access to your encrypted messages and verification keys. Keep this safe. Don't share it with anyone and don't lose it! Do not pass go! Do not collect $200!")
|
text: qsTr("This is your recovery key. You will need it to restore access to your encrypted messages and verification keys. Keep this safe. Don't share it with anyone and don't lose it! Do not pass go! Do not collect $200!")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -49,7 +49,7 @@ Item {
|
||||||
readOnly: true
|
readOnly: true
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
text: showRecoverKeyDialog.recoveryKey
|
text: showRecoverKeyDialog.recoveryKey
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
font.bold: true
|
font.bold: true
|
||||||
wrapMode: TextEdit.Wrap
|
wrapMode: TextEdit.Wrap
|
||||||
}
|
}
|
||||||
|
@ -57,7 +57,7 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.theme.separator
|
border.color: Nheko.theme.separator
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: Nheko.paddingSmall
|
radius: Nheko.paddingSmall
|
||||||
|
@ -101,7 +101,7 @@ Item {
|
||||||
Layout.columnSpan: 2
|
Layout.columnSpan: 2
|
||||||
font.pointSize: fontMetrics.font.pointSize * 2
|
font.pointSize: fontMetrics.font.pointSize * 2
|
||||||
text: qsTr("Setup Encryption")
|
text: qsTr("Setup Encryption")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -111,7 +111,7 @@ Item {
|
||||||
Layout.columnSpan: 2
|
Layout.columnSpan: 2
|
||||||
Layout.maximumWidth: grid.width - Nheko.paddingMedium * 2
|
Layout.maximumWidth: grid.width - Nheko.paddingMedium * 2
|
||||||
text: qsTr("Hello and welcome to Matrix!\nIt seems like you are new. Before you can securely encrypt your messages, we need to setup a few small things. You can either press accept immediately or adjust a few basic options. We also try to explain a few of the basics. You can skip those parts, but they might prove to be helpful!")
|
text: qsTr("Hello and welcome to Matrix!\nIt seems like you are new. Before you can securely encrypt your messages, we need to setup a few small things. You can either press accept immediately or adjust a few basic options. We also try to explain a few of the basics. You can skip those parts, but they might prove to be helpful!")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ Item {
|
||||||
Layout.columnSpan: 1
|
Layout.columnSpan: 1
|
||||||
Layout.maximumWidth: Math.floor(grid.width / 2) - Nheko.paddingMedium * 2
|
Layout.maximumWidth: Math.floor(grid.width / 2) - Nheko.paddingMedium * 2
|
||||||
text: "Store secrets online.\nYou have a few secrets to make all the encryption magic work. While you can keep them stored only locally, we recommend storing them encrypted on the server. Otherwise it will be painful to recover them. Only disable this if you are paranoid and like losing your data!"
|
text: "Store secrets online.\nYou have a few secrets to make all the encryption magic work. While you can keep them stored only locally, we recommend storing them encrypted on the server. Otherwise it will be painful to recover them. Only disable this if you are paranoid and like losing your data!"
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -148,7 +148,7 @@ Item {
|
||||||
Layout.maximumWidth: Math.floor(grid.width / 2) - Nheko.paddingMedium * 2
|
Layout.maximumWidth: Math.floor(grid.width / 2) - Nheko.paddingMedium * 2
|
||||||
visible: storeSecretsOnline.checked
|
visible: storeSecretsOnline.checked
|
||||||
text: "Set an online backup password.\nWe recommend you DON'T set a password and instead only rely on the recovery key. You will get a recovery key in any case when storing the cross-signing secrets online, but passwords are usually not very random, so they are easier to attack than a completely random recovery key. If you choose to use a password, DON'T make it the same as your login password, otherwise your server can read all your encrypted messages. (You don't want that.)"
|
text: "Set an online backup password.\nWe recommend you DON'T set a password and instead only rely on the recovery key. You will get a recovery key in any case when storing the cross-signing secrets online, but passwords are usually not very random, so they are easier to attack than a completely random recovery key. If you choose to use a password, DON'T make it the same as your login password, otherwise your server can read all your encrypted messages. (You don't want that.)"
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -187,7 +187,7 @@ Item {
|
||||||
Layout.columnSpan: 1
|
Layout.columnSpan: 1
|
||||||
Layout.maximumWidth: Math.floor(grid.width / 2) - Nheko.paddingMedium * 2
|
Layout.maximumWidth: Math.floor(grid.width / 2) - Nheko.paddingMedium * 2
|
||||||
text: "Use online key backup.\nStore the keys for your messages securely encrypted online. In general you do want this, because it protects your messages from becoming unreadable, if you log out by accident. It does however carry a small security risk, if you ever share your recovery key by accident. Currently this also has some other weaknesses, that might allow the server to insert new keys into your backup. The server will however never be able to read your messages."
|
text: "Use online key backup.\nStore the keys for your messages securely encrypted online. In general you do want this, because it protects your messages from becoming unreadable, if you log out by accident. It does however carry a small security risk, if you ever share your recovery key by accident. Currently this also has some other weaknesses, that might allow the server to insert new keys into your backup. The server will however never be able to read your messages."
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -209,7 +209,7 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.theme.separator
|
border.color: Nheko.theme.separator
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: Nheko.paddingSmall
|
radius: Nheko.paddingSmall
|
||||||
|
@ -235,7 +235,7 @@ Item {
|
||||||
//Layout.columnSpan: 2
|
//Layout.columnSpan: 2
|
||||||
font.pointSize: fontMetrics.font.pointSize * 2
|
font.pointSize: fontMetrics.font.pointSize * 2
|
||||||
text: qsTr("Activate Encryption")
|
text: qsTr("Activate Encryption")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -245,7 +245,7 @@ Item {
|
||||||
//Layout.columnSpan: 2
|
//Layout.columnSpan: 2
|
||||||
Layout.maximumWidth: grid.width - Nheko.paddingMedium * 2
|
Layout.maximumWidth: grid.width - Nheko.paddingMedium * 2
|
||||||
text: qsTr("It seems like you have encryption already configured for this account. To be able to access your encrypted messages and make this device appear as trusted, you can either verify an existing device or (if you have one) enter your recovery passphrase. Please select one of the options below.\nIf you choose verify, you need to have the other device available. If you choose \"enter passphrase\", you will need your recovery key or passphrase. If you click cancel, you can choose to verify yourself at a later point.")
|
text: qsTr("It seems like you have encryption already configured for this account. To be able to access your encrypted messages and make this device appear as trusted, you can either verify an existing device or (if you have one) enter your recovery passphrase. Please select one of the options below.\nIf you choose verify, you need to have the other device available. If you choose \"enter passphrase\", you will need your recovery key or passphrase. If you click cancel, you can choose to verify yourself at a later point.")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -54,7 +54,7 @@ AbstractButton {
|
||||||
height: row.height+(reactionRow.height > 0 ? reactionRow.height-2 : 0 )+unreadRow.height
|
height: row.height+(reactionRow.height > 0 ? reactionRow.height-2 : 0 )+unreadRow.height
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: (Settings.messageHoverHighlight && hovered) ? Nheko.colors.alternateBase : "transparent"
|
color: (Settings.messageHoverHighlight && hovered) ? palette.alternateBase : "transparent"
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
// this looks better without margins
|
// this looks better without margins
|
||||||
TapHandler {
|
TapHandler {
|
||||||
|
@ -112,7 +112,7 @@ AbstractButton {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: threadLine
|
id: threadLine
|
||||||
|
|
||||||
color: TimelineManager.userColor(threadId, Nheko.colors.base)
|
color: TimelineManager.userColor(threadId, palette.base)
|
||||||
anchors.fill: parent
|
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
|
width: Settings.bubbles? Math.min(maxWidth,Math.max(reply.implicitWidth+8,contentItem.implicitWidth+metadata.width+20)) : maxWidth
|
||||||
height: msg.height+msg.anchors.margins*2
|
height: msg.height+msg.anchors.margins*2
|
||||||
|
|
||||||
property color userColor: TimelineManager.userColor(userId, Nheko.colors.base)
|
property color userColor: TimelineManager.userColor(userId, palette.base)
|
||||||
property color bgColor: Nheko.colors.base
|
property color bgColor: palette.base
|
||||||
color: (Settings.bubbles && !isStateEvent) ? Qt.tint(bgColor, Qt.hsla(userColor.hslHue, 0.5, userColor.hslLightness, 0.2)) : "#00000000"
|
color: (Settings.bubbles && !isStateEvent) ? Qt.tint(bgColor, Qt.hsla(userColor.hslHue, 0.5, userColor.hslLightness, 0.2)) : "#00000000"
|
||||||
radius: 4
|
radius: 4
|
||||||
border.width: r.notificationlevel == MtxEvent.Highlight ? 1 : 0
|
border.width: r.notificationlevel == MtxEvent.Highlight ? 1 : 0
|
||||||
|
@ -169,7 +169,7 @@ AbstractButton {
|
||||||
return replyTo != "" ? room.dataById(replyTo, role, r.eventId) : null;
|
return replyTo != "" ? room.dataById(replyTo, role, r.eventId) : null;
|
||||||
}
|
}
|
||||||
visible: replyTo
|
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) ?? ""
|
blurhash: r.relatedEventCacheBuster, fromModel(Room.Blurhash) ?? ""
|
||||||
body: r.relatedEventCacheBuster, fromModel(Room.Body) ?? ""
|
body: r.relatedEventCacheBuster, fromModel(Room.Body) ?? ""
|
||||||
formattedBody: r.relatedEventCacheBuster, fromModel(Room.FormattedBody) ?? ""
|
formattedBody: r.relatedEventCacheBuster, fromModel(Room.FormattedBody) ?? ""
|
||||||
|
@ -186,11 +186,11 @@ AbstractButton {
|
||||||
userId: r.relatedEventCacheBuster, fromModel(Room.UserId) ?? ""
|
userId: r.relatedEventCacheBuster, fromModel(Room.UserId) ?? ""
|
||||||
userName: r.relatedEventCacheBuster, fromModel(Room.UserName) ?? ""
|
userName: r.relatedEventCacheBuster, fromModel(Room.UserName) ?? ""
|
||||||
thumbnailUrl: r.relatedEventCacheBuster, fromModel(Room.ThumbnailUrl) ?? ""
|
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) ?? ""
|
roomTopic: r.relatedEventCacheBuster, fromModel(Room.RoomTopic) ?? ""
|
||||||
roomName: r.relatedEventCacheBuster, fromModel(Room.RoomName) ?? ""
|
roomName: r.relatedEventCacheBuster, fromModel(Room.RoomName) ?? ""
|
||||||
callType: r.relatedEventCacheBuster, fromModel(Room.CallType) ?? ""
|
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
|
relatedEventCacheBuster: r.relatedEventCacheBuster, fromModel(Room.RelatedEventCacheBuster) ?? 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -260,7 +260,7 @@ AbstractButton {
|
||||||
width: parent.iconSize
|
width: parent.iconSize
|
||||||
sourceSize.width: parent.iconSize * Screen.devicePixelRatio
|
sourceSize.width: parent.iconSize * Screen.devicePixelRatio
|
||||||
sourceSize.height: 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.visible: editHovered.hovered
|
||||||
ToolTip.delay: Nheko.tooltipDelay
|
ToolTip.delay: Nheko.tooltipDelay
|
||||||
ToolTip.text: qsTr("Edited")
|
ToolTip.text: qsTr("Edited")
|
||||||
|
@ -278,7 +278,7 @@ AbstractButton {
|
||||||
height: parent.iconSize
|
height: parent.iconSize
|
||||||
width: parent.iconSize
|
width: parent.iconSize
|
||||||
image: ":/icons/icons/ui/thread.svg"
|
image: ":/icons/icons/ui/thread.svg"
|
||||||
buttonTextColor: TimelineManager.userColor(threadId, Nheko.colors.base)
|
buttonTextColor: TimelineManager.userColor(threadId, palette.base)
|
||||||
ToolTip.visible: hovered
|
ToolTip.visible: hovered
|
||||||
ToolTip.delay: Nheko.tooltipDelay
|
ToolTip.delay: Nheko.tooltipDelay
|
||||||
ToolTip.text: qsTr("Part of a thread")
|
ToolTip.text: qsTr("Part of a thread")
|
||||||
|
@ -303,7 +303,7 @@ AbstractButton {
|
||||||
Layout.alignment: Qt.AlignRight | Qt.AlignTop
|
Layout.alignment: Qt.AlignRight | Qt.AlignTop
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
text: timestamp.toLocaleTimeString(Locale.ShortFormat)
|
text: timestamp.toLocaleTimeString(Locale.ShortFormat)
|
||||||
color: Nheko.inactiveColors.text
|
color: palette.inactive.text
|
||||||
ToolTip.visible: ma.hovered
|
ToolTip.visible: ma.hovered
|
||||||
ToolTip.delay: Nheko.tooltipDelay
|
ToolTip.delay: Nheko.tooltipDelay
|
||||||
ToolTip.text: Qt.formatDateTime(timestamp, Qt.DefaultLocaleLongDate)
|
ToolTip.text: Qt.formatDateTime(timestamp, Qt.DefaultLocaleLongDate)
|
||||||
|
@ -341,7 +341,7 @@ AbstractButton {
|
||||||
left: parent.left
|
left: parent.left
|
||||||
right: parent.right
|
right: parent.right
|
||||||
}
|
}
|
||||||
color: Nheko.colors.highlight
|
color: palette.highlight
|
||||||
|
|
||||||
visible: (r.index > 0 && (room.fullyReadEventId == r.eventId))
|
visible: (r.index > 0 && (room.fullyReadEventId == r.eventId))
|
||||||
height: visible ? 3 : 0
|
height: visible ? 3 : 0
|
||||||
|
|
|
@ -32,12 +32,11 @@ Item {
|
||||||
StickerPicker {
|
StickerPicker {
|
||||||
id: emojiPopup
|
id: emojiPopup
|
||||||
|
|
||||||
colors: Nheko.colors
|
|
||||||
emoji: true
|
emoji: true
|
||||||
}
|
}
|
||||||
|
|
||||||
// focus message input on key press, but not on Ctrl-C and such.
|
// focus message input on key press, but not on Ctrl-C and such.
|
||||||
Keys.onPressed: {
|
Keys.onPressed: (event) => {
|
||||||
if (event.text && event.key !== Qt.Key_Enter && event.key !== Qt.Key_Return && !topBar.searchHasFocus) {
|
if (event.text && event.key !== Qt.Key_Enter && event.key !== Qt.Key_Return && !topBar.searchHasFocus) {
|
||||||
TimelineManager.focusMessageInput();
|
TimelineManager.focusMessageInput();
|
||||||
room.input.setText(room.input.text + event.text);
|
room.input.setText(room.input.text + event.text);
|
||||||
|
@ -54,13 +53,12 @@ Item {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
text: qsTr("No room open")
|
text: qsTr("No room open")
|
||||||
font.pointSize: 24
|
font.pointSize: 24
|
||||||
color: Nheko.colors.text
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Spinner {
|
Spinner {
|
||||||
visible: TimelineManager.isInitialSync
|
visible: TimelineManager.isInitialSync
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
running: TimelineManager.isInitialSync
|
running: TimelineManager.isInitialSync
|
||||||
// height is somewhat arbitrary here... don't set width because width scales w/ height
|
// height is somewhat arbitrary here... don't set width because width scales w/ height
|
||||||
height: parent.height / 16
|
height: parent.height / 16
|
||||||
|
@ -102,7 +100,7 @@ Item {
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
color: Nheko.colors.base
|
color: palette.base
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
@ -223,7 +221,7 @@ Item {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
|
|
||||||
MatrixText {
|
MatrixText {
|
||||||
text: !roomPreview.isFetched ? qsTr("No preview available") : preview.roomName
|
text: !(roomPreview?.isFetched ?? false) ? qsTr("No preview available") : preview.roomName
|
||||||
font.pixelSize: 24
|
font.pixelSize: 24
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -264,13 +262,12 @@ Item {
|
||||||
Layout.rightMargin: Nheko.paddingLarge
|
Layout.rightMargin: Nheko.paddingLarge
|
||||||
|
|
||||||
TextArea {
|
TextArea {
|
||||||
text: roomPreview.isFetched ? TimelineManager.escapeEmoji(preview.roomTopic) : qsTr("This room is possibly inaccessible. If this room is private, you should remove it from this community.")
|
text: (roomPreview?.isFetched ?? false) ? TimelineManager.escapeEmoji(preview.roomTopic) : qsTr("This room is possibly inaccessible. If this room is private, you should remove it from this community.")
|
||||||
wrapMode: TextEdit.WordWrap
|
wrapMode: TextEdit.WordWrap
|
||||||
textFormat: TextEdit.RichText
|
textFormat: TextEdit.RichText
|
||||||
readOnly: true
|
readOnly: true
|
||||||
background: null
|
background: null
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
color: Nheko.colors.text
|
|
||||||
horizontalAlignment: TextEdit.AlignHCenter
|
horizontalAlignment: TextEdit.AlignHCenter
|
||||||
onLinkActivated: Nheko.openLink(link)
|
onLinkActivated: Nheko.openLink(link)
|
||||||
|
|
||||||
|
@ -328,7 +325,6 @@ Item {
|
||||||
readOnly: true
|
readOnly: true
|
||||||
background: null
|
background: null
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
color: Nheko.colors.text
|
|
||||||
horizontalAlignment: TextEdit.AlignHCenter
|
horizontalAlignment: TextEdit.AlignHCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -32,7 +32,7 @@ Switch {
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: track
|
target: track
|
||||||
border.color: Nheko.colors.highlight
|
border.color: palette.highlight
|
||||||
}
|
}
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
|
@ -88,7 +88,7 @@ Switch {
|
||||||
width: parent.height * 0.9
|
width: parent.height * 0.9
|
||||||
height: width
|
height: width
|
||||||
radius: width / 2
|
radius: width / 2
|
||||||
color: Nheko.colors.button
|
color: palette.button
|
||||||
border.color: "#767676"
|
border.color: "#767676"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -53,7 +53,7 @@ Pane {
|
||||||
|
|
||||||
padding: 0
|
padding: 0
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
}
|
}
|
||||||
|
|
||||||
TapHandler {
|
TapHandler {
|
||||||
|
@ -137,7 +137,7 @@ Pane {
|
||||||
Layout.column: 2
|
Layout.column: 2
|
||||||
Layout.row: 0
|
Layout.row: 0
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: qsTr("In %1").arg(communityAvatar.displayName)
|
text: qsTr("In %1").arg(communityAvatar.displayName)
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
|
@ -178,7 +178,7 @@ Pane {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.column: 2
|
Layout.column: 2
|
||||||
Layout.row: 1
|
Layout.row: 1
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
font.pointSize: fontMetrics.font.pointSize * 1.1
|
font.pointSize: fontMetrics.font.pointSize * 1.1
|
||||||
font.bold: true
|
font.bold: true
|
||||||
text: roomName
|
text: roomName
|
||||||
|
@ -241,8 +241,8 @@ Pane {
|
||||||
trust: trustlevel
|
trust: trustlevel
|
||||||
enabled: false
|
enabled: false
|
||||||
unencryptedIcon: ":/icons/icons/ui/people.svg"
|
unencryptedIcon: ":/icons/icons/ui/people.svg"
|
||||||
unencryptedColor: Nheko.colors.buttonText
|
unencryptedColor: palette.buttonText
|
||||||
unencryptedHoverColor: Nheko.colors.highlight
|
unencryptedHoverColor: palette.highlight
|
||||||
hovered: parent.hovered
|
hovered: parent.hovered
|
||||||
|
|
||||||
ToolTip.delay: Nheko.tooltipDelay
|
ToolTip.delay: Nheko.tooltipDelay
|
||||||
|
@ -349,7 +349,6 @@ Pane {
|
||||||
visible: !!room && room.pinnedMessages.length > 0 && !Settings.hiddenPins.includes(roomId)
|
visible: !!room && room.pinnedMessages.length > 0 && !Settings.hiddenPins.includes(roomId)
|
||||||
clip: true
|
clip: true
|
||||||
|
|
||||||
palette: Nheko.colors
|
|
||||||
ScrollBar.horizontal.visible: false
|
ScrollBar.horizontal.visible: false
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
|
@ -372,7 +371,7 @@ Pane {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: height
|
Layout.preferredHeight: height
|
||||||
|
|
||||||
userColor: TimelineManager.userColor(e.userId, Nheko.colors.window)
|
userColor: TimelineManager.userColor(e.userId, palette.window)
|
||||||
blurhash: e.blurhash ?? ""
|
blurhash: e.blurhash ?? ""
|
||||||
body: e.body ?? ""
|
body: e.body ?? ""
|
||||||
formattedBody: e.formattedBody ?? ""
|
formattedBody: e.formattedBody ?? ""
|
||||||
|
@ -387,7 +386,7 @@ Pane {
|
||||||
isOnlyEmoji: e.isOnlyEmoji ?? false
|
isOnlyEmoji: e.isOnlyEmoji ?? false
|
||||||
userId: e.userId ?? ""
|
userId: e.userId ?? ""
|
||||||
userName: e.userName ?? ""
|
userName: e.userName ?? ""
|
||||||
encryptionError: e.encryptionError ?? ""
|
encryptionError: e.encryptionError ?? 0
|
||||||
keepFullText: true
|
keepFullText: true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -430,7 +429,6 @@ Pane {
|
||||||
visible: !!room && room.widgetLinks.length > 0 && !Settings.hiddenWidgets.includes(roomId)
|
visible: !!room && room.widgetLinks.length > 0 && !Settings.hiddenWidgets.includes(roomId)
|
||||||
clip: true
|
clip: true
|
||||||
|
|
||||||
palette: Nheko.colors
|
|
||||||
ScrollBar.horizontal.visible: false
|
ScrollBar.horizontal.visible: false
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
|
@ -440,7 +438,7 @@ Pane {
|
||||||
delegate: MatrixText {
|
delegate: MatrixText {
|
||||||
required property var modelData
|
required property var modelData
|
||||||
|
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: modelData
|
text: modelData
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,7 @@ Item {
|
||||||
id: typingRect
|
id: typingRect
|
||||||
|
|
||||||
visible: (room && room.typingUsers.length > 0)
|
visible: (room && room.typingUsers.length > 0)
|
||||||
color: Nheko.colors.base
|
color: palette.base
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
z: 3
|
z: 3
|
||||||
|
|
||||||
|
@ -27,8 +27,8 @@ Item {
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: 10
|
anchors.rightMargin: 10
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: room ? room.formatTypingUsers(room.typingUsers, Nheko.colors.base) : ""
|
text: room ? room.formatTypingUsers(room.typingUsers, palette.base) : ""
|
||||||
textFormat: Text.RichText
|
textFormat: Text.RichText
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -40,7 +40,7 @@ Page {
|
||||||
width: uploadPopup.availableHeight - buttons.height
|
width: uploadPopup.availableHeight - buttons.height
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
radius: Nheko.paddingMedium
|
radius: Nheko.paddingMedium
|
||||||
}
|
}
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
|
@ -60,7 +60,7 @@ Page {
|
||||||
case MediaUpload.Image: return "image";
|
case MediaUpload.Image: return "image";
|
||||||
default: return "zip";
|
default: return "zip";
|
||||||
}
|
}
|
||||||
source: (modelData.thumbnail != "") ? modelData.thumbnail : ("image://colorimage/:/icons/icons/ui/"+typeStr+".svg?" + Nheko.colors.buttonText)
|
source: (modelData.thumbnail != "") ? modelData.thumbnail : ("image://colorimage/:/icons/icons/ui/"+typeStr+".svg?" + palette.buttonText)
|
||||||
}
|
}
|
||||||
MatrixTextField {
|
MatrixTextField {
|
||||||
id: namefield
|
id: namefield
|
||||||
|
@ -85,6 +85,6 @@ Page {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.base
|
color: palette.base
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,11 +11,11 @@ import im.nheko 1.0
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: tile
|
id: tile
|
||||||
|
|
||||||
property color background: Nheko.colors.window
|
property color background: palette.window
|
||||||
property color importantText: Nheko.colors.text
|
property color importantText: palette.text
|
||||||
property color unimportantText: Nheko.colors.buttonText
|
property color unimportantText: palette.buttonText
|
||||||
property color bubbleBackground: Nheko.colors.highlight
|
property color bubbleBackground: palette.highlight
|
||||||
property color bubbleText: Nheko.colors.highlightedText
|
property color bubbleText: palette.highlightedText
|
||||||
property int avatarSize: Math.ceil(fontMetrics.lineSpacing * 2.3)
|
property int avatarSize: Math.ceil(fontMetrics.lineSpacing * 2.3)
|
||||||
required property string avatarUrl
|
required property string avatarUrl
|
||||||
required property string title
|
required property string title
|
||||||
|
@ -37,11 +37,11 @@ Rectangle {
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: tile
|
target: tile
|
||||||
background: Nheko.colors.dark
|
background: palette.dark
|
||||||
importantText: Nheko.colors.brightText
|
importantText: palette.brightText
|
||||||
unimportantText: Nheko.colors.brightText
|
unimportantText: palette.brightText
|
||||||
bubbleBackground: Nheko.colors.highlight
|
bubbleBackground: palette.highlight
|
||||||
bubbleText: Nheko.colors.highlightedText
|
bubbleText: palette.highlightedText
|
||||||
}
|
}
|
||||||
|
|
||||||
},
|
},
|
||||||
|
@ -51,11 +51,11 @@ Rectangle {
|
||||||
|
|
||||||
PropertyChanges {
|
PropertyChanges {
|
||||||
target: tile
|
target: tile
|
||||||
background: Nheko.colors.highlight
|
background: palette.highlight
|
||||||
importantText: Nheko.colors.highlightedText
|
importantText: palette.highlightedText
|
||||||
unimportantText: Nheko.colors.highlightedText
|
unimportantText: palette.highlightedText
|
||||||
bubbleBackground: Nheko.colors.highlightedText
|
bubbleBackground: palette.highlightedText
|
||||||
bubbleText: Nheko.colors.highlight
|
bubbleText: palette.highlight
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,7 +47,7 @@ Button {
|
||||||
font.capitalization: Font.AllUppercase
|
font.capitalization: Font.AllUppercase
|
||||||
font.pointSize: Math.ceil(fontMetrics.font.pointSize * 1.5)
|
font.pointSize: Math.ceil(fontMetrics.font.pointSize * 1.5)
|
||||||
//font.capitalization: Font.AllUppercase
|
//font.capitalization: Font.AllUppercase
|
||||||
color: Nheko.colors.light
|
color: palette.light
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
|
@ -58,7 +58,7 @@ Button {
|
||||||
//height: control.contentItem.implicitHeight * 2
|
//height: control.contentItem.implicitHeight * 2
|
||||||
//width: control.contentItem.implicitWidth * 2
|
//width: control.contentItem.implicitWidth * 2
|
||||||
radius: height / 8
|
radius: height / 8
|
||||||
color: Qt.lighter(Nheko.colors.dark, control.down ? 1.4 : (control.hovered ? 1.2 : 1))
|
color: Qt.lighter(palette.dark, control.down ? 1.4 : (control.hovered ? 1.2 : 1))
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,7 +32,7 @@ Dialog {
|
||||||
]
|
]
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.theme.separator
|
border.color: Nheko.theme.separator
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: Nheko.paddingSmall
|
radius: Nheko.paddingSmall
|
||||||
|
|
|
@ -13,15 +13,15 @@ TabButton {
|
||||||
text: control.text
|
text: control.text
|
||||||
font: control.font
|
font: control.font
|
||||||
opacity: enabled ? 1.0 : 0.3
|
opacity: enabled ? 1.0 : 0.3
|
||||||
color: control.down ? Nheko.colors.highlightedText : Nheko.colors.text
|
color: control.down ? palette.highlightedText : palette.text
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
border.color: control.down ? Nheko.colors.highlight : Nheko.theme.separator
|
border.color: control.down ? palette.highlight : Nheko.theme.separator
|
||||||
color: control.checked ? Nheko.colors.highlight : Nheko.colors.base
|
color: control.checked ? palette.highlight : palette.base
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: 2
|
radius: 2
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,9 +47,9 @@ Item {
|
||||||
width: dragArea.width; height: actualDelegate.implicitHeight + 4
|
width: dragArea.width; height: actualDelegate.implicitHeight + 4
|
||||||
|
|
||||||
border.width: dragArea.enabled ? 1 : 0
|
border.width: dragArea.enabled ? 1 : 0
|
||||||
border.color: Nheko.colors.highlight
|
border.color: palette.highlight
|
||||||
|
|
||||||
color: dragArea.held ? Nheko.colors.highlight : Nheko.colors.base
|
color: dragArea.held ? palette.highlight : palette.base
|
||||||
Behavior on color { ColorAnimation { duration: 100 } }
|
Behavior on color { ColorAnimation { duration: 100 } }
|
||||||
|
|
||||||
radius: 2
|
radius: 2
|
||||||
|
|
|
@ -11,8 +11,8 @@ AbstractButton {
|
||||||
id: button
|
id: button
|
||||||
|
|
||||||
property alias cursor: mouseArea.cursorShape
|
property alias cursor: mouseArea.cursorShape
|
||||||
property color highlightColor: Nheko.colors.highlight
|
property color highlightColor: palette.highlight
|
||||||
property color buttonTextColor: Nheko.colors.buttonText
|
property color buttonTextColor: palette.buttonText
|
||||||
|
|
||||||
focusPolicy: Qt.NoFocus
|
focusPolicy: Qt.NoFocus
|
||||||
width: buttonText.implicitWidth
|
width: buttonText.implicitWidth
|
||||||
|
|
|
@ -36,7 +36,7 @@ ItemDelegate {
|
||||||
Label {
|
Label {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: displayName
|
text: displayName
|
||||||
color: TimelineManager.userColor(userid, Nheko.colors.window)
|
color: TimelineManager.userColor(userid, palette.window)
|
||||||
font.pointSize: fontMetrics.font.pointSize
|
font.pointSize: fontMetrics.font.pointSize
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -44,7 +44,7 @@ ItemDelegate {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.alignment: Qt.AlignTop
|
Layout.alignment: Qt.AlignTop
|
||||||
text: userid
|
text: userid
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
font.pointSize: fontMetrics.font.pointSize * 0.9
|
font.pointSize: fontMetrics.font.pointSize * 0.9
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@ Rectangle {
|
||||||
width: parent.width? parent.width : 0
|
width: parent.width? parent.width : 0
|
||||||
implicitWidth: encryptedText.implicitWidth+24+Nheko.paddingMedium*3 // Column doesn't provide a useful implicitWidth, should be replaced by ColumnLayout
|
implicitWidth: encryptedText.implicitWidth+24+Nheko.paddingMedium*3 // Column doesn't provide a useful implicitWidth, should be replaced by ColumnLayout
|
||||||
height: contents.implicitHeight + Nheko.paddingMedium * 2
|
height: contents.implicitHeight + Nheko.paddingMedium * 2
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: contents
|
id: contents
|
||||||
|
@ -58,12 +58,11 @@ Rectangle {
|
||||||
return qsTr("Unknown decryption error");
|
return qsTr("Unknown decryption error");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
width: parent.width
|
width: parent.width
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
palette: Nheko.colors
|
|
||||||
visible: encryptionError == Olm.MissingSession || encryptionError == Olm.MissingSessionIndex
|
visible: encryptionError == Olm.MissingSession || encryptionError == Olm.MissingSessionIndex
|
||||||
text: qsTr("Request key")
|
text: qsTr("Request key")
|
||||||
onClicked: room.requestKeyForEvent(eventId)
|
onClicked: room.requestKeyForEvent(eventId)
|
||||||
|
|
|
@ -17,7 +17,7 @@ Rectangle {
|
||||||
width: parent.width ? Math.min(parent.width, 700) : 0
|
width: parent.width ? Math.min(parent.width, 700) : 0
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
height: contents.implicitHeight + Nheko.paddingMedium * 2
|
height: contents.implicitHeight + Nheko.paddingMedium * 2
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
border.color: Nheko.theme.green
|
border.color: Nheko.theme.green
|
||||||
border.width: 2
|
border.width: 2
|
||||||
|
|
||||||
|
@ -43,13 +43,13 @@ Rectangle {
|
||||||
text: qsTr("%1 enabled end-to-end encryption").arg(r.username)
|
text: qsTr("%1 enabled end-to-end encryption").arg(r.username)
|
||||||
font.bold: true
|
font.bold: true
|
||||||
font.pointSize: 14
|
font.pointSize: 14
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
width: parent.width
|
width: parent.width
|
||||||
}
|
}
|
||||||
|
|
||||||
MatrixText {
|
MatrixText {
|
||||||
text: qsTr("Encryption keeps your messages safe by only allowing the people you sent the message to to read it. For extra security, if you want to make sure you are talking to the right people, you can verify them in real life.")
|
text: qsTr("Encryption keeps your messages safe by only allowing the people you sent the message to to read it. For extra security, if you want to make sure you are talking to the right people, you can verify them in real life.")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
width: parent.width
|
width: parent.width
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -27,7 +27,7 @@ Item {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: button
|
id: button
|
||||||
|
|
||||||
color: Nheko.colors.light
|
color: palette.light
|
||||||
radius: 22
|
radius: 22
|
||||||
height: 44
|
height: 44
|
||||||
width: 44
|
width: 44
|
||||||
|
@ -67,7 +67,7 @@ Item {
|
||||||
text: filename
|
text: filename
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
@ -77,7 +77,7 @@ Item {
|
||||||
text: filesize
|
text: filesize
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -85,7 +85,7 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
z: -1
|
z: -1
|
||||||
radius: 10
|
radius: 10
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
|
@ -22,7 +22,7 @@ AbstractButton {
|
||||||
property int tempWidth: originalWidth < 1? 400: originalWidth
|
property int tempWidth: originalWidth < 1? 400: originalWidth
|
||||||
|
|
||||||
implicitWidth: Math.round(tempWidth*Math.min((timelineView.height/divisor)/(tempWidth*proportionalHeight), 1))
|
implicitWidth: Math.round(tempWidth*Math.min((timelineView.height/divisor)/(tempWidth*proportionalHeight), 1))
|
||||||
width: Math.min(parent.width,implicitWidth)
|
width: Math.min(parent?.width ?? 2000,implicitWidth)
|
||||||
height: width*proportionalHeight
|
height: width*proportionalHeight
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
|
|
||||||
|
@ -106,14 +106,14 @@ AbstractButton {
|
||||||
]
|
]
|
||||||
|
|
||||||
property int metadataWidth
|
property int metadataWidth
|
||||||
property bool fitsMetadata: (parent.width - width) > metadataWidth+4
|
property bool fitsMetadata: parent != null ? (parent.width - width) > metadataWidth+4 : false
|
||||||
|
|
||||||
Image {
|
Image {
|
||||||
id: img
|
id: img
|
||||||
|
|
||||||
visible: !mxcimage.loaded
|
visible: !mxcimage.loaded
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
source: url.replace("mxc://", "image://MxcImage/") + "?scale"
|
source: url != "" ? (url.replace("mxc://", "image://MxcImage/") + "?scale") : ""
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
smooth: true
|
smooth: true
|
||||||
|
@ -137,7 +137,7 @@ AbstractButton {
|
||||||
id: blurhash_
|
id: blurhash_
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
source: blurhash ? ("image://blurhash/" + blurhash) : ("image://colorimage/:/icons/icons/ui/image-failed.svg?" + Nheko.colors.buttonText)
|
source: blurhash ? ("image://blurhash/" + blurhash) : ("image://colorimage/:/icons/icons/ui/image-failed.svg?" + palette.buttonText)
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
sourceSize.width: parent.width * Screen.devicePixelRatio
|
sourceSize.width: parent.width * Screen.devicePixelRatio
|
||||||
|
@ -158,7 +158,7 @@ AbstractButton {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
implicitHeight: imgcaption.implicitHeight
|
implicitHeight: imgcaption.implicitHeight
|
||||||
anchors.bottom: overlay.bottom
|
anchors.bottom: overlay.bottom
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
opacity: 0.75
|
opacity: 0.75
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -171,7 +171,7 @@ AbstractButton {
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
// See this MSC: https://github.com/matrix-org/matrix-doc/pull/2530
|
// See this MSC: https://github.com/matrix-org/matrix-doc/pull/2530
|
||||||
text: filename ? filename : body
|
text: filename ? filename : body
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,7 @@ Item {
|
||||||
required property bool isReply
|
required property bool isReply
|
||||||
property bool keepFullText: !isReply
|
property bool keepFullText: !isReply
|
||||||
property alias child: chooser.child
|
property alias child: chooser.child
|
||||||
implicitWidth: (chooser.child && chooser.child.implicitWidth) ? chooser.child.implicitWidth : 0
|
//implicitWidth: chooser.child?.implicitWidth ?? 0
|
||||||
required property double proportionalHeight
|
required property double proportionalHeight
|
||||||
required property int type
|
required property int type
|
||||||
required property string typeString
|
required property string typeString
|
||||||
|
@ -48,7 +48,7 @@ Item {
|
||||||
roleValue: type
|
roleValue: type
|
||||||
//anchors.fill: parent
|
//anchors.fill: parent
|
||||||
|
|
||||||
width: parent.width? parent.width: 0 // this should get rid of "cannot read property 'width' of null"
|
width: parent?.width ?? 0 // this should get rid of "cannot read property 'width' of null"
|
||||||
|
|
||||||
DelegateChoice {
|
DelegateChoice {
|
||||||
roleValue: MtxEvent.UnknownEvent
|
roleValue: MtxEvent.UnknownEvent
|
||||||
|
@ -78,7 +78,6 @@ Item {
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
palette: Nheko.colors
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
text: qsTr("Go to replacement room")
|
text: qsTr("Go to replacement room")
|
||||||
onClicked: room.joinReplacementRoom(eventId)
|
onClicked: room.joinReplacementRoom(eventId)
|
||||||
|
@ -149,7 +148,7 @@ Item {
|
||||||
|
|
||||||
NoticeMessage {
|
NoticeMessage {
|
||||||
formatted: TimelineManager.escapeEmoji(d.userName) + " " + d.formattedBody
|
formatted: TimelineManager.escapeEmoji(d.userName) + " " + d.formattedBody
|
||||||
color: TimelineManager.userColor(d.userId, Nheko.colors.base)
|
color: TimelineManager.userColor(d.userId, palette.base)
|
||||||
body: d.body
|
body: d.body
|
||||||
isOnlyEmoji: d.isOnlyEmoji
|
isOnlyEmoji: d.isOnlyEmoji
|
||||||
isReply: d.isReply
|
isReply: d.isReply
|
||||||
|
@ -617,7 +616,6 @@ Item {
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
visible: d.relatedEventCacheBuster, room.showAcceptKnockButton(d.eventId)
|
visible: d.relatedEventCacheBuster, room.showAcceptKnockButton(d.eventId)
|
||||||
palette: Nheko.colors
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
text: qsTr("Allow them in")
|
text: qsTr("Allow them in")
|
||||||
onClicked: room.acceptKnock(eventId)
|
onClicked: room.acceptKnock(eventId)
|
||||||
|
|
|
@ -9,7 +9,7 @@ import im.nheko 1.0
|
||||||
TextMessage {
|
TextMessage {
|
||||||
property bool isStateEvent
|
property bool isStateEvent
|
||||||
font.italic: true
|
font.italic: true
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
font.pointSize: isStateEvent? 0.8*Settings.fontSize : Settings.fontSize
|
font.pointSize: isStateEvent? 0.8*Settings.fontSize : Settings.fontSize
|
||||||
horizontalAlignment: isStateEvent? Text.AlignHCenter : undefined
|
horizontalAlignment: isStateEvent? Text.AlignHCenter : undefined
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,14 +8,14 @@ import im.nheko 1.0
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
property bool isStateEvent
|
property bool isStateEvent
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
height: Math.round(fontMetrics.height * 1.4)
|
height: Math.round(fontMetrics.height * 1.4)
|
||||||
width: contentWidth * 1.2
|
width: contentWidth * 1.2
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
radius: parent.height / 2
|
radius: parent.height / 2
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -10,5 +10,5 @@ MatrixText {
|
||||||
|
|
||||||
text: qsTr("unimplemented event: ") + typeString
|
text: qsTr("unimplemented event: ") + typeString
|
||||||
// width: parent.width
|
// width: parent.width
|
||||||
color: Nheko.inactiveColors.text
|
color: palette.inactive.text
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,7 +47,7 @@ Item {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: videoContainer
|
id: videoContainer
|
||||||
|
|
||||||
color: type == MtxEvent.VideoMessage ? Nheko.colors.window : "transparent"
|
color: type == MtxEvent.VideoMessage ? palette.window : "transparent"
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: parent.height - fileInfoLabel.height
|
height: parent.height - fileInfoLabel.height
|
||||||
|
|
||||||
|
@ -57,7 +57,7 @@ Item {
|
||||||
|
|
||||||
Image {
|
Image {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
source: thumbnailUrl ? thumbnailUrl.replace("mxc://", "image://MxcImage/") + "?scale" : "image://colorimage/:/icons/icons/ui/video-file.svg?" + Nheko.colors.windowText
|
source: thumbnailUrl ? thumbnailUrl.replace("mxc://", "image://MxcImage/") + "?scale" : "image://colorimage/:/icons/icons/ui/video-file.svg?" + palette.windowText
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
|
|
||||||
|
@ -99,10 +99,10 @@ Item {
|
||||||
text: body + " [" + filesize + "]"
|
text: body + " [" + filesize + "]"
|
||||||
textFormat: Text.RichText
|
textFormat: Text.RichText
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.base
|
color: palette.base
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,7 +13,7 @@ Rectangle{
|
||||||
implicitWidth: redactedLayout.implicitWidth + 2 * Nheko.paddingMedium
|
implicitWidth: redactedLayout.implicitWidth + 2 * Nheko.paddingMedium
|
||||||
width: Math.min(parent.width,implicitWidth+1)
|
width: Math.min(parent.width,implicitWidth+1)
|
||||||
radius: fontMetrics.lineSpacing / 2 + 2 * Nheko.paddingSmall
|
radius: fontMetrics.lineSpacing / 2 + 2 * Nheko.paddingSmall
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
property int metadataWidth
|
property int metadataWidth
|
||||||
property bool fitsMetadata: parent.width - redactedLayout.width > metadataWidth + 4
|
property bool fitsMetadata: parent.width - redactedLayout.width > metadataWidth + 4
|
||||||
|
|
||||||
|
@ -28,7 +28,7 @@ Rectangle{
|
||||||
Layout.alignment: Qt.AlignLeft | Qt.AlignVCenter
|
Layout.alignment: Qt.AlignLeft | Qt.AlignVCenter
|
||||||
Layout.preferredWidth: fontMetrics.font.pixelSize
|
Layout.preferredWidth: fontMetrics.font.pixelSize
|
||||||
Layout.preferredHeight: fontMetrics.font.pixelSize
|
Layout.preferredHeight: fontMetrics.font.pixelSize
|
||||||
source: "image://colorimage/:/icons/icons/ui/delete.svg?" + Nheko.colors.text
|
source: "image://colorimage/:/icons/icons/ui/delete.svg?" + palette.text
|
||||||
}
|
}
|
||||||
Label {
|
Label {
|
||||||
id: redactedLabel
|
id: redactedLabel
|
||||||
|
@ -39,7 +39,7 @@ Rectangle{
|
||||||
property var redactedPair: room.formatRedactedEvent(eventId)
|
property var redactedPair: room.formatRedactedEvent(eventId)
|
||||||
text: redactedPair["first"]
|
text: redactedPair["first"]
|
||||||
wrapMode: Label.WordWrap
|
wrapMode: Label.WordWrap
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
ToolTip.text: redactedPair["second"]
|
ToolTip.text: redactedPair["second"]
|
||||||
ToolTip.visible: hh.hovered
|
ToolTip.visible: hh.hovered
|
||||||
|
|
|
@ -54,7 +54,7 @@ AbstractButton {
|
||||||
anchors.top: replyContainer.top
|
anchors.top: replyContainer.top
|
||||||
anchors.bottom: replyContainer.bottom
|
anchors.bottom: replyContainer.bottom
|
||||||
width: 4
|
width: 4
|
||||||
color: TimelineManager.userColor(userId, Nheko.colors.base)
|
color: TimelineManager.userColor(userId, palette.base)
|
||||||
}
|
}
|
||||||
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
@ -135,8 +135,8 @@ AbstractButton {
|
||||||
|
|
||||||
z: -1
|
z: -1
|
||||||
anchors.fill: replyContainer
|
anchors.fill: replyContainer
|
||||||
property color userColor: TimelineManager.userColor(userId, Nheko.colors.base)
|
property color userColor: TimelineManager.userColor(userId, palette.base)
|
||||||
property color bgColor: Nheko.colors.base
|
property color bgColor: palette.base
|
||||||
color: Qt.tint(bgColor, Qt.hsla(userColor.hslHue, 0.5, userColor.hslLightness, 0.1))
|
color: Qt.tint(bgColor, Qt.hsla(userColor.hslHue, 0.5, userColor.hslLightness, 0.1))
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -19,15 +19,15 @@ MatrixText {
|
||||||
// table border-collapse doesn't seem to work
|
// table border-collapse doesn't seem to work
|
||||||
text: "
|
text: "
|
||||||
<style type=\"text/css\">
|
<style type=\"text/css\">
|
||||||
a { color:" + Nheko.colors.link + ";}
|
a { color:" + palette.link + ";}
|
||||||
code { background-color: " + Nheko.colors.alternateBase + "; white-space: pre-wrap; }
|
code { background-color: " + palette.alternateBase + "; white-space: pre-wrap; }
|
||||||
pre { background-color: " + Nheko.colors.alternateBase + "; white-space: pre-wrap; }
|
pre { background-color: " + palette.alternateBase + "; white-space: pre-wrap; }
|
||||||
table {
|
table {
|
||||||
border-width: 1px;
|
border-width: 1px;
|
||||||
border-collapse: collapse;
|
border-collapse: collapse;
|
||||||
border-style: solid;
|
border-style: solid;
|
||||||
border-color: " + Nheko.colors.text + ";
|
border-color: " + palette.text + ";
|
||||||
background-color: " + Nheko.colors.alternateBase + ";
|
background-color: " + palette.alternateBase + ";
|
||||||
}
|
}
|
||||||
table th,
|
table th,
|
||||||
table td {
|
table td {
|
||||||
|
@ -36,11 +36,11 @@ MatrixText {
|
||||||
blockquote { margin-left: 1em; }
|
blockquote { margin-left: 1em; }
|
||||||
" + (!Settings.mobileMode ? "span[data-mx-spoiler] {
|
" + (!Settings.mobileMode ? "span[data-mx-spoiler] {
|
||||||
color: transparent;
|
color: transparent;
|
||||||
background-color: " + Nheko.colors.text + ";
|
background-color: " + palette.text + ";
|
||||||
}" : "") + // TODO(Nico): Figure out how to support mobile
|
}" : "") + // TODO(Nico): Figure out how to support mobile
|
||||||
"</style>
|
"</style>
|
||||||
" + formatted.replace(/<del>/g, "<s>").replace(/<\/del>/g, "</s>").replace(/<strike>/g, "<s>").replace(/<\/strike>/g, "</s>")
|
" + formatted.replace(/<del>/g, "<s>").replace(/<\/del>/g, "</s>").replace(/<strike>/g, "<s>").replace(/<\/strike>/g, "</s>")
|
||||||
width: parent.width
|
width: parent?.width ?? 0
|
||||||
height: !keepFullText ? Math.round(Math.min(timelineView.height / 8, implicitHeight)) : implicitHeight
|
height: !keepFullText ? Math.round(Math.min(timelineView.height / 8, implicitHeight)) : implicitHeight
|
||||||
clip: !keepFullText
|
clip: !keepFullText
|
||||||
selectByMouse: !Settings.mobileMode && !isReply
|
selectByMouse: !Settings.mobileMode && !isReply
|
||||||
|
|
|
@ -15,8 +15,7 @@ ApplicationWindow {
|
||||||
onClosing: VerificationManager.removeVerificationFlow(flow)
|
onClosing: VerificationManager.removeVerificationFlow(flow)
|
||||||
title: stack.currentItem ? (stack.currentItem.title_ || "") : ""
|
title: stack.currentItem ? (stack.currentItem.title_ || "") : ""
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
//height: stack.currentItem.implicitHeight
|
//height: stack.currentItem.implicitHeight
|
||||||
minimumHeight: stack.currentItem.implicitHeight + 2 * Nheko.paddingLarge
|
minimumHeight: stack.currentItem.implicitHeight + 2 * Nheko.paddingLarge
|
||||||
height: stack.currentItem.implicitHeight + 2 * Nheko.paddingMedium
|
height: stack.currentItem.implicitHeight + 2 * Nheko.paddingMedium
|
||||||
|
@ -25,7 +24,7 @@ ApplicationWindow {
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -17,7 +17,7 @@ ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
text: qsTr("Please verify the following digits. You should see the same numbers on both sides. If they differ, please press 'They do not match!' to abort verification!")
|
text: qsTr("Please verify the following digits. You should see the same numbers on both sides. If they differ, please press 'They do not match!' to abort verification!")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -28,19 +28,19 @@ ColumnLayout {
|
||||||
Label {
|
Label {
|
||||||
font.pixelSize: Qt.application.font.pixelSize * 2
|
font.pixelSize: Qt.application.font.pixelSize * 2
|
||||||
text: flow.sasList[0]
|
text: flow.sasList[0]
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
font.pixelSize: Qt.application.font.pixelSize * 2
|
font.pixelSize: Qt.application.font.pixelSize * 2
|
||||||
text: flow.sasList[1]
|
text: flow.sasList[1]
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
font.pixelSize: Qt.application.font.pixelSize * 2
|
font.pixelSize: Qt.application.font.pixelSize * 2
|
||||||
text: flow.sasList[2]
|
text: flow.sasList[2]
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,7 +17,7 @@ ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
text: qsTr("Please verify the following emoji. You should see the same emoji on both sides. If they differ, please press 'They do not match!' to abort verification!")
|
text: qsTr("Please verify the following emoji. You should see the same emoji on both sides. If they differ, please press 'They do not match!' to abort verification!")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -373,13 +373,13 @@ ColumnLayout {
|
||||||
text: col.emoji.emoji
|
text: col.emoji.emoji
|
||||||
font.pixelSize: Qt.application.font.pixelSize * 2
|
font.pixelSize: Qt.application.font.pixelSize * 2
|
||||||
font.family: Settings.emojiFont
|
font.family: Settings.emojiFont
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
Layout.alignment: Qt.AlignHCenter | Qt.AlignBottom
|
Layout.alignment: Qt.AlignHCenter | Qt.AlignBottom
|
||||||
text: col.emoji.description
|
text: col.emoji.description
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -396,7 +396,7 @@ ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
text: qsTr("The displayed emoji might look different in different clients if a different font is used. Similarly they might be translated into different languages. Nonetheless they should depict one of 64 different objects or animals. For example a lion and a cat are different, but a cat is the same even if one client just shows a cat face, while another client shows a full cat body.")
|
text: qsTr("The displayed emoji might look different in different clients if a different font is used. Similarly they might be translated into different languages. Nonetheless they should depict one of 64 different objects or animals. For example a lion and a cat are different, but a cat is the same even if one client just shows a cat face, while another client shows a full cat body.")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,7 @@ ColumnLayout {
|
||||||
return qsTr("Unknown verification error.");
|
return qsTr("Unknown verification error.");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -36,7 +36,7 @@ ColumnLayout {
|
||||||
return qsTr("Your device (%1) has requested to be verified.").arg(flow.deviceId);
|
return qsTr("Your device (%1) has requested to be verified.").arg(flow.deviceId);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,7 @@ ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
text: qsTr("Verification successful! Both sides verified their devices!")
|
text: qsTr("Verification successful! Both sides verified their devices!")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -30,14 +30,14 @@ ColumnLayout {
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
Item { Layout.fillHeight: true; }
|
Item { Layout.fillHeight: true; }
|
||||||
Spinner {
|
Spinner {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
Item { Layout.fillHeight: true; }
|
Item { Layout.fillHeight: true; }
|
||||||
|
|
||||||
|
|
|
@ -41,7 +41,7 @@ ApplicationWindow {
|
||||||
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: false
|
Layout.fillHeight: false
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.bottomMargin: Nheko.paddingMedium
|
Layout.bottomMargin: Nheko.paddingMedium
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -69,7 +69,7 @@ ApplicationWindow {
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: model.name
|
text: model.name
|
||||||
color: model.isPublished ? Nheko.colors.text : Nheko.theme.error
|
color: model.isPublished ? palette.text : Nheko.theme.error
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -78,8 +78,8 @@ ApplicationWindow {
|
||||||
Layout.margins: 2
|
Layout.margins: 2
|
||||||
image: ":/icons/icons/ui/star.svg"
|
image: ":/icons/icons/ui/star.svg"
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
buttonTextColor: model.isCanonical ? Nheko.colors.highlight : Nheko.colors.text
|
buttonTextColor: model.isCanonical ? palette.highlight : palette.text
|
||||||
highlightColor: editingModel.canAdvertize ? Nheko.colors.highlight : buttonTextColor
|
highlightColor: editingModel.canAdvertize ? palette.highlight : buttonTextColor
|
||||||
|
|
||||||
ToolTip.visible: hovered
|
ToolTip.visible: hovered
|
||||||
ToolTip.text: model.isCanonical ? qsTr("Primary alias") : qsTr("Make primary alias")
|
ToolTip.text: model.isCanonical ? qsTr("Primary alias") : qsTr("Make primary alias")
|
||||||
|
@ -92,8 +92,8 @@ ApplicationWindow {
|
||||||
Layout.margins: 2
|
Layout.margins: 2
|
||||||
image: ":/icons/icons/ui/building-shop.svg"
|
image: ":/icons/icons/ui/building-shop.svg"
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
buttonTextColor: model.isAdvertized ? Nheko.colors.highlight : Nheko.colors.text
|
buttonTextColor: model.isAdvertized ? palette.highlight : palette.text
|
||||||
highlightColor: editingModel.canAdvertize ? Nheko.colors.highlight : buttonTextColor
|
highlightColor: editingModel.canAdvertize ? palette.highlight : buttonTextColor
|
||||||
|
|
||||||
ToolTip.visible: hovered
|
ToolTip.visible: hovered
|
||||||
ToolTip.text: qsTr("Advertise as an alias in this room")
|
ToolTip.text: qsTr("Advertise as an alias in this room")
|
||||||
|
@ -106,7 +106,7 @@ ApplicationWindow {
|
||||||
Layout.margins: 2
|
Layout.margins: 2
|
||||||
image: ":/icons/icons/ui/room-directory.svg"
|
image: ":/icons/icons/ui/room-directory.svg"
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
buttonTextColor: model.isPublished ? Nheko.colors.highlight : Nheko.colors.text
|
buttonTextColor: model.isPublished ? palette.highlight : palette.text
|
||||||
|
|
||||||
ToolTip.visible: hovered
|
ToolTip.visible: hovered
|
||||||
ToolTip.text: qsTr("Publish in room directory")
|
ToolTip.text: qsTr("Publish in room directory")
|
||||||
|
@ -139,7 +139,7 @@ ApplicationWindow {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
font.pixelSize: fontMetrics.font.pixelSize
|
font.pixelSize: fontMetrics.font.pixelSize
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
placeholderText: qsTr("#new-alias:server.tld")
|
placeholderText: qsTr("#new-alias:server.tld")
|
||||||
|
|
||||||
Component.onCompleted: forceActiveFocus()
|
Component.onCompleted: forceActiveFocus()
|
||||||
|
|
|
@ -20,8 +20,7 @@ ApplicationWindow {
|
||||||
minimumHeight: 450
|
minimumHeight: 450
|
||||||
width: 450
|
width: 450
|
||||||
height: 680
|
height: 680
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
title: qsTr("Allowed rooms settings")
|
title: qsTr("Allowed rooms settings")
|
||||||
|
@ -42,7 +41,7 @@ ApplicationWindow {
|
||||||
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: false
|
Layout.fillHeight: false
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.bottomMargin: Nheko.paddingMedium
|
Layout.bottomMargin: Nheko.paddingMedium
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -72,14 +71,14 @@ ApplicationWindow {
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: model.name
|
text: model.name
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: model.isParent ? qsTr("Parent community") : qsTr("Other room")
|
text: model.isParent ? qsTr("Parent community") : qsTr("Other room")
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -122,7 +121,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
placeholderText: qsTr("Enter additional rooms not in the list yet...")
|
placeholderText: qsTr("Enter additional rooms not in the list yet...")
|
||||||
|
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
onTextEdited: {
|
onTextEdited: {
|
||||||
roomCompleter.completer.searchString = text;
|
roomCompleter.completer.searchString = text;
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,8 +19,7 @@ ApplicationWindow {
|
||||||
title: summary.isSpace ? qsTr("Confirm community join") : qsTr("Confirm room join")
|
title: summary.isSpace ? qsTr("Confirm community join") : qsTr("Confirm room join")
|
||||||
modality: Qt.WindowModal
|
modality: Qt.WindowModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
width: 350
|
width: 350
|
||||||
height: content.implicitHeight + Nheko.paddingLarge + footer.implicitHeight
|
height: content.implicitHeight + Nheko.paddingLarge + footer.implicitHeight
|
||||||
|
|
||||||
|
@ -48,7 +47,7 @@ ApplicationWindow {
|
||||||
Spinner {
|
Spinner {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
visible: !summary.isLoaded
|
visible: !summary.isLoaded
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
running: !summary.isLoaded
|
running: !summary.isLoaded
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -57,7 +56,7 @@ ApplicationWindow {
|
||||||
textFormat: TextEdit.RichText
|
textFormat: TextEdit.RichText
|
||||||
text: summary.roomName
|
text: summary.roomName
|
||||||
font.pixelSize: fontMetrics.font.pixelSize * 2
|
font.pixelSize: fontMetrics.font.pixelSize * 2
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
@ -70,7 +69,7 @@ ApplicationWindow {
|
||||||
textFormat: TextEdit.RichText
|
textFormat: TextEdit.RichText
|
||||||
text: summary.roomid
|
text: summary.roomid
|
||||||
font.pixelSize: fontMetrics.font.pixelSize * 0.8
|
font.pixelSize: fontMetrics.font.pixelSize * 0.8
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
@ -96,7 +95,7 @@ ApplicationWindow {
|
||||||
readOnly: true
|
readOnly: true
|
||||||
textFormat: TextEdit.RichText
|
textFormat: TextEdit.RichText
|
||||||
text: summary.roomTopic
|
text: summary.roomTopic
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
@ -109,7 +108,7 @@ ApplicationWindow {
|
||||||
id: promptLabel
|
id: promptLabel
|
||||||
|
|
||||||
text: summary.isKnockOnly ? qsTr("This room can't be joined directly. You can, however, knock on the room and room members can accept or decline this join request. You can additionally provide a reason for them to let you in below:") : qsTr("Do you want to join this room? You can optionally add a reason below:")
|
text: summary.isKnockOnly ? qsTr("This room can't be joined directly. You can, however, knock on the room and room members can accept or decline this join request. You can additionally provide a reason for them to let you in below:") : qsTr("Do you want to join this room? You can optionally add a reason below:")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
|
|
|
@ -55,14 +55,14 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: profile? profile.displayName : ""
|
text: profile? profile.displayName : ""
|
||||||
color: TimelineManager.userColor(userID.text, Nheko.colors.window)
|
color: TimelineManager.userColor(userID.text, palette.window)
|
||||||
font.pointSize: fontMetrics.font.pointSize
|
font.pointSize: fontMetrics.font.pointSize
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: userID.text
|
text: userID.text
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
font.pointSize: fontMetrics.font.pointSize * 0.9
|
font.pointSize: fontMetrics.font.pointSize * 0.9
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -89,7 +89,7 @@ ApplicationWindow {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Encryption")
|
text: qsTr("Encryption")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
ToggleButton {
|
ToggleButton {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignRight
|
||||||
|
|
|
@ -64,7 +64,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
text: "#"
|
text: "#"
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
MatrixTextField {
|
MatrixTextField {
|
||||||
id: newRoomAlias
|
id: newRoomAlias
|
||||||
|
@ -75,14 +75,14 @@ ApplicationWindow {
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
property string userName: userInfoGrid.profile.userid
|
property string userName: userInfoGrid.profile.userid
|
||||||
text: userName.substring(userName.indexOf(":"))
|
text: userName.substring(userName.indexOf(":"))
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Label {
|
Label {
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Public")
|
text: qsTr("Public")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
HoverHandler {
|
HoverHandler {
|
||||||
id: privateHover
|
id: privateHover
|
||||||
}
|
}
|
||||||
|
@ -101,7 +101,7 @@ ApplicationWindow {
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Trusted")
|
text: qsTr("Trusted")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
HoverHandler {
|
HoverHandler {
|
||||||
id: trustedHover
|
id: trustedHover
|
||||||
}
|
}
|
||||||
|
@ -122,7 +122,7 @@ ApplicationWindow {
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Encryption")
|
text: qsTr("Encryption")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
HoverHandler {
|
HoverHandler {
|
||||||
id: encryptionHover
|
id: encryptionHover
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,8 +22,7 @@ ApplicationWindow {
|
||||||
title: qsTr("Editing image pack")
|
title: qsTr("Editing image pack")
|
||||||
height: 600
|
height: 600
|
||||||
width: 600
|
width: 600
|
||||||
palette: Nheko.colors
|
color: palette.base
|
||||||
color: Nheko.colors.base
|
|
||||||
modality: Qt.WindowModal
|
modality: Qt.WindowModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
|
@ -73,13 +72,12 @@ ApplicationWindow {
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
height: parent.height - Nheko.paddingSmall * 2
|
height: parent.height - Nheko.paddingSmall * 2
|
||||||
width: 3
|
width: 3
|
||||||
color: Nheko.colors.highlight
|
color: palette.highlight
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
footer: Button {
|
footer: Button {
|
||||||
palette: Nheko.colors
|
|
||||||
onClicked: addFilesDialog.open()
|
onClicked: addFilesDialog.open()
|
||||||
width: ListView.view.width
|
width: ListView.view.width
|
||||||
text: qsTr("Add images")
|
text: qsTr("Add images")
|
||||||
|
@ -100,11 +98,11 @@ ApplicationWindow {
|
||||||
delegate: AvatarListTile {
|
delegate: AvatarListTile {
|
||||||
id: packItem
|
id: packItem
|
||||||
|
|
||||||
property color background: Nheko.colors.window
|
property color background: palette.window
|
||||||
property color importantText: Nheko.colors.text
|
property color importantText: palette.text
|
||||||
property color unimportantText: Nheko.colors.buttonText
|
property color unimportantText: palette.buttonText
|
||||||
property color bubbleBackground: Nheko.colors.highlight
|
property color bubbleBackground: palette.highlight
|
||||||
property color bubbleText: Nheko.colors.highlightedText
|
property color bubbleText: palette.highlightedText
|
||||||
required property string shortCode
|
required property string shortCode
|
||||||
required property string url
|
required property string url
|
||||||
required property string body
|
required property string body
|
||||||
|
@ -129,7 +127,7 @@ ApplicationWindow {
|
||||||
id: packinfoC
|
id: packinfoC
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
|
|
||||||
GridLayout {
|
GridLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
|
@ -23,8 +23,7 @@ ApplicationWindow {
|
||||||
title: qsTr("Image pack settings")
|
title: qsTr("Image pack settings")
|
||||||
height: 600
|
height: 600
|
||||||
width: 800
|
width: 800
|
||||||
palette: Nheko.colors
|
color: palette.base
|
||||||
color: Nheko.colors.base
|
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
|
@ -64,7 +63,6 @@ ApplicationWindow {
|
||||||
|
|
||||||
footer: ColumnLayout {
|
footer: ColumnLayout {
|
||||||
Button {
|
Button {
|
||||||
palette: Nheko.colors
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
var dialog = packEditor.createObject(timelineRoot, {
|
var dialog = packEditor.createObject(timelineRoot, {
|
||||||
"imagePack": packlist.newPack(false)
|
"imagePack": packlist.newPack(false)
|
||||||
|
@ -78,7 +76,6 @@ ApplicationWindow {
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
palette: Nheko.colors
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
var dialog = packEditor.createObject(timelineRoot, {
|
var dialog = packEditor.createObject(timelineRoot, {
|
||||||
"imagePack": packlist.newPack(true)
|
"imagePack": packlist.newPack(true)
|
||||||
|
@ -96,11 +93,11 @@ ApplicationWindow {
|
||||||
delegate: AvatarListTile {
|
delegate: AvatarListTile {
|
||||||
id: packItem
|
id: packItem
|
||||||
|
|
||||||
property color background: Nheko.colors.window
|
property color background: palette.window
|
||||||
property color importantText: Nheko.colors.text
|
property color importantText: palette.text
|
||||||
property color unimportantText: Nheko.colors.buttonText
|
property color unimportantText: palette.buttonText
|
||||||
property color bubbleBackground: Nheko.colors.highlight
|
property color bubbleBackground: palette.highlight
|
||||||
property color bubbleText: Nheko.colors.highlightedText
|
property color bubbleText: palette.highlightedText
|
||||||
required property string displayName
|
required property string displayName
|
||||||
required property bool fromAccountData
|
required property bool fromAccountData
|
||||||
required property bool fromCurrentRoom
|
required property bool fromCurrentRoom
|
||||||
|
@ -135,7 +132,7 @@ ApplicationWindow {
|
||||||
id: packinfoC
|
id: packinfoC
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: packinfo
|
id: packinfo
|
||||||
|
@ -243,7 +240,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: hovered ? Nheko.colors.highlight : 'transparent'
|
color: hovered ? palette.highlight : 'transparent'
|
||||||
radius: 5
|
radius: 5
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -37,7 +37,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
id: promptLabel
|
id: promptLabel
|
||||||
|
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
MatrixTextField {
|
MatrixTextField {
|
||||||
|
|
|
@ -40,8 +40,7 @@ ApplicationWindow {
|
||||||
title: qsTr("Invite users to %1").arg(invitees.room.plainRoomName)
|
title: qsTr("Invite users to %1").arg(invitees.room.plainRoomName)
|
||||||
height: 380
|
height: 380
|
||||||
width: 340
|
width: 340
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
Shortcut {
|
Shortcut {
|
||||||
|
@ -74,12 +73,12 @@ ApplicationWindow {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
id: inviteeUserid
|
id: inviteeUserid
|
||||||
text: model.displayName != "" ? model.displayName : model.userid
|
text: model.displayName != "" ? model.displayName : model.userid
|
||||||
color: inviteeButton.hovered ? Nheko.colors.highlightedText: Nheko.colors.text
|
color: inviteeButton.hovered ? palette.highlightedText: palette.text
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
}
|
}
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
border.color: Nheko.colors.text
|
border.color: palette.text
|
||||||
color: inviteeButton.hovered ? Nheko.colors.highlight : Nheko.colors.window
|
color: inviteeButton.hovered ? palette.highlight : palette.window
|
||||||
border.width: 1
|
border.width: 1
|
||||||
radius: inviteeButton.height / 2
|
radius: inviteeButton.height / 2
|
||||||
}
|
}
|
||||||
|
@ -90,7 +89,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Search user")
|
text: qsTr("Search user")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Nheko.paddingMedium
|
spacing: Nheko.paddingMedium
|
||||||
|
@ -100,7 +99,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
property bool isValidMxid: text.match("@.+?:.{3,}")
|
property bool isValidMxid: text.match("@.+?:.{3,}")
|
||||||
|
|
||||||
backgroundColor: Nheko.colors.window
|
backgroundColor: palette.window
|
||||||
placeholderText: qsTr("@joe:matrix.org", "Example user id. The name 'joe' can be localized however you want.")
|
placeholderText: qsTr("@joe:matrix.org", "Example user id. The name 'joe' can be localized however you want.")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
onAccepted: {
|
onAccepted: {
|
||||||
|
@ -158,7 +157,7 @@ ApplicationWindow {
|
||||||
avatarUrl: profile? profile.avatarUrl : ""
|
avatarUrl: profile? profile.avatarUrl : ""
|
||||||
userid: inviteeEntry.text
|
userid: inviteeEntry.text
|
||||||
onClicked: addInvite(inviteeEntry.text, displayName, avatarUrl)
|
onClicked: addInvite(inviteeEntry.text, displayName, avatarUrl)
|
||||||
bgColor: del3.hovered ? Nheko.colors.dark : inviteDialogRoot.color
|
bgColor: del3.hovered ? palette.dark : inviteDialogRoot.color
|
||||||
}
|
}
|
||||||
ListView {
|
ListView {
|
||||||
visible: !inviteeEntry.isValidMxid
|
visible: !inviteeEntry.isValidMxid
|
||||||
|
@ -175,7 +174,7 @@ ApplicationWindow {
|
||||||
userid: model.userid
|
userid: model.userid
|
||||||
avatarUrl: model.avatarUrl
|
avatarUrl: model.avatarUrl
|
||||||
onClicked: addInvite(userid, displayName, avatarUrl)
|
onClicked: addInvite(userid, displayName, avatarUrl)
|
||||||
bgColor: del2.hovered ? Nheko.colors.dark : inviteDialogRoot.color
|
bgColor: del2.hovered ? palette.dark : inviteDialogRoot.color
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
@ -202,7 +201,7 @@ ApplicationWindow {
|
||||||
userid: model.mxid
|
userid: model.mxid
|
||||||
avatarUrl: model.avatarUrl
|
avatarUrl: model.avatarUrl
|
||||||
displayName: model.displayName
|
displayName: model.displayName
|
||||||
bgColor: del.hovered ? Nheko.colors.dark : inviteDialogRoot.color
|
bgColor: del.hovered ? palette.dark : inviteDialogRoot.color
|
||||||
ImageButton {
|
ImageButton {
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Nheko.paddingSmall
|
anchors.rightMargin: Nheko.paddingSmall
|
||||||
|
|
|
@ -14,8 +14,7 @@ ApplicationWindow {
|
||||||
title: qsTr("Join room")
|
title: qsTr("Join room")
|
||||||
modality: Qt.WindowModal
|
modality: Qt.WindowModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
width: 350
|
width: 350
|
||||||
height: fontMetrics.lineSpacing * 7
|
height: fontMetrics.lineSpacing * 7
|
||||||
|
|
||||||
|
@ -33,7 +32,7 @@ ApplicationWindow {
|
||||||
id: promptLabel
|
id: promptLabel
|
||||||
|
|
||||||
text: qsTr("Room ID or alias")
|
text: qsTr("Room ID or alias")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
MatrixTextField {
|
MatrixTextField {
|
||||||
|
|
|
@ -31,7 +31,7 @@ ApplicationWindow {
|
||||||
id: promptLabel
|
id: promptLabel
|
||||||
|
|
||||||
Layout.columnSpan: 2
|
Layout.columnSpan: 2
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
|
|
@ -41,14 +41,13 @@ ApplicationWindow {
|
||||||
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: false
|
Layout.fillHeight: false
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.bottomMargin: Nheko.paddingMedium
|
Layout.bottomMargin: Nheko.paddingMedium
|
||||||
}
|
}
|
||||||
|
|
||||||
TabBar {
|
TabBar {
|
||||||
id: bar
|
id: bar
|
||||||
width: parent.width
|
width: parent.width
|
||||||
palette: Nheko.colors
|
|
||||||
|
|
||||||
NhekoTabButton {
|
NhekoTabButton {
|
||||||
text: qsTr("Roles")
|
text: qsTr("Roles")
|
||||||
|
@ -60,7 +59,7 @@ ApplicationWindow {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
border.width: 1
|
border.width: 1
|
||||||
border.color: Nheko.theme.separator
|
border.color: Nheko.theme.separator
|
||||||
|
|
||||||
|
@ -78,7 +77,7 @@ ApplicationWindow {
|
||||||
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: false
|
Layout.fillHeight: false
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ReorderableListview {
|
ReorderableListview {
|
||||||
|
@ -91,7 +90,7 @@ ApplicationWindow {
|
||||||
Column {
|
Column {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
Text { visible: model.isType; text: model.displayName; color: Nheko.colors.text}
|
Text { visible: model.isType; text: model.displayName; color: palette.text}
|
||||||
Text {
|
Text {
|
||||||
visible: !model.isType;
|
visible: !model.isType;
|
||||||
text: {
|
text: {
|
||||||
|
@ -104,7 +103,7 @@ ApplicationWindow {
|
||||||
else
|
else
|
||||||
return qsTr("Custom (%1)").arg(model.powerlevel)
|
return qsTr("Custom (%1)").arg(model.powerlevel)
|
||||||
}
|
}
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -137,7 +136,7 @@ ApplicationWindow {
|
||||||
z: 5
|
z: 5
|
||||||
visible: false
|
visible: false
|
||||||
|
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
Keys.onPressed: {
|
Keys.onPressed: {
|
||||||
if (typeEntry.text.includes('.') && event.matches(StandardKey.InsertParagraphSeparator)) {
|
if (typeEntry.text.includes('.') && event.matches(StandardKey.InsertParagraphSeparator)) {
|
||||||
|
@ -166,7 +165,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
visible: false
|
visible: false
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Nheko.paddingMedium
|
spacing: Nheko.paddingMedium
|
||||||
|
@ -238,7 +237,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
width: parent.width
|
width: parent.width
|
||||||
//font.pixelSize: Math.ceil(quickSwitcher.textHeight * 0.6)
|
//font.pixelSize: Math.ceil(quickSwitcher.textHeight * 0.6)
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
onTextEdited: {
|
onTextEdited: {
|
||||||
userCompleter.completer.searchString = text;
|
userCompleter.completer.searchString = text;
|
||||||
}
|
}
|
||||||
|
@ -318,11 +317,11 @@ ApplicationWindow {
|
||||||
if (model.isUser)
|
if (model.isUser)
|
||||||
return model.avatarUrl.replace("mxc://", "image://MxcImage/")
|
return model.avatarUrl.replace("mxc://", "image://MxcImage/")
|
||||||
else if (editingModel.adminLevel >= model.powerlevel)
|
else if (editingModel.adminLevel >= model.powerlevel)
|
||||||
return "image://colorimage/:/icons/icons/ui/ribbon_star.svg?" + Nheko.colors.buttonText;
|
return "image://colorimage/:/icons/icons/ui/ribbon_star.svg?" + palette.buttonText;
|
||||||
else if (editingModel.moderatorLevel >= model.powerlevel)
|
else if (editingModel.moderatorLevel >= model.powerlevel)
|
||||||
return "image://colorimage/:/icons/icons/ui/ribbon.svg?" + Nheko.colors.buttonText;
|
return "image://colorimage/:/icons/icons/ui/ribbon.svg?" + palette.buttonText;
|
||||||
else
|
else
|
||||||
return "image://colorimage/:/icons/icons/ui/person.svg?" + Nheko.colors.buttonText;
|
return "image://colorimage/:/icons/icons/ui/person.svg?" + palette.buttonText;
|
||||||
}
|
}
|
||||||
displayName: model.displayName
|
displayName: model.displayName
|
||||||
enabled: false
|
enabled: false
|
||||||
|
@ -330,8 +329,8 @@ ApplicationWindow {
|
||||||
Column {
|
Column {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
Text { visible: model.isUser; text: model.displayName; color: Nheko.colors.text}
|
Text { visible: model.isUser; text: model.displayName; color: palette.text}
|
||||||
Text { visible: model.isUser; text: model.mxid; color: Nheko.colors.text}
|
Text { visible: model.isUser; text: model.mxid; color: palette.text}
|
||||||
Text {
|
Text {
|
||||||
visible: !model.isUser;
|
visible: !model.isUser;
|
||||||
text: {
|
text: {
|
||||||
|
@ -342,7 +341,7 @@ ApplicationWindow {
|
||||||
else
|
else
|
||||||
return qsTr("Custom (%1)").arg(model.powerlevel)
|
return qsTr("Custom (%1)").arg(model.powerlevel)
|
||||||
}
|
}
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -21,8 +21,7 @@ ApplicationWindow {
|
||||||
minimumHeight: 450
|
minimumHeight: 450
|
||||||
width: 450
|
width: 450
|
||||||
height: 680
|
height: 680
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
title: qsTr("Apply permission changes")
|
title: qsTr("Apply permission changes")
|
||||||
|
@ -43,7 +42,7 @@ ApplicationWindow {
|
||||||
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 1.1)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: false
|
Layout.fillHeight: false
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.bottomMargin: Nheko.paddingMedium
|
Layout.bottomMargin: Nheko.paddingMedium
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -55,7 +54,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Apply permissions recursively")
|
text: qsTr("Apply permissions recursively")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ToggleButton {
|
ToggleButton {
|
||||||
|
@ -67,7 +66,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Overwrite exisiting modifications in rooms")
|
text: qsTr("Overwrite exisiting modifications in rooms")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ToggleButton {
|
ToggleButton {
|
||||||
|
@ -103,7 +102,7 @@ ApplicationWindow {
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: model.displayName
|
text: model.displayName
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
}
|
}
|
||||||
|
@ -117,7 +116,7 @@ ApplicationWindow {
|
||||||
return qsTr("Permissions synchronized with community")
|
return qsTr("Permissions synchronized with community")
|
||||||
}
|
}
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,8 +13,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
height: 420
|
height: 420
|
||||||
width: 420
|
width: 420
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
flags: Qt.Tool | Qt.WindowStaysOnTopHint | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Tool | Qt.WindowStaysOnTopHint | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
Shortcut {
|
Shortcut {
|
||||||
|
@ -25,14 +24,13 @@ ApplicationWindow {
|
||||||
ScrollView {
|
ScrollView {
|
||||||
anchors.margins: Nheko.paddingMedium
|
anchors.margins: Nheko.paddingMedium
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
palette: Nheko.colors
|
|
||||||
padding: Nheko.paddingMedium
|
padding: Nheko.paddingMedium
|
||||||
|
|
||||||
TextArea {
|
TextArea {
|
||||||
id: rawMessageView
|
id: rawMessageView
|
||||||
|
|
||||||
font: Nheko.monospaceFont()
|
font: Nheko.monospaceFont()
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
readOnly: true
|
readOnly: true
|
||||||
selectByMouse: !Settings.mobileMode
|
selectByMouse: !Settings.mobileMode
|
||||||
textFormat: Text.PlainText
|
textFormat: Text.PlainText
|
||||||
|
@ -40,7 +38,7 @@ ApplicationWindow {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.base
|
color: palette.base
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,8 +18,7 @@ ApplicationWindow {
|
||||||
width: 340
|
width: 340
|
||||||
minimumHeight: 380
|
minimumHeight: 380
|
||||||
minimumWidth: headerTitle.width + 2 * Nheko.paddingMedium
|
minimumWidth: headerTitle.width + 2 * Nheko.paddingMedium
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
Shortcut {
|
Shortcut {
|
||||||
|
@ -35,14 +34,13 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
id: headerTitle
|
id: headerTitle
|
||||||
|
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
text: qsTr("Read receipts")
|
text: qsTr("Read receipts")
|
||||||
font.pointSize: fontMetrics.font.pointSize * 1.5
|
font.pointSize: fontMetrics.font.pointSize * 1.5
|
||||||
}
|
}
|
||||||
|
|
||||||
ScrollView {
|
ScrollView {
|
||||||
palette: Nheko.colors
|
|
||||||
padding: Nheko.paddingMedium
|
padding: Nheko.paddingMedium
|
||||||
ScrollBar.horizontal.visible: false
|
ScrollBar.horizontal.visible: false
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
|
@ -67,7 +65,7 @@ ApplicationWindow {
|
||||||
ToolTip.visible: hovered
|
ToolTip.visible: hovered
|
||||||
ToolTip.text: model.mxid
|
ToolTip.text: model.mxid
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: del.hovered ? Nheko.colors.dark : readReceiptsRoot.color
|
color: del.hovered ? palette.dark : readReceiptsRoot.color
|
||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
|
@ -94,7 +92,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
ElidedLabel {
|
ElidedLabel {
|
||||||
text: model.displayName
|
text: model.displayName
|
||||||
color: TimelineManager.userColor(model ? model.mxid : "", Nheko.colors.window)
|
color: TimelineManager.userColor(model ? model.mxid : "", palette.window)
|
||||||
font.pointSize: fontMetrics.font.pointSize
|
font.pointSize: fontMetrics.font.pointSize
|
||||||
elideWidth: del.width - Nheko.paddingMedium - avatar.width
|
elideWidth: del.width - Nheko.paddingMedium - avatar.width
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
@ -102,7 +100,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
ElidedLabel {
|
ElidedLabel {
|
||||||
text: model.timestamp
|
text: model.timestamp
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
font.pointSize: fontMetrics.font.pointSize * 0.9
|
font.pointSize: fontMetrics.font.pointSize * 0.9
|
||||||
elideWidth: del.width - Nheko.paddingMedium - avatar.width
|
elideWidth: del.width - Nheko.paddingMedium - avatar.width
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
|
@ -18,8 +18,7 @@ ApplicationWindow {
|
||||||
minimumHeight: 340
|
minimumHeight: 340
|
||||||
height: 420
|
height: 420
|
||||||
width: 650
|
width: 650
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
title: qsTr("Explore Public Rooms")
|
title: qsTr("Explore Public Rooms")
|
||||||
|
@ -43,9 +42,9 @@ ApplicationWindow {
|
||||||
delegate: Rectangle {
|
delegate: Rectangle {
|
||||||
id: roomDirDelegate
|
id: roomDirDelegate
|
||||||
|
|
||||||
property color background: Nheko.colors.window
|
property color background: palette.window
|
||||||
property color importantText: Nheko.colors.text
|
property color importantText: palette.text
|
||||||
property color unimportantText: Nheko.colors.buttonText
|
property color unimportantText: palette.buttonText
|
||||||
property int avatarSize: fontMetrics.height * 3.2
|
property int avatarSize: fontMetrics.height * 3.2
|
||||||
|
|
||||||
color: background
|
color: background
|
||||||
|
@ -143,7 +142,7 @@ ApplicationWindow {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
anchors.margins: Nheko.paddingLarge
|
anchors.margins: Nheko.paddingLarge
|
||||||
running: visible
|
running: visible
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -164,7 +163,7 @@ ApplicationWindow {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
font.pixelSize: fontMetrics.font.pixelSize
|
font.pixelSize: fontMetrics.font.pixelSize
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
placeholderText: qsTr("Search for public rooms")
|
placeholderText: qsTr("Search for public rooms")
|
||||||
onTextChanged: searchTimer.restart()
|
onTextChanged: searchTimer.restart()
|
||||||
|
|
||||||
|
@ -176,7 +175,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Layout.minimumWidth: 0.3 * header.width
|
Layout.minimumWidth: 0.3 * header.width
|
||||||
Layout.maximumWidth: 0.3 * header.width
|
Layout.maximumWidth: 0.3 * header.width
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
placeholderText: qsTr("Choose custom homeserver")
|
placeholderText: qsTr("Choose custom homeserver")
|
||||||
onTextChanged: publicRooms.setMatrixServer(text)
|
onTextChanged: publicRooms.setMatrixServer(text)
|
||||||
}
|
}
|
||||||
|
|
|
@ -20,8 +20,7 @@ ApplicationWindow {
|
||||||
height: 650
|
height: 650
|
||||||
width: 420
|
width: 420
|
||||||
minimumHeight: 420
|
minimumHeight: 420
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
|
||||||
Shortcut {
|
Shortcut {
|
||||||
|
@ -77,7 +76,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Sort by: ")
|
text: qsTr("Sort by: ")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -94,7 +93,6 @@ ApplicationWindow {
|
||||||
}
|
}
|
||||||
|
|
||||||
ScrollView {
|
ScrollView {
|
||||||
palette: Nheko.colors
|
|
||||||
padding: Nheko.paddingMedium
|
padding: Nheko.paddingMedium
|
||||||
ScrollBar.horizontal.visible: false
|
ScrollBar.horizontal.visible: false
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
|
@ -123,7 +121,7 @@ ApplicationWindow {
|
||||||
height: memberLayout.implicitHeight + Nheko.paddingSmall * 2
|
height: memberLayout.implicitHeight + Nheko.paddingSmall * 2
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: del.hovered ? Nheko.colors.dark : roomMembersRoot.color
|
color: del.hovered ? palette.dark : roomMembersRoot.color
|
||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
|
@ -158,7 +156,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
ElidedLabel {
|
ElidedLabel {
|
||||||
fullText: model.mxid
|
fullText: model.mxid
|
||||||
color: del.hovered ? Nheko.colors.brightText : Nheko.colors.buttonText
|
color: del.hovered ? palette.brightText : palette.buttonText
|
||||||
font.pixelSize: Math.ceil(fontMetrics.font.pixelSize * 0.9)
|
font.pixelSize: Math.ceil(fontMetrics.font.pixelSize * 0.9)
|
||||||
elideWidth: del.width - Nheko.paddingMedium * 2 - avatar.width - encryptInd.width
|
elideWidth: del.width - Nheko.paddingMedium * 2 - avatar.width - encryptInd.width
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
@ -184,7 +182,7 @@ ApplicationWindow {
|
||||||
Layout.preferredHeight: 16
|
Layout.preferredHeight: 16
|
||||||
sourceSize.width: width
|
sourceSize.width: width
|
||||||
sourceSize.height: height
|
sourceSize.height: height
|
||||||
source: sourceUrl + (ma.hovered ? Nheko.colors.highlight : Nheko.colors.buttonText)
|
source: sourceUrl + (ma.hovered ? palette.highlight : palette.buttonText)
|
||||||
ToolTip.visible: ma.hovered
|
ToolTip.visible: ma.hovered
|
||||||
ToolTip.text: {
|
ToolTip.text: {
|
||||||
if (isAdmin)
|
if (isAdmin)
|
||||||
|
|
|
@ -20,8 +20,7 @@ ApplicationWindow {
|
||||||
minimumHeight: 450
|
minimumHeight: 450
|
||||||
width: 450
|
width: 450
|
||||||
height: 680
|
height: 680
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
title: qsTr("Room Settings")
|
title: qsTr("Room Settings")
|
||||||
|
@ -79,7 +78,7 @@ ApplicationWindow {
|
||||||
Spinner {
|
Spinner {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
visible: roomSettings.isLoading
|
visible: roomSettings.isLoading
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
running: roomSettings.isLoading
|
running: roomSettings.isLoading
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -130,7 +129,7 @@ ApplicationWindow {
|
||||||
textFormat: isNameEditingAllowed ? TextEdit.PlainText : TextEdit.RichText
|
textFormat: isNameEditingAllowed ? TextEdit.PlainText : TextEdit.RichText
|
||||||
text: isNameEditingAllowed ? roomSettings.plainRoomName : roomSettings.roomName
|
text: isNameEditingAllowed ? roomSettings.plainRoomName : roomSettings.roomName
|
||||||
font.pixelSize: fontMetrics.font.pixelSize * 2
|
font.pixelSize: fontMetrics.font.pixelSize * 2
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.maximumWidth: parent.width - (Nheko.paddingSmall * 2) - nameChangeButton.anchors.leftMargin - (nameChangeButton.width * 2)
|
Layout.maximumWidth: parent.width - (Nheko.paddingSmall * 2) - nameChangeButton.anchors.leftMargin - (nameChangeButton.width * 2)
|
||||||
|
@ -178,7 +177,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("%n member(s)", "", roomSettings.memberCount)
|
text: qsTr("%n member(s)", "", roomSettings.memberCount)
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ImageButton {
|
ImageButton {
|
||||||
|
@ -213,7 +212,7 @@ ApplicationWindow {
|
||||||
wrapMode: TextEdit.WordWrap
|
wrapMode: TextEdit.WordWrap
|
||||||
background: null
|
background: null
|
||||||
selectByMouse: !Settings.mobileMode
|
selectByMouse: !Settings.mobileMode
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
horizontalAlignment: TextEdit.AlignHCenter
|
horizontalAlignment: TextEdit.AlignHCenter
|
||||||
onLinkActivated: Nheko.openLink(link)
|
onLinkActivated: Nheko.openLink(link)
|
||||||
|
|
||||||
|
@ -263,7 +262,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("SETTINGS")
|
text: qsTr("SETTINGS")
|
||||||
font.bold: true
|
font.bold: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
@ -273,7 +272,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Notifications")
|
text: qsTr("Notifications")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -289,7 +288,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Anyone can join")
|
text: qsTr("Anyone can join")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ToggleButton {
|
ToggleButton {
|
||||||
|
@ -303,7 +302,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Allow knocking")
|
text: qsTr("Allow knocking")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
visible: knockingButton.visible
|
visible: knockingButton.visible
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -322,7 +321,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Allow joining via other rooms")
|
text: qsTr("Allow joining via other rooms")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
visible: restrictedButton.visible
|
visible: restrictedButton.visible
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -341,7 +340,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Rooms to join via")
|
text: qsTr("Rooms to join via")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
visible: allowedRoomsButton.visible
|
visible: allowedRoomsButton.visible
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -360,7 +359,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Allow guests to join")
|
text: qsTr("Allow guests to join")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ToggleButton {
|
ToggleButton {
|
||||||
|
@ -383,7 +382,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Encryption")
|
text: qsTr("Encryption")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
ToggleButton {
|
ToggleButton {
|
||||||
|
@ -422,7 +421,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Permission")
|
text: qsTr("Permission")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
|
@ -434,7 +433,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Aliases")
|
text: qsTr("Aliases")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
|
@ -446,7 +445,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Sticker & Emote Settings")
|
text: qsTr("Sticker & Emote Settings")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
|
@ -458,7 +457,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Hidden events")
|
text: qsTr("Hidden events")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
HiddenEventsDialog {
|
HiddenEventsDialog {
|
||||||
|
@ -487,7 +486,7 @@ ApplicationWindow {
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("INFO")
|
text: qsTr("INFO")
|
||||||
font.bold: true
|
font.bold: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
@ -496,7 +495,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Internal ID")
|
text: qsTr("Internal ID")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
AbstractButton { // AbstractButton does not allow setting text color
|
AbstractButton { // AbstractButton does not allow setting text color
|
||||||
|
@ -507,7 +506,7 @@ ApplicationWindow {
|
||||||
id: idLabel
|
id: idLabel
|
||||||
text: roomSettings.roomId
|
text: roomSettings.roomId
|
||||||
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 0.8)
|
font.pixelSize: Math.floor(fontMetrics.font.pixelSize * 0.8)
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
width: parent.width
|
width: parent.width
|
||||||
horizontalAlignment: Text.AlignRight
|
horizontalAlignment: Text.AlignRight
|
||||||
wrapMode: Text.WrapAnywhere
|
wrapMode: Text.WrapAnywhere
|
||||||
|
@ -531,14 +530,14 @@ ApplicationWindow {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Room Version")
|
text: qsTr("Room Version")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: roomSettings.roomVersion
|
text: roomSettings.roomVersion
|
||||||
font.pixelSize: fontMetrics.font.pixelSize
|
font.pixelSize: fontMetrics.font.pixelSize
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignRight
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -22,8 +22,7 @@ ApplicationWindow {
|
||||||
width: 420
|
width: 420
|
||||||
minimumWidth: 150
|
minimumWidth: 150
|
||||||
minimumHeight: 150
|
minimumHeight: 150
|
||||||
palette: Nheko.colors
|
color: palette.window
|
||||||
color: Nheko.colors.window
|
|
||||||
title: profile.isGlobalUserProfile ? qsTr("Global User Profile") : qsTr("Room User Profile")
|
title: profile.isGlobalUserProfile ? qsTr("Global User Profile") : qsTr("Room User Profile")
|
||||||
modality: Qt.NonModal
|
modality: Qt.NonModal
|
||||||
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
flags: Qt.Dialog | Qt.WindowCloseButtonHint | Qt.WindowTitleHint
|
||||||
|
@ -89,7 +88,7 @@ ApplicationWindow {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
running: profile.isLoading
|
running: profile.isLoading
|
||||||
visible: profile.isLoading
|
visible: profile.isLoading
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
@ -137,7 +136,7 @@ ApplicationWindow {
|
||||||
readOnly: !isUsernameEditingAllowed
|
readOnly: !isUsernameEditingAllowed
|
||||||
text: profile.displayName
|
text: profile.displayName
|
||||||
font.pixelSize: 20
|
font.pixelSize: 20
|
||||||
color: TimelineManager.userColor(profile.userid, Nheko.colors.window)
|
color: TimelineManager.userColor(profile.userid, palette.window)
|
||||||
font.bold: true
|
font.bold: true
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.maximumWidth: parent.width - (Nheko.paddingSmall * 2) - usernameChangeButton.anchors.leftMargin - (usernameChangeButton.width * 2)
|
Layout.maximumWidth: parent.width - (Nheko.paddingSmall * 2) - usernameChangeButton.anchors.leftMargin - (usernameChangeButton.width * 2)
|
||||||
|
@ -315,7 +314,6 @@ ApplicationWindow {
|
||||||
|
|
||||||
onCurrentIndexChanged: devicelist.selectedTab = currentIndex
|
onCurrentIndexChanged: devicelist.selectedTab = currentIndex
|
||||||
|
|
||||||
palette: Nheko.colors
|
|
||||||
|
|
||||||
NhekoTabButton {
|
NhekoTabButton {
|
||||||
text: qsTr("Devices")
|
text: qsTr("Devices")
|
||||||
|
@ -354,7 +352,7 @@ ApplicationWindow {
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
font.bold: true
|
font.bold: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: deviceId
|
text: deviceId
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -400,7 +398,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
readOnly: !deviceNameRow.isEditingAllowed
|
readOnly: !deviceNameRow.isEditingAllowed
|
||||||
text: deviceName
|
text: deviceName
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
|
@ -435,7 +433,7 @@ ApplicationWindow {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: qsTr("Last seen %1 from %2").arg(new Date(lastTs).toLocaleString(Locale.ShortFormat)).arg(lastIp ? lastIp : "???")
|
text: qsTr("Last seen %1 from %2").arg(new Date(lastTs).toLocaleString(Locale.ShortFormat)).arg(lastIp ? lastIp : "???")
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -504,7 +502,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
ElidedLabel {
|
ElidedLabel {
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
elideWidth: width
|
elideWidth: width
|
||||||
fullText: roomName
|
fullText: roomName
|
||||||
|
@ -527,7 +525,7 @@ ApplicationWindow {
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,14 +13,13 @@ Menu {
|
||||||
id: stickerPopup
|
id: stickerPopup
|
||||||
|
|
||||||
property var callback
|
property var callback
|
||||||
property var colors
|
|
||||||
property string roomid
|
property string roomid
|
||||||
property alias model: gridView.model
|
property alias model: gridView.model
|
||||||
required property bool emoji
|
required property bool emoji
|
||||||
property var textArea
|
property var textArea
|
||||||
property real highlightHue: Nheko.colors.highlight.hslHue
|
property real highlightHue: palette.highlight.hslHue
|
||||||
property real highlightSat: Nheko.colors.highlight.hslSaturation
|
property real highlightSat: palette.highlight.hslSaturation
|
||||||
property real highlightLight: Nheko.colors.highlight.hslLightness
|
property real highlightLight: palette.highlight.hslLightness
|
||||||
readonly property int stickerDim: emoji ? 48 : 128
|
readonly property int stickerDim: emoji ? 48 : 128
|
||||||
readonly property int stickerDimPad: stickerDim + Nheko.paddingSmall
|
readonly property int stickerDimPad: stickerDim + Nheko.paddingSmall
|
||||||
readonly property int stickersPerRow: emoji ? 7 : 3
|
readonly property int stickersPerRow: emoji ? 7 : 3
|
||||||
|
@ -44,7 +43,7 @@ Menu {
|
||||||
width: sidebarAvatarSize + Nheko.paddingSmall + stickersPerRow * stickerDimPad + 20
|
width: sidebarAvatarSize + Nheko.paddingSmall + stickersPerRow * stickerDimPad + 20
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
height: columnView.implicitHeight + Nheko.paddingSmall*2
|
height: columnView.implicitHeight + Nheko.paddingSmall*2
|
||||||
width: sidebarAvatarSize + Nheko.paddingSmall + stickersPerRow * stickerDimPad + 20
|
width: sidebarAvatarSize + Nheko.paddingSmall + stickersPerRow * stickerDimPad + 20
|
||||||
|
|
||||||
|
@ -66,10 +65,8 @@ Menu {
|
||||||
Layout.preferredWidth: stickersPerRow * stickerDimPad + 20 - Nheko.paddingSmall
|
Layout.preferredWidth: stickersPerRow * stickerDimPad + 20 - Nheko.paddingSmall
|
||||||
Layout.row: 0
|
Layout.row: 0
|
||||||
Layout.column: 1
|
Layout.column: 1
|
||||||
palette: Nheko.colors
|
|
||||||
background: null
|
background: null
|
||||||
placeholderTextColor: Nheko.colors.buttonText
|
placeholderTextColor: palette.buttonText
|
||||||
color: Nheko.colors.text
|
|
||||||
placeholderText: qsTr("Search")
|
placeholderText: qsTr("Search")
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
rightPadding: clearSearch.width
|
rightPadding: clearSearch.width
|
||||||
|
@ -125,7 +122,7 @@ Menu {
|
||||||
section.delegate: Rectangle {
|
section.delegate: Rectangle {
|
||||||
width: gridView.width
|
width: gridView.width
|
||||||
height: childrenRect.height
|
height: childrenRect.height
|
||||||
color: Nheko.colors.alternateBase
|
color: palette.alternateBase
|
||||||
|
|
||||||
required property string section
|
required property string section
|
||||||
|
|
||||||
|
@ -133,7 +130,6 @@ Menu {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
text: parent.section
|
text: parent.section
|
||||||
color: Nheko.colors.text
|
|
||||||
font.bold: true
|
font.bold: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -196,7 +192,6 @@ Menu {
|
||||||
font.family: Settings.emojiFont
|
font.family: Settings.emojiFont
|
||||||
font.pixelSize: 36
|
font.pixelSize: 36
|
||||||
text: del.modelData.unicode.replace('\ufe0f', '')
|
text: del.modelData.unicode.replace('\ufe0f', '')
|
||||||
color: Nheko.colors.text
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -213,7 +208,7 @@ Menu {
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: hovered ? Nheko.colors.highlight : 'transparent'
|
color: hovered ? palette.highlight : 'transparent'
|
||||||
radius: 5
|
radius: 5
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,6 @@ Item {
|
||||||
id: scroll
|
id: scroll
|
||||||
|
|
||||||
clip: false
|
clip: false
|
||||||
palette: Nheko.colors
|
|
||||||
ScrollBar.horizontal.visible: false
|
ScrollBar.horizontal.visible: false
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
|
@ -71,7 +70,7 @@ Item {
|
||||||
|
|
||||||
visible: running
|
visible: running
|
||||||
running: login.lookingUpHs
|
running: login.lookingUpHs
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -127,7 +126,7 @@ Item {
|
||||||
|
|
||||||
visible: running
|
visible: running
|
||||||
running: login.loggingIn
|
running: login.loggingIn
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -25,7 +25,6 @@ Item {
|
||||||
id: scroll
|
id: scroll
|
||||||
|
|
||||||
clip: false
|
clip: false
|
||||||
palette: Nheko.colors
|
|
||||||
ScrollBar.horizontal.visible: false
|
ScrollBar.horizontal.visible: false
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
|
@ -70,7 +69,7 @@ Item {
|
||||||
|
|
||||||
visible: running
|
visible: running
|
||||||
running: regis.lookingUpHs
|
running: regis.lookingUpHs
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -102,7 +101,7 @@ Item {
|
||||||
|
|
||||||
visible: running
|
visible: running
|
||||||
running: regis.lookingUpUsername
|
running: regis.lookingUpUsername
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
|
|
||||||
Image {
|
Image {
|
||||||
|
@ -178,7 +177,7 @@ Item {
|
||||||
|
|
||||||
visible: running
|
visible: running
|
||||||
running: regis.registering
|
running: regis.registering
|
||||||
foreground: Nheko.colors.mid
|
foreground: palette.mid
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,12 +16,11 @@ Rectangle {
|
||||||
|
|
||||||
property int collapsePoint: 600
|
property int collapsePoint: 600
|
||||||
property bool collapsed: width < collapsePoint
|
property bool collapsed: width < collapsePoint
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
|
|
||||||
ScrollView {
|
ScrollView {
|
||||||
id: scroll
|
id: scroll
|
||||||
|
|
||||||
palette: Nheko.colors
|
|
||||||
ScrollBar.horizontal.visible: false
|
ScrollBar.horizontal.visible: false
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.topMargin: (collapsed? backButton.height : 0)+Nheko.paddingLarge
|
anchors.topMargin: (collapsed? backButton.height : 0)+Nheko.paddingLarge
|
||||||
|
@ -51,7 +50,7 @@ Rectangle {
|
||||||
Label {
|
Label {
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: model.name
|
text: model.name
|
||||||
//Layout.column: 0
|
//Layout.column: 0
|
||||||
Layout.columnSpan: (model.type == UserSettingsModel.SectionTitle && !userSettingsDialog.collapsed) ? 2 : 1
|
Layout.columnSpan: (model.type == UserSettingsModel.SectionTitle && !userSettingsDialog.collapsed) ? 2 : 1
|
||||||
|
@ -159,7 +158,7 @@ Rectangle {
|
||||||
DelegateChoice {
|
DelegateChoice {
|
||||||
roleValue: UserSettingsModel.ReadOnlyText
|
roleValue: UserSettingsModel.ReadOnlyText
|
||||||
TextEdit {
|
TextEdit {
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
text: model.value
|
text: model.value
|
||||||
readOnly: true
|
readOnly: true
|
||||||
selectByMouse: !Settings.mobileMode
|
selectByMouse: !Settings.mobileMode
|
||||||
|
@ -176,7 +175,7 @@ Rectangle {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
height: 1
|
height: 1
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,7 +28,7 @@ ColumnLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: qsTr("Welcome to nheko! The desktop client for the Matrix protocol.")
|
text: qsTr("Welcome to nheko! The desktop client for the Matrix protocol.")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
font.pointSize: fontMetrics.font.pointSize*2
|
font.pointSize: fontMetrics.font.pointSize*2
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
|
@ -38,7 +38,7 @@ ColumnLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: qsTr("Enjoy your stay!")
|
text: qsTr("Enjoy your stay!")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
font.pointSize: fontMetrics.font.pointSize*1.5
|
font.pointSize: fontMetrics.font.pointSize*1.5
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
|
@ -86,7 +86,7 @@ ColumnLayout {
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
Layout.margins: Nheko.paddingLarge
|
Layout.margins: Nheko.paddingLarge
|
||||||
text: qsTr("Reduce animations")
|
text: qsTr("Reduce animations")
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
|
|
||||||
HoverHandler {
|
HoverHandler {
|
||||||
id: hovered
|
id: hovered
|
||||||
|
|
|
@ -9,7 +9,7 @@ import im.nheko 1.0
|
||||||
Slider {
|
Slider {
|
||||||
id: control
|
id: control
|
||||||
|
|
||||||
property color progressColor: Nheko.colors.highlight
|
property color progressColor: palette.highlight
|
||||||
property bool alwaysShowSlider: true
|
property bool alwaysShowSlider: true
|
||||||
property int sliderRadius: 16
|
property int sliderRadius: 16
|
||||||
|
|
||||||
|
@ -25,7 +25,7 @@ Slider {
|
||||||
width: control.availableWidth - handle.width
|
width: control.availableWidth - handle.width
|
||||||
height: implicitHeight
|
height: implicitHeight
|
||||||
radius: height / 2
|
radius: height / 2
|
||||||
color: Nheko.colors.buttonText
|
color: palette.buttonText
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width: control.visualPosition * parent.width
|
width: control.visualPosition * parent.width
|
||||||
|
|
|
@ -20,7 +20,7 @@ Item {
|
||||||
PointHandler {
|
PointHandler {
|
||||||
id: ph
|
id: ph
|
||||||
|
|
||||||
onGrabChanged: {
|
onGrabChanged: (_, point) => {
|
||||||
circle.centerX = point.position.x
|
circle.centerX = point.position.x
|
||||||
circle.centerY = point.position.y
|
circle.centerY = point.position.y
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,7 +45,7 @@ Popup {
|
||||||
padding: Nheko.paddingLarge
|
padding: Nheko.paddingLarge
|
||||||
|
|
||||||
contentItem: Label {
|
contentItem: Label {
|
||||||
color: Nheko.colors.light
|
color: palette.light
|
||||||
width: Math.max(Overlay.overlay? Overlay.overlay.width/2 : 0, 400)
|
width: Math.max(Overlay.overlay? Overlay.overlay.width/2 : 0, 400)
|
||||||
text: snackbar.currentMessage
|
text: snackbar.currentMessage
|
||||||
font.bold: true
|
font.bold: true
|
||||||
|
@ -53,7 +53,7 @@ Popup {
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
radius: Nheko.paddingLarge
|
radius: Nheko.paddingLarge
|
||||||
color: Nheko.colors.dark
|
color: palette.dark
|
||||||
opacity: 0.8
|
opacity: 0.8
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -50,7 +50,7 @@ Rectangle {
|
||||||
}
|
}
|
||||||
|
|
||||||
color: {
|
color: {
|
||||||
var wc = Nheko.colors.alternateBase;
|
var wc = palette.alternateBase;
|
||||||
return Qt.rgba(wc.r, wc.g, wc.b, 0.5);
|
return Qt.rgba(wc.r, wc.g, wc.b, 0.5);
|
||||||
}
|
}
|
||||||
opacity: control.shouldShowControls ? 1 : 0
|
opacity: control.shouldShowControls ? 1 : 0
|
||||||
|
@ -95,7 +95,7 @@ Rectangle {
|
||||||
id: playbackStateImage
|
id: playbackStateImage
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
buttonTextColor: Nheko.colors.text
|
buttonTextColor: palette.text
|
||||||
Layout.preferredHeight: 24
|
Layout.preferredHeight: 24
|
||||||
Layout.preferredWidth: 24
|
Layout.preferredWidth: 24
|
||||||
image: {
|
image: {
|
||||||
|
@ -115,7 +115,7 @@ Rectangle {
|
||||||
id: volumeButton
|
id: volumeButton
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
buttonTextColor: Nheko.colors.text
|
buttonTextColor: palette.text
|
||||||
Layout.preferredHeight: 24
|
Layout.preferredHeight: 24
|
||||||
Layout.preferredWidth: 24
|
Layout.preferredWidth: 24
|
||||||
image: {
|
image: {
|
||||||
|
@ -214,7 +214,7 @@ Rectangle {
|
||||||
Label {
|
Label {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignRight
|
||||||
text: (!control.mediaLoaded ? "-- " : durationToString(control.positionValue)) + " / " + durationToString(control.duration)
|
text: (!control.mediaLoaded ? "-- " : durationToString(control.positionValue)) + " / " + durationToString(control.duration)
|
||||||
color: Nheko.colors.text
|
color: palette.text
|
||||||
}
|
}
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
|
|
@ -9,7 +9,6 @@ import im.nheko 1.0
|
||||||
|
|
||||||
Popup {
|
Popup {
|
||||||
modal: true
|
modal: true
|
||||||
palette: Nheko.colors
|
|
||||||
// only set the anchors on Qt 5.12 or higher
|
// only set the anchors on Qt 5.12 or higher
|
||||||
// see https://doc.qt.io/qt-5/qml-qtquick-controls2-popup.html#anchors.centerIn-prop
|
// see https://doc.qt.io/qt-5/qml-qtquick-controls2-popup.html#anchors.centerIn-prop
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
|
@ -31,7 +30,7 @@ Popup {
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: 22
|
Layout.preferredWidth: 22
|
||||||
Layout.preferredHeight: 22
|
Layout.preferredHeight: 22
|
||||||
source: "image://colorimage/:/icons/icons/ui/microphone-unmute.svg?" + Nheko.colors.windowText
|
source: "image://colorimage/:/icons/icons/ui/microphone-unmute.svg?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -49,7 +48,7 @@ Popup {
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: 22
|
Layout.preferredWidth: 22
|
||||||
Layout.preferredHeight: 22
|
Layout.preferredHeight: 22
|
||||||
source: "image://colorimage/:/icons/icons/ui/video-call.svg?" + Nheko.colors.windowText
|
source: "image://colorimage/:/icons/icons/ui/video-call.svg?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -81,8 +80,8 @@ Popup {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.colors.windowText
|
border.color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,7 +14,6 @@ Popup {
|
||||||
closePolicy: Popup.NoAutoClose
|
closePolicy: Popup.NoAutoClose
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: parent.height
|
height: parent.height
|
||||||
palette: Nheko.colors
|
|
||||||
|
|
||||||
Component {
|
Component {
|
||||||
id: deviceError
|
id: deviceError
|
||||||
|
@ -45,7 +44,7 @@ Popup {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: CallManager.callPartyDisplayName
|
text: CallManager.callPartyDisplayName
|
||||||
font.pointSize: fontMetrics.font.pointSize * 2
|
font.pointSize: fontMetrics.font.pointSize * 2
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -68,14 +67,14 @@ Popup {
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
Layout.preferredWidth: callInv.height / 10
|
Layout.preferredWidth: callInv.height / 10
|
||||||
Layout.preferredHeight: callInv.height / 10
|
Layout.preferredHeight: callInv.height / 10
|
||||||
source: "image://colorimage/" + image + "?" + Nheko.colors.windowText
|
source: "image://colorimage/" + image + "?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
text: CallManager.callType == CallType.VIDEO ? qsTr("Video Call") : qsTr("Voice Call")
|
text: CallManager.callType == CallType.VIDEO ? qsTr("Video Call") : qsTr("Voice Call")
|
||||||
font.pointSize: fontMetrics.font.pointSize * 2
|
font.pointSize: fontMetrics.font.pointSize * 2
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -94,7 +93,7 @@ Popup {
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: deviceCombos.imageSize
|
Layout.preferredWidth: deviceCombos.imageSize
|
||||||
Layout.preferredHeight: deviceCombos.imageSize
|
Layout.preferredHeight: deviceCombos.imageSize
|
||||||
source: "image://colorimage/:/icons/icons/ui/microphone-unmute.svg?" + Nheko.colors.windowText
|
source: "image://colorimage/:/icons/icons/ui/microphone-unmute.svg?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -113,7 +112,7 @@ Popup {
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: deviceCombos.imageSize
|
Layout.preferredWidth: deviceCombos.imageSize
|
||||||
Layout.preferredHeight: deviceCombos.imageSize
|
Layout.preferredHeight: deviceCombos.imageSize
|
||||||
source: "image://colorimage/:/icons/icons/ui/video.svg?" + Nheko.colors.windowText
|
source: "image://colorimage/:/icons/icons/ui/video.svg?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -201,8 +200,8 @@ Popup {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.colors.windowText
|
border.color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -90,7 +90,6 @@ Rectangle {
|
||||||
Layout.rightMargin: 4
|
Layout.rightMargin: 4
|
||||||
icon.source: CallManager.callType == CallType.VIDEO ? "qrc:/icons/icons/ui/video.svg" : "qrc:/icons/icons/ui/place-call.svg"
|
icon.source: CallManager.callType == CallType.VIDEO ? "qrc:/icons/icons/ui/video.svg" : "qrc:/icons/icons/ui/place-call.svg"
|
||||||
text: qsTr("Accept")
|
text: qsTr("Accept")
|
||||||
palette: Nheko.colors
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
if (CallManager.mics.length == 0) {
|
if (CallManager.mics.length == 0) {
|
||||||
var dialog = deviceError.createObject(timelineRoot, {
|
var dialog = deviceError.createObject(timelineRoot, {
|
||||||
|
@ -126,7 +125,6 @@ Rectangle {
|
||||||
Layout.rightMargin: 16
|
Layout.rightMargin: 16
|
||||||
icon.source: "qrc:/icons/icons/ui/end-call.svg"
|
icon.source: "qrc:/icons/icons/ui/end-call.svg"
|
||||||
text: qsTr("Decline")
|
text: qsTr("Decline")
|
||||||
palette: Nheko.colors
|
|
||||||
onClicked: {
|
onClicked: {
|
||||||
CallManager.rejectInvite();
|
CallManager.rejectInvite();
|
||||||
}
|
}
|
||||||
|
|
|
@ -24,19 +24,19 @@ Popup {
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: 16
|
Layout.preferredWidth: 16
|
||||||
Layout.preferredHeight: 16
|
Layout.preferredHeight: 16
|
||||||
source: "image://colorimage/" + image + "?" + Nheko.colors.windowText
|
source: "image://colorimage/" + image + "?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: errorString
|
text: errorString
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.colors.windowText
|
border.color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,7 +17,6 @@ Popup {
|
||||||
anchors.centerIn = parent;
|
anchors.centerIn = parent;
|
||||||
|
|
||||||
}
|
}
|
||||||
palette: Nheko.colors
|
|
||||||
|
|
||||||
Component {
|
Component {
|
||||||
id: deviceError
|
id: deviceError
|
||||||
|
@ -38,7 +37,7 @@ Popup {
|
||||||
|
|
||||||
Label {
|
Label {
|
||||||
text: qsTr("Place a call to %1?").arg(room.roomName)
|
text: qsTr("Place a call to %1?").arg(room.roomName)
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
@ -138,7 +137,7 @@ Popup {
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: 22
|
Layout.preferredWidth: 22
|
||||||
Layout.preferredHeight: 22
|
Layout.preferredHeight: 22
|
||||||
source: "image://colorimage/:/icons/icons/ui/microphone-unmute.svg?" + Nheko.colors.windowText
|
source: "image://colorimage/:/icons/icons/ui/microphone-unmute.svg?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -159,7 +158,7 @@ Popup {
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: 22
|
Layout.preferredWidth: 22
|
||||||
Layout.preferredHeight: 22
|
Layout.preferredHeight: 22
|
||||||
source: "image://colorimage/:/icons/icons/ui/video.svg?" + Nheko.colors.windowText
|
source: "image://colorimage/:/icons/icons/ui/video.svg?" + palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -176,8 +175,8 @@ Popup {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.colors.windowText
|
border.color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,7 +19,6 @@ Popup {
|
||||||
Component.onDestruction: {
|
Component.onDestruction: {
|
||||||
CallManager.closeScreenShare();
|
CallManager.closeScreenShare();
|
||||||
}
|
}
|
||||||
palette: Nheko.colors
|
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Label {
|
Label {
|
||||||
|
@ -29,7 +28,7 @@ Popup {
|
||||||
Layout.rightMargin: 8
|
Layout.rightMargin: 8
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Share desktop with %1?").arg(room.roomName)
|
text: qsTr("Share desktop with %1?").arg(room.roomName)
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
|
@ -40,7 +39,7 @@ Popup {
|
||||||
Label {
|
Label {
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Method:")
|
text: qsTr("Method:")
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -60,7 +59,7 @@ Popup {
|
||||||
Label {
|
Label {
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Window:")
|
text: qsTr("Window:")
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -91,7 +90,7 @@ Popup {
|
||||||
Label {
|
Label {
|
||||||
Layout.alignment: Qt.AlignLeft
|
Layout.alignment: Qt.AlignLeft
|
||||||
text: qsTr("Frame rate:")
|
text: qsTr("Frame rate:")
|
||||||
color: Nheko.colors.windowText
|
color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
|
@ -191,8 +190,8 @@ Popup {
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: Nheko.colors.window
|
color: palette.window
|
||||||
border.color: Nheko.colors.windowText
|
border.color: palette.windowText
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -1033,12 +1033,12 @@ MediaUpload::MediaUpload(std::unique_ptr<QIODevice> source_,
|
||||||
}
|
}
|
||||||
|
|
||||||
connect(mediaPlayer,
|
connect(mediaPlayer,
|
||||||
&QMediaPlayer::error,
|
&QMediaPlayer::errorOccurred,
|
||||||
this,
|
this,
|
||||||
[mediaPlayer]() {
|
[](QMediaPlayer::Error error, QString errorString) {
|
||||||
nhlog::ui()->debug("Media player error {} and errorStr {}",
|
nhlog::ui()->debug("Media player error {} and errorStr {}",
|
||||||
mediaPlayer->error(),
|
error,
|
||||||
mediaPlayer->errorString().toStdString());
|
errorString.toStdString());
|
||||||
});
|
});
|
||||||
connect(mediaPlayer,
|
connect(mediaPlayer,
|
||||||
&QMediaPlayer::mediaStatusChanged,
|
&QMediaPlayer::mediaStatusChanged,
|
||||||
|
|
|
@ -25,13 +25,14 @@ MxcMediaProxy::MxcMediaProxy(QObject *parent)
|
||||||
{
|
{
|
||||||
connect(this, &MxcMediaProxy::eventIdChanged, &MxcMediaProxy::startDownload);
|
connect(this, &MxcMediaProxy::eventIdChanged, &MxcMediaProxy::startDownload);
|
||||||
connect(this, &MxcMediaProxy::roomChanged, &MxcMediaProxy::startDownload);
|
connect(this, &MxcMediaProxy::roomChanged, &MxcMediaProxy::startDownload);
|
||||||
connect(this,
|
connect(this,
|
||||||
&MxcMediaProxy::error,
|
&QMediaPlayer::errorOccurred,
|
||||||
[this]() {
|
this,
|
||||||
nhlog::ui()->info("Media player error {} and errorStr {}",
|
[](QMediaPlayer::Error error, QString errorString) {
|
||||||
error(),
|
nhlog::ui()->debug("Media player error {} and errorStr {}",
|
||||||
this->errorString().toStdString());
|
error,
|
||||||
});
|
errorString.toStdString());
|
||||||
|
});
|
||||||
connect(this, &MxcMediaProxy::mediaStatusChanged, [this](QMediaPlayer::MediaStatus status) {
|
connect(this, &MxcMediaProxy::mediaStatusChanged, [this](QMediaPlayer::MediaStatus status) {
|
||||||
nhlog::ui()->info("Media player status {} and error {}", status, this->error());
|
nhlog::ui()->info("Media player status {} and error {}", status, this->error());
|
||||||
});
|
});
|
||||||
|
|
|
@ -173,11 +173,11 @@ CallManager::CallManager(QObject *parent)
|
||||||
});
|
});
|
||||||
|
|
||||||
connect(&player_,
|
connect(&player_,
|
||||||
&QMediaPlayer::error,
|
&QMediaPlayer::errorOccurred,
|
||||||
this,
|
this,
|
||||||
[this]() {
|
[this](QMediaPlayer::Error error, QString errorString) {
|
||||||
stopRingtone();
|
stopRingtone();
|
||||||
switch (player_.error()) {
|
switch (error) {
|
||||||
case QMediaPlayer::FormatError:
|
case QMediaPlayer::FormatError:
|
||||||
case QMediaPlayer::ResourceError:
|
case QMediaPlayer::ResourceError:
|
||||||
nhlog::ui()->error("WebRTC: valid ringtone file not found");
|
nhlog::ui()->error("WebRTC: valid ringtone file not found");
|
||||||
|
@ -186,7 +186,7 @@ CallManager::CallManager(QObject *parent)
|
||||||
nhlog::ui()->error("WebRTC: access to ringtone file denied");
|
nhlog::ui()->error("WebRTC: access to ringtone file denied");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
nhlog::ui()->error("WebRTC: unable to play ringtone");
|
nhlog::ui()->error("WebRTC: unable to play ringtone, {}", errorString.toStdString());
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue