mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-04-15 02:02:08 -04:00
dankbar: Fix widget context focus w/Autohide enabled
This commit is contained in:
@@ -855,12 +855,20 @@ Item {
|
||||
edge = barEdge ?? "top";
|
||||
isVisible = true;
|
||||
visible = true;
|
||||
|
||||
if (screen) {
|
||||
TrayMenuManager.registerMenu(screen.name, contextMenuWindow);
|
||||
}
|
||||
}
|
||||
|
||||
function close() {
|
||||
isVisible = false;
|
||||
visible = false;
|
||||
windowContextMenuLoader.active = false;
|
||||
|
||||
if (screen) {
|
||||
TrayMenuManager.unregisterMenu(screen.name);
|
||||
}
|
||||
}
|
||||
|
||||
implicitWidth: 100
|
||||
@@ -879,6 +887,19 @@ Item {
|
||||
bottom: true
|
||||
}
|
||||
|
||||
Component.onDestruction: {
|
||||
if (screen) {
|
||||
TrayMenuManager.unregisterMenu(screen.name);
|
||||
}
|
||||
}
|
||||
|
||||
Connections {
|
||||
target: PopoutManager
|
||||
function onPopoutOpening() {
|
||||
contextMenuWindow.close();
|
||||
}
|
||||
}
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
onClicked: contextMenuWindow.close()
|
||||
|
||||
Reference in New Issue
Block a user