summaryrefslogtreecommitdiffstats
path: root/resources
diff options
context:
space:
mode:
authorNicolas Werner <nicolas.werner@hotmail.de>2023-06-02 01:29:05 +0200
committerNicolas Werner <nicolas.werner@hotmail.de>2023-06-08 22:32:07 +0200
commit54e2295c214874a316d22eaedaf5c2db17b59df0 (patch)
tree2c88e09be38e2758dfcd3fe6732da484f99d94c5 /resources
parente85a1d4aeb464f155cf026d33cab120f07724e70 (diff)
Fix palette access and QMediaPlayer errors
Diffstat (limited to 'resources')
-rw-r--r--resources/qml/Avatar.qml6
-rw-r--r--resources/qml/ChatPage.qml2
-rw-r--r--resources/qml/CommunitiesList.qml30
-rw-r--r--resources/qml/Completer.qml30
-rw-r--r--resources/qml/ElidedLabel.qml2
-rw-r--r--resources/qml/EncryptionIndicator.qml2
-rw-r--r--resources/qml/ForwardCompleter.qml11
-rw-r--r--resources/qml/ImageButton.qml4
-rw-r--r--resources/qml/MatrixText.qml2
-rw-r--r--resources/qml/MatrixTextField.qml10
-rw-r--r--resources/qml/MessageInput.qml15
-rw-r--r--resources/qml/MessageInputWarning.qml3
-rw-r--r--resources/qml/MessageView.qml30
-rw-r--r--resources/qml/QuickSwitcher.qml3
-rw-r--r--resources/qml/Reactions.qml14
-rw-r--r--resources/qml/ReplyPopup.qml8
-rw-r--r--resources/qml/RoomList.qml49
-rw-r--r--resources/qml/Root.qml1
-rw-r--r--resources/qml/SelfVerificationCheck.qml22
-rw-r--r--resources/qml/TimelineRow.qml22
-rw-r--r--resources/qml/TimelineView.qml14
-rw-r--r--resources/qml/ToggleButton.qml4
-rw-r--r--resources/qml/TopBar.qml18
-rw-r--r--resources/qml/TypingIndicator.qml6
-rw-r--r--resources/qml/UploadBox.qml6
-rw-r--r--resources/qml/components/AvatarListTile.qml30
-rw-r--r--resources/qml/components/FlatButton.qml4
-rw-r--r--resources/qml/components/MainWindowDialog.qml2
-rw-r--r--resources/qml/components/NhekoTabButton.qml6
-rw-r--r--resources/qml/components/ReorderableListview.qml4
-rw-r--r--resources/qml/components/TextButton.qml4
-rw-r--r--resources/qml/components/UserListRow.qml4
-rw-r--r--resources/qml/delegates/Encrypted.qml5
-rw-r--r--resources/qml/delegates/EncryptionEnabled.qml6
-rw-r--r--resources/qml/delegates/FileMessage.qml8
-rw-r--r--resources/qml/delegates/ImageMessage.qml12
-rw-r--r--resources/qml/delegates/MessageDelegate.qml8
-rw-r--r--resources/qml/delegates/NoticeMessage.qml2
-rw-r--r--resources/qml/delegates/Pill.qml4
-rw-r--r--resources/qml/delegates/Placeholder.qml2
-rw-r--r--resources/qml/delegates/PlayableMediaMessage.qml8
-rw-r--r--resources/qml/delegates/Redacted.qml6
-rw-r--r--resources/qml/delegates/Reply.qml6
-rw-r--r--resources/qml/delegates/TextMessage.qml14
-rw-r--r--resources/qml/device-verification/DeviceVerification.qml5
-rw-r--r--resources/qml/device-verification/DigitVerification.qml8
-rw-r--r--resources/qml/device-verification/EmojiVerification.qml8
-rw-r--r--resources/qml/device-verification/Failed.qml2
-rw-r--r--resources/qml/device-verification/NewVerificationRequest.qml2
-rw-r--r--resources/qml/device-verification/Success.qml2
-rw-r--r--resources/qml/device-verification/Waiting.qml4
-rw-r--r--resources/qml/dialogs/AliasEditor.qml16
-rw-r--r--resources/qml/dialogs/AllowedRoomsSettingsDialog.qml11
-rw-r--r--resources/qml/dialogs/ConfirmJoinRoomDialog.qml13
-rw-r--r--resources/qml/dialogs/CreateDirect.qml6
-rw-r--r--resources/qml/dialogs/CreateRoom.qml10
-rw-r--r--resources/qml/dialogs/ImagePackEditorDialog.qml18
-rw-r--r--resources/qml/dialogs/ImagePackSettingsDialog.qml19
-rw-r--r--resources/qml/dialogs/InputDialog.qml2
-rw-r--r--resources/qml/dialogs/InviteDialog.qml19
-rw-r--r--resources/qml/dialogs/JoinRoomDialog.qml5
-rw-r--r--resources/qml/dialogs/PhoneNumberInputDialog.qml2
-rw-r--r--resources/qml/dialogs/PowerLevelEditor.qml29
-rw-r--r--resources/qml/dialogs/PowerLevelSpacesApplyDialog.qml13
-rw-r--r--resources/qml/dialogs/RawMessageDialog.qml8
-rw-r--r--resources/qml/dialogs/ReadReceipts.qml12
-rw-r--r--resources/qml/dialogs/RoomDirectory.qml15
-rw-r--r--resources/qml/dialogs/RoomMembers.qml12
-rw-r--r--resources/qml/dialogs/RoomSettings.qml45
-rw-r--r--resources/qml/dialogs/UserProfile.qml18
-rw-r--r--resources/qml/emoji/StickerPicker.qml19
-rw-r--r--resources/qml/pages/LoginPage.qml5
-rw-r--r--resources/qml/pages/RegisterPage.qml7
-rw-r--r--resources/qml/pages/UserSettingsPage.qml9
-rw-r--r--resources/qml/pages/WelcomePage.qml6
-rw-r--r--resources/qml/ui/NhekoSlider.qml4
-rw-r--r--resources/qml/ui/Ripple.qml2
-rw-r--r--resources/qml/ui/Snackbar.qml4
-rw-r--r--resources/qml/ui/media/MediaControls.qml8
-rw-r--r--resources/qml/voip/CallDevices.qml9
-rw-r--r--resources/qml/voip/CallInvite.qml15
-rw-r--r--resources/qml/voip/CallInviteBar.qml2
-rw-r--r--resources/qml/voip/DeviceError.qml8
-rw-r--r--resources/qml/voip/PlaceCall.qml11
-rw-r--r--resources/qml/voip/ScreenShare.qml13
85 files changed, 410 insertions, 465 deletions
diff --git a/resources/qml/Avatar.qml b/resources/qml/Avatar.qml
index 4951a9fb..8302f8fa 100644
--- a/resources/qml/Avatar.qml
+++ b/resources/qml/Avatar.qml
@@ -24,7 +24,7 @@ AbstractButton {
background: Rectangle {
id: bg
radius: Settings.avatarCircles ? height / 2 : height / 8
- color: Nheko.colors.alternateBase
+ color: palette.alternateBase
}
Label {
@@ -39,7 +39,7 @@ AbstractButton {
verticalAlignment: Text.AlignVCenter
horizontalAlignment: Text.AlignHCenter
visible: img.status != Image.Ready && !Settings.useIdenticon
- color: Nheko.colors.text
+ color: palette.text
}
Image {
@@ -109,7 +109,7 @@ AbstractButton {
}
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)
}
}
diff --git a/resources/qml/ChatPage.qml b/resources/qml/ChatPage.qml
index d4d2b845..564c093d 100644
--- a/resources/qml/ChatPage.qml
+++ b/resources/qml/ChatPage.qml
@@ -14,7 +14,7 @@ import QtQml 2.15
Rectangle {
id: chatPage
- color: Nheko.colors.window
+ color: palette.window
ColumnLayout {
spacing: 0
diff --git a/resources/qml/CommunitiesList.qml b/resources/qml/CommunitiesList.qml
index ee49ae2d..5bf239a6 100644
--- a/resources/qml/CommunitiesList.qml
+++ b/resources/qml/CommunitiesList.qml
@@ -78,11 +78,11 @@ Page {
delegate: ItemDelegate {
id: communityItem
- property color backgroundColor: Nheko.colors.window
- property color importantText: Nheko.colors.text
- property color unimportantText: Nheko.colors.buttonText
- property color bubbleBackground: Nheko.colors.highlight
- property color bubbleText: Nheko.colors.highlightedText
+ property color backgroundColor: palette.window
+ property color importantText: palette.text
+ property color unimportantText: palette.buttonText
+ property color bubbleBackground: palette.highlight
+ property color bubbleText: palette.highlightedText
required property var model
height: avatarSize + 2 * Nheko.paddingMedium
@@ -100,11 +100,11 @@ Page {
PropertyChanges {
target: communityItem
- backgroundColor: Nheko.colors.dark
- importantText: Nheko.colors.brightText
- unimportantText: Nheko.colors.brightText
- bubbleBackground: Nheko.colors.highlight
- bubbleText: Nheko.colors.highlightedText
+ backgroundColor: palette.dark
+ importantText: palette.brightText
+ unimportantText: palette.brightText
+ bubbleBackground: palette.highlight
+ bubbleText: palette.highlightedText
}
},
@@ -114,11 +114,11 @@ Page {
PropertyChanges {
target: communityItem
- backgroundColor: Nheko.colors.highlight
- importantText: Nheko.colors.highlightedText
- unimportantText: Nheko.colors.highlightedText
- bubbleBackground: Nheko.colors.highlightedText
- bubbleText: Nheko.colors.highlight
+ backgroundColor: palette.highlight
+ importantText: palette.highlightedText
+ unimportantText: palette.highlightedText
+ bubbleBackground: palette.highlightedText
+ bubbleText: palette.highlight
}
}
diff --git a/resources/qml/Completer.qml b/resources/qml/Completer.qml
index 0a9c41ed..95bebc1b 100644
--- a/resources/qml/Completer.qml
+++ b/resources/qml/Completer.qml
@@ -127,8 +127,8 @@ Control {
ListView.delayRemove: true
- color: model.index == popup.currentIndex ? Nheko.colors.highlight : Nheko.colors.base
- height: chooser.child.implicitHeight + 2 * popup.rowMargin
+ color: model.index == popup.currentIndex ? palette.highlight : palette.base
+ height: (chooser.child?.implicitHeight ?? 0) + 2 * popup.rowMargin
implicitWidth: fullWidth ? ListView.view.width : chooser.child.implicitWidth + 4
MouseArea {
@@ -146,7 +146,7 @@ Control {
}
}
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 {
@@ -177,12 +177,12 @@ Control {
Label {
text: model.displayName
- color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
+ color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
}
Label {
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 {
visible: !!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
}
@@ -220,12 +220,12 @@ Control {
Layout.leftMargin: Nheko.paddingSmall
Layout.rightMargin: Nheko.paddingSmall
text: model.shortcode
- color: model.index == popup.currentIndex ? Nheko.colors.highlightedText : Nheko.colors.text
+ color: model.index == popup.currentIndex ? palette.highlightedText : palette.text
}
Label {
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 {
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
}
Label {
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 {
text: model.roomName
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
textFormat: Text.RichText
}
@@ -306,14 +306,14 @@ Control {
Label {
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
textFormat: Text.RichText
}
Label {
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
}
@@ -329,8 +329,8 @@ Control {
background: Rectangle {
- color: Nheko.colors.base
- border.color: Nheko.colors.mid
+ color: palette.base
+ border.color: palette.mid
}
}
diff --git a/resources/qml/ElidedLabel.qml b/resources/qml/ElidedLabel.qml
index 180259b1..2d53faff 100644
--- a/resources/qml/ElidedLabel.qml
+++ b/resources/qml/ElidedLabel.qml
@@ -13,7 +13,7 @@ Label {
property alias elideWidth: metrics.elideWidth
property int fullTextWidth: Math.ceil(metrics.advanceWidth)
- color: Nheko.colors.text
+ color: palette.text
text: (textFormat == Text.PlainText) ? metrics.elidedText : TimelineManager.escapeEmoji(metrics.elidedText)
maximumLineCount: 1
elide: Text.ElideRight
diff --git a/resources/qml/EncryptionIndicator.qml b/resources/qml/EncryptionIndicator.qml
index 5338b6be..c675fb52 100644
--- a/resources/qml/EncryptionIndicator.qml
+++ b/resources/qml/EncryptionIndicator.qml
@@ -43,7 +43,7 @@ Image {
case Crypto.Verified:
return sourceUrl + Nheko.theme.green;
case Crypto.TOFU:
- return sourceUrl + Nheko.colors.buttonText;
+ return sourceUrl + palette.buttonText;
default:
return sourceUrl + Nheko.theme.error;
}
diff --git a/resources/qml/ForwardCompleter.qml b/resources/qml/ForwardCompleter.qml
index 4ab23a4f..a5787189 100644
--- a/resources/qml/ForwardCompleter.qml
+++ b/resources/qml/ForwardCompleter.qml
@@ -19,7 +19,6 @@ Popup {
x: Math.round(parent.width / 2 - width / 2)
y: Math.round(parent.height / 4)
modal: true
- palette: Nheko.colors
parent: Overlay.overlay
width: timelineRoot.width * 0.8
leftPadding: 10
@@ -39,7 +38,7 @@ Popup {
text: qsTr("Forward Message")
font.bold: true
bottomPadding: 10
- color: Nheko.colors.text
+ color: palette.text
}
Reply {
@@ -50,7 +49,7 @@ Popup {
width: parent.width
- userColor: TimelineManager.userColor(modelData.userId, Nheko.colors.window)
+ userColor: TimelineManager.userColor(modelData.userId, palette.window)
blurhash: modelData.blurhash ?? ""
body: modelData.body ?? ""
formattedBody: modelData.formattedBody ?? ""
@@ -72,7 +71,7 @@ Popup {
id: roomTextInput
width: forwardMessagePopup.width - forwardMessagePopup.leftPadding * 2
- color: Nheko.colors.text
+ color: palette.text
onTextEdited: {
completerPopup.completer.searchString = text;
}
@@ -123,11 +122,11 @@ Popup {
}
background: Rectangle {
- color: Nheko.colors.window
+ color: palette.window
}
Overlay.modal: Rectangle {
- color: Qt.rgba(Nheko.colors.window.r, Nheko.colors.windo