qml: reorganise toolbarTopLayout, so that top-left click opens menu
previously clicking too far left would not open the wallet-menu: - click on label would open it, but - click on wallet-icon or padding to its left would not
This commit is contained in:
@@ -111,6 +111,20 @@ ApplicationWindow
|
|||||||
Layout.rightMargin: constants.paddingMedium
|
Layout.rightMargin: constants.paddingMedium
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
|
|
||||||
|
Item {
|
||||||
|
Layout.fillWidth: true
|
||||||
|
Layout.preferredHeight: Math.max(implicitHeight, toolbarTopLayout.height)
|
||||||
|
|
||||||
|
MouseArea {
|
||||||
|
anchors.fill: parent
|
||||||
|
onClicked: {
|
||||||
|
stack.getRoot().menu.open() // open wallet-menu
|
||||||
|
stack.getRoot().menu.y = toolbar.height
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
RowLayout {
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
Layout.preferredWidth: constants.paddingXLarge
|
Layout.preferredWidth: constants.paddingXLarge
|
||||||
Layout.preferredHeight: 1
|
Layout.preferredHeight: 1
|
||||||
@@ -133,11 +147,6 @@ ApplicationWindow
|
|||||||
verticalAlignment: Qt.AlignVCenter
|
verticalAlignment: Qt.AlignVCenter
|
||||||
font.pixelSize: constants.fontSizeMedium
|
font.pixelSize: constants.fontSizeMedium
|
||||||
font.bold: true
|
font.bold: true
|
||||||
MouseArea {
|
|
||||||
anchors.fill: parent
|
|
||||||
onClicked: {
|
|
||||||
stack.getRoot().menu.open()
|
|
||||||
stack.getRoot().menu.y = toolbar.height
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -148,7 +157,7 @@ ApplicationWindow
|
|||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
onClicked: openAppMenu()
|
onClicked: openAppMenu() // open global-app-menu
|
||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
|
|||||||
Reference in New Issue
Block a user