compatible right section

This commit is contained in:
王劲鹏 2021-06-25 19:35:23 +08:00 committed by osborn
parent 6d100847e4
commit f191910cb6

View File

@ -32,7 +32,6 @@ ApplicationWindow {
Rectangle { Rectangle {
anchors.centerIn: parent anchors.centerIn: parent
objectName: "center" objectName: "center"
color: "red"
width: childrenRect.width width: childrenRect.width
height: childrenRect.height height: childrenRect.height
} }
@ -65,15 +64,17 @@ ApplicationWindow {
} }
RowLayout { RowLayout {
anchors.right: parent.right id: rightSection
height: navbar.height
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
RowLayout { RowLayout {
objectName: "right" objectName: "right"
} width: childrenRect.width
Rectangle { onChildrenRectChanged: {
Layout.preferredWidth: 10 rightSection.x = navbar.width - this.childrenRect.width - 10
}
} }
} }
} }