Rename some chat components

This commit is contained in:
miruka 2019-12-10 14:57:54 -04:00
parent f65425957b
commit 3a3e0e9dbb
6 changed files with 20 additions and 20 deletions

View File

@ -27,8 +27,8 @@ HAvatar {
small: true
svgName: "user-power-" + (admin ? "100" : "50")
colorize: admin ?
theme.chat.roomSidePane.member.adminIcon :
theme.chat.roomSidePane.member.moderatorIcon
theme.chat.roomPane.member.adminIcon :
theme.chat.roomPane.member.moderatorIcon
HoverHandler { id: powerIconHover }

View File

@ -2,7 +2,7 @@ import QtQuick 2.12
import QtQuick.Layouts 1.12
import "../Base"
import "../utils.js" as Utils
import "RoomSidePane"
import "RoomPane"
Item {
id: chat
@ -23,7 +23,7 @@ Item {
) || "waiting"
readonly property alias loader: loader
readonly property alias roomSidePane: roomSidePane
readonly property alias roomPane: roomPane
onRoomInfoChanged: {
@ -42,9 +42,9 @@ Item {
HLoader {
id: loader
anchors.rightMargin: roomSidePane.visibleSize
anchors.rightMargin: roomPane.visibleSize
anchors.fill: parent
visible: ! roomSidePane.hidden || anchors.rightMargin < width
visible: ! roomPane.hidden || anchors.rightMargin < width
onLoaded: if (chat.focus) item.composer.takeFocus()
source: ready ? "ChatPage.qml" : ""
@ -61,8 +61,8 @@ Item {
}
}
RoomSidePane {
id: roomSidePane
RoomPane {
id: roomPane
referenceSizeParent: chat
}
}

View File

@ -4,24 +4,24 @@ import "../../utils.js" as Utils
HTileDelegate {
id: memberDelegate
backgroundColor: theme.chat.roomSidePane.member.background
backgroundColor: theme.chat.roomPane.member.background
image: HUserAvatar {
userId: model.user_id
displayName: model.display_name
mxc: model.avatar_url
powerLevel: model.power_level
shiftPowerIconPosition: ! roomSidePane.collapsed
shiftPowerIconPosition: ! roomPane.collapsed
}
title.text: model.display_name || model.user_id
title.color:
memberDelegate.hovered ?
Utils.nameColor(model.display_name || model.user_id.substring(1)) :
theme.chat.roomSidePane.member.name
theme.chat.roomPane.member.name
subtitle.text: model.user_id
subtitle.color: theme.chat.roomSidePane.member.subtitle
subtitle.color: theme.chat.roomPane.member.subtitle
Behavior on title.color { HColorAnimation {} }

View File

@ -48,7 +48,7 @@ HColumnLayout {
HTextField {
id: filterField
placeholderText: qsTr("Filter members")
backgroundColor: theme.chat.roomSidePane.filterMembers.background
backgroundColor: theme.chat.roomPane.filterMembers.background
bordered: false
opacity: width >= 16 ? 1 : 0
@ -66,7 +66,7 @@ HColumnLayout {
topPadding: 0
bottomPadding: 0
toolTip.text: qsTr("Invite to this room")
backgroundColor: theme.chat.roomSidePane.inviteButton.background
backgroundColor: theme.chat.roomPane.inviteButton.background
Layout.fillHeight: true
}

View File

@ -3,7 +3,7 @@ import QtQuick.Layouts 1.12
import "../../Base"
HDrawer {
id: roomSidePane
id: roomPane
objectName: "roomPane"
edge: Qt.RightEdge
defaultSize: buttonRepeater.childrenImplicitWidth
@ -12,14 +12,14 @@ HDrawer {
background: HColumnLayout{
Rectangle {
color: theme.chat.roomSidePaneButtons.background
color: theme.chat.roomPaneButtons.background
Layout.fillWidth: true
Layout.preferredHeight: theme.baseElementsHeight
}
Rectangle {
color: theme.chat.roomSidePane.background
color: theme.chat.roomPane.background
Layout.fillWidth: true
Layout.fillHeight: true
@ -52,7 +52,7 @@ HDrawer {
}
}
MembersView {
MemberView {
Layout.fillWidth: true
Layout.fillHeight: true
}

View File

@ -297,10 +297,10 @@ chat:
color name: colors.text
color topic: colors.dimText
roomSidePaneButtons:
roomPaneButtons:
color background: chat.roomHeader.background
roomSidePane:
roomPane:
color background: colors.mediumBackground
member: