fix(ui): new chat menu popup hide on second click
Partially fixes #3558.
This commit is contained in:
parent
b94b932572
commit
1ee3bba598
|
@ -91,7 +91,11 @@ Item {
|
||||||
icon.name: "add"
|
icon.name: "add"
|
||||||
state: "default"
|
state: "default"
|
||||||
|
|
||||||
onClicked: chatContextMenu.popup(actionButton.width-chatContextMenu.width, actionButton.height + 4)
|
onClicked: {
|
||||||
|
chatContextMenu.opened ?
|
||||||
|
chatContextMenu.close() :
|
||||||
|
chatContextMenu.popup(actionButton.width-chatContextMenu.width, actionButton.height + 4)
|
||||||
|
}
|
||||||
states: [
|
states: [
|
||||||
State {
|
State {
|
||||||
name: "default"
|
name: "default"
|
||||||
|
@ -135,6 +139,7 @@ Item {
|
||||||
|
|
||||||
StatusPopupMenu {
|
StatusPopupMenu {
|
||||||
id: chatContextMenu
|
id: chatContextMenu
|
||||||
|
closePolicy: Popup.Popup.CloseOnReleaseOutsideParent | Popup.CloseOnEscape
|
||||||
|
|
||||||
onOpened: {
|
onOpened: {
|
||||||
actionButton.state = "pressed"
|
actionButton.state = "pressed"
|
||||||
|
|
Loading…
Reference in New Issue