Remove quotes from id: properties

As suggested in the Qt Quick coding style
This commit is contained in:
miruka 2019-04-20 17:45:51 -04:00
parent 8f35e60801
commit c866ac87a9
16 changed files with 33 additions and 33 deletions

View File

@ -22,7 +22,7 @@ Controls1.SplitView {
console.log("replaced")
}
id: "pageStack"
id: pageStack
onCurrentItemChanged: currentItem.forceActiveFocus()

View File

@ -13,12 +13,12 @@ Item {
typeof(name) == "string" ? name :
(name.value ? name.value : "?")
id: "root"
id: root
width: dimmension
height: invisible ? 1 : dimmension
Rectangle {
id: "letterRectangle"
id: letterRectangle
anchors.fill: parent
visible: ! invisible && imageSource === null
color: resolvedName === "?" ?
@ -34,7 +34,7 @@ Item {
}
Image {
id: "avatarImage"
id: avatarImage
anchors.fill: parent
visible: ! invisible && imageSource !== null

View File

@ -6,7 +6,7 @@ ToolButton {
property string tooltip: ""
property string iconName: ""
id: "button"
id: button
display: ToolButton.IconOnly
icon.source: "../../icons/" + iconName + ".svg"
background: Rectangle { color: "transparent" }
@ -20,7 +20,7 @@ ToolButton {
visible: text ? toolTipZone.containsMouse : false
}
MouseArea {
id: "toolTipZone"
id: toolTipZone
anchors.fill: parent
hoverEnabled: true
acceptedButtons: Qt.NoButton // Make button receive clicks normally

View File

@ -2,11 +2,11 @@ import QtQuick 2.7
import QtQuick.Controls 2.0
HLabel {
id: "label"
id: label
textFormat: Text.RichText
MouseArea {
id: "mouseArea"
id: mouseArea
anchors.fill: parent
hoverEnabled: true

View File

@ -4,7 +4,7 @@ import QtQuick.Layouts 1.4
Avatar {
Image {
id: "status"
id: status
anchors.right: parent.right
anchors.bottom: parent.bottom
source: "../../icons/status.svg"

View File

@ -5,7 +5,7 @@ import "../base" as Base
import "utils.js" as ChatJS
Column {
id: "messageDelegate"
id: messageDelegate
function minsBetween(date1, date2) {
return Math.round((((date2 - date1) % 86400000) % 3600000) / 60000)

View File

@ -7,26 +7,26 @@ Rectangle {
property string displayName: ""
property string topic: ""
id: "root"
id: root
Layout.fillWidth: true
Layout.minimumHeight: 36
Layout.maximumHeight: Layout.minimumHeight
color: "#BBB"
RowLayout {
id: "row"
id: row
spacing: 12
anchors.fill: parent
Base.Avatar {
id: "avatar"
id: avatar
Layout.alignment: Qt.AlignTop
dimmension: root.Layout.minimumHeight
name: displayName
}
Base.HLabel {
id: "roomName"
id: roomName
text: displayName
font.pixelSize: bigSize
elide: Text.ElideRight
@ -37,7 +37,7 @@ Rectangle {
}
Base.HLabel {
id: "roomTopic"
id: roomTopic
text: topic
font.pixelSize: smallSize
elide: Text.ElideRight

View File

@ -9,17 +9,17 @@ ColumnLayout {
property var roomInfo:
Backend.models.rooms.get(userId).getWhere("roomId", roomId)
id: "chatPage"
id: chatPage
spacing: 0
onFocusChanged: sendBox.setFocus()
RoomHeader {
id: "roomHeader"
id: roomHeader
displayName: roomInfo.displayName
topic: roomInfo.topic
}
MessageList {}
TypingUsersBar {}
SendBox { id: "sendBox" }
SendBox { id: sendBox }
}

View File

@ -6,7 +6,7 @@ import "../base" as Base
Rectangle {
function setFocus() { textArea.forceActiveFocus() }
id: "root"
id: root
Layout.fillWidth: true
Layout.minimumHeight: 32
Layout.preferredHeight: textArea.implicitHeight
@ -19,7 +19,7 @@ Rectangle {
spacing: 0
Base.Avatar {
id: "avatar"
id: avatar
name: Backend.getUserDisplayName(chatPage.userId)
dimmension: root.Layout.minimumHeight
//visible: textArea.text === ""

View File

@ -14,7 +14,7 @@ Rectangle {
property var typingUsers: chatPage.roomInfo.typingUsers
Base.HLabel {
id: "usersLabel"
id: usersLabel
anchors.fill: parent
text: ChatJS.getTypingUsersText(typingUsers, chatPage.userId)

View File

@ -4,15 +4,15 @@ import QtQuick.Layouts 1.4
import "../base" as Base
ColumnLayout {
id: "accountDelegate"
id: accountDelegate
spacing: 0
width: parent.width
RowLayout {
id: "row"
id: row
spacing: 0
Base.Avatar { id: "avatar"; name: displayName; dimmension: 36 }
Base.Avatar { id: avatar; name: displayName; dimmension: 36 }
ColumnLayout {
Layout.fillWidth: true
@ -20,7 +20,7 @@ ColumnLayout {
spacing: 0
Base.HLabel {
id: "accountLabel"
id: accountLabel
text: displayName.value || userId
elide: Text.ElideRight
maximumLineCount: 1
@ -30,7 +30,7 @@ ColumnLayout {
}
TextField {
id: "statusEdit"
id: statusEdit
text: statusMessage || ""
placeholderText: qsTr("Set status message")
background: null
@ -51,7 +51,7 @@ ColumnLayout {
}
Base.HToolButton {
id: "toggleExpand"
id: toggleExpand
iconName: roomList.visible ? "up" : "down"
Layout.maximumWidth: 28
Layout.minimumHeight: row.height
@ -64,7 +64,7 @@ ColumnLayout {
}
RoomList {
id: "roomList"
id: roomList
visible: true
interactive: false // no scrolling
forUserId: userId

View File

@ -3,7 +3,7 @@ import QtQuick.Controls 2.2
import QtQuick.Layouts 1.4
ListView {
id: "accountList"
id: accountList
spacing: 8
model: Backend.models.accounts
delegate: AccountDelegate {}

View File

@ -4,7 +4,7 @@ import QtQuick.Layouts 1.4
import "../base" as Base
RowLayout {
id: "toolBar"
id: toolBar
Layout.fillWidth: true
Layout.maximumHeight: 32
spacing: 0

View File

@ -9,7 +9,7 @@ Base.HToolButton {
Layout.minimumWidth * (toolBar.children.length - 2)
}
id: "button"
id: button
visible: toolBarIsBig()
Layout.fillHeight: true
Layout.fillWidth: true

View File

@ -5,7 +5,7 @@ import "../base" as Base
import "utils.js" as SidePaneJS
MouseArea {
id: "root"
id: root
width: roomList.width
height: roomList.childrenHeight

View File

@ -14,7 +14,7 @@ ListView {
spacing * (model.count - 1)
}
id: "roomList"
id: roomList
spacing: 8
model: Backend.models.rooms.get(forUserId)
delegate: RoomDelegate {}