timeout popup after mouse exits
This commit is contained in:
parent
49ec4d8502
commit
87e9941e0a
1 changed files with 54 additions and 34 deletions
|
|
@ -32,6 +32,25 @@ PopupWindow {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Timer {
|
||||||
|
id: timer
|
||||||
|
interval: 750
|
||||||
|
onTriggered: {
|
||||||
|
if (!root.visible) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
root.toggle();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
WrapperMouseArea {
|
||||||
|
hoverEnabled: true
|
||||||
|
onExited: {
|
||||||
|
timer.start();
|
||||||
|
}
|
||||||
|
onEntered: {
|
||||||
|
timer.stop();
|
||||||
|
}
|
||||||
WrapperRectangle {
|
WrapperRectangle {
|
||||||
id: background
|
id: background
|
||||||
|
|
||||||
|
|
@ -79,4 +98,5 @@ PopupWindow {
|
||||||
sourceComponent: root.content
|
sourceComponent: root.content
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue