fix qml issue after rebasing
This commit is contained in:
parent
3b9be01cc5
commit
6e20f47ec8
187
main.qml
187
main.qml
|
@ -160,94 +160,111 @@ ApplicationWindow {
|
||||||
height: parent.height
|
height: parent.height
|
||||||
Layout.minimumWidth: 200
|
Layout.minimumWidth: 200
|
||||||
|
|
||||||
Text {
|
ColumnLayout {
|
||||||
id: element
|
anchors.rightMargin: 0
|
||||||
x: 772
|
anchors.fill: parent
|
||||||
text: qsTr("Chat")
|
|
||||||
anchors.top: parent.top
|
|
||||||
anchors.topMargin: 17
|
|
||||||
font.bold: true
|
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
|
||||||
font.pixelSize: 17
|
|
||||||
}
|
|
||||||
|
|
||||||
Rectangle {
|
Item {
|
||||||
id: searchBox
|
Layout.preferredHeight: 100
|
||||||
height: 36
|
Layout.fillHeight: false
|
||||||
color: "#EEF2F5"
|
Layout.fillWidth: true
|
||||||
anchors.top: parent.top
|
|
||||||
anchors.topMargin: 59
|
|
||||||
radius: 8
|
|
||||||
anchors.right: parent.right
|
|
||||||
anchors.rightMargin: 55
|
|
||||||
anchors.left: parent.left
|
|
||||||
anchors.leftMargin: 16
|
|
||||||
|
|
||||||
TextField {
|
Text {
|
||||||
id: searchText
|
id: element
|
||||||
placeholderText: qsTr("Search")
|
x: 772
|
||||||
anchors.left: parent.left
|
text: qsTr("Chat")
|
||||||
anchors.leftMargin: 32
|
anchors.top: parent.top
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.topMargin: 17
|
||||||
font.pixelSize: 12
|
font.bold: true
|
||||||
background: {
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
font.pixelSize: 17
|
||||||
|
}
|
||||||
|
|
||||||
|
Rectangle {
|
||||||
|
id: searchBox
|
||||||
|
height: 36
|
||||||
|
color: "#EEF2F5"
|
||||||
|
anchors.top: parent.top
|
||||||
|
anchors.topMargin: 59
|
||||||
|
radius: 8
|
||||||
|
anchors.right: parent.right
|
||||||
|
anchors.rightMargin: 55
|
||||||
|
anchors.left: parent.left
|
||||||
|
anchors.leftMargin: 16
|
||||||
|
|
||||||
|
TextField {
|
||||||
|
id: searchText
|
||||||
|
placeholderText: qsTr("Search")
|
||||||
|
anchors.left: parent.left
|
||||||
|
anchors.leftMargin: 32
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
font.pixelSize: 12
|
||||||
|
background: {
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Image {
|
||||||
|
id: image4
|
||||||
|
anchors.left: parent.left
|
||||||
|
anchors.leftMargin: 10
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
fillMode: Image.PreserveAspectFit
|
||||||
|
source: "img/search.svg"
|
||||||
|
}
|
||||||
|
|
||||||
|
MouseArea {
|
||||||
|
id: mouseArea
|
||||||
|
anchors.fill: parent
|
||||||
|
onClicked : {
|
||||||
|
searchText.forceActiveFocus(Qt.MouseFocusReason)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
Rectangle {
|
||||||
|
id: addChat
|
||||||
|
width: 36
|
||||||
|
height: 36
|
||||||
|
color: "#4360DF"
|
||||||
|
radius: 50
|
||||||
|
anchors.right: parent.right
|
||||||
|
anchors.rightMargin: 9
|
||||||
|
anchors.top: parent.top
|
||||||
|
anchors.topMargin: 59
|
||||||
|
|
||||||
|
Text {
|
||||||
|
id: element3
|
||||||
|
color: "#ffffff"
|
||||||
|
text: qsTr("+")
|
||||||
|
anchors.verticalCenterOffset: -1
|
||||||
|
anchors.horizontalCenterOffset: 1
|
||||||
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
|
lineHeight: 1
|
||||||
|
fontSizeMode: Text.FixedSize
|
||||||
|
font.bold: true
|
||||||
|
font.pixelSize: 28
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Image {
|
Item {
|
||||||
id: image4
|
Layout.fillHeight: true
|
||||||
anchors.left: parent.left
|
Layout.fillWidth: true
|
||||||
anchors.leftMargin: 10
|
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
|
||||||
fillMode: Image.PreserveAspectFit
|
|
||||||
source: "img/search.svg"
|
|
||||||
}
|
|
||||||
|
|
||||||
MouseArea {
|
Component {
|
||||||
id: mouseArea
|
id: chatViewDelegate
|
||||||
anchors.fill: parent
|
Label { text: "Name:" + name }
|
||||||
onClicked : {
|
}
|
||||||
searchText.forceActiveFocus(Qt.MouseFocusReason)
|
|
||||||
|
ListView {
|
||||||
|
id: listView
|
||||||
|
anchors.fill: parent
|
||||||
|
model: chatsModel
|
||||||
|
delegate: chatViewDelegate
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
|
||||||
id: addChat
|
|
||||||
width: 36
|
|
||||||
height: 36
|
|
||||||
color: "#4360DF"
|
|
||||||
radius: 50
|
|
||||||
anchors.right: parent.right
|
|
||||||
anchors.rightMargin: 9
|
|
||||||
anchors.top: parent.top
|
|
||||||
anchors.topMargin: 59
|
|
||||||
|
|
||||||
Text {
|
|
||||||
id: element3
|
|
||||||
color: "#ffffff"
|
|
||||||
text: qsTr("+")
|
|
||||||
anchors.verticalCenterOffset: -1
|
|
||||||
anchors.horizontalCenterOffset: 1
|
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
|
||||||
lineHeight: 1
|
|
||||||
fontSizeMode: Text.FixedSize
|
|
||||||
font.bold: true
|
|
||||||
font.pixelSize: 28
|
|
||||||
}
|
|
||||||
}
|
|
||||||
Component {
|
|
||||||
id: chatViewDelegate
|
|
||||||
Label { text: "Name:" + name }
|
|
||||||
}
|
|
||||||
|
|
||||||
ListView {
|
|
||||||
id: listView
|
|
||||||
anchors.fill: parent
|
|
||||||
model: chatsModel
|
|
||||||
delegate: chatViewDelegate
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
@ -282,14 +299,14 @@ ApplicationWindow {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
TextArea { id: accountResult; Layout.fillWidth: true; text: logic.accountResult; readOnly: true }
|
TextArea { id: accountResult; Layout.fillWidth: true; text: logic.accountResult; readOnly: true }
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue