Minor bug fix on desktop handling

This commit is contained in:
Dany LE 2021-10-24 19:44:21 +02:00
parent 99e0d02581
commit 27ac7c06fc
2 changed files with 12 additions and 1 deletions

Binary file not shown.

View File

@ -992,11 +992,22 @@ namespace OS {
// desktop[0].set "selected", -1
$(desktop).on("click", function (e) {
let el = $(e.target).closest("afx-app-window")[0];
let el:any = $(e.target).closest("afx-app-window")[0];
if(el)
{
return;
}
el = $(e.target).parent();
if (!(el.length > 0)) {
return;
}
el = el.parent();
if (!(el.length > 0)) {
return;
}
if (el[0] !== desktop) {
return;
}
desktop.unselect();
($("#sysdock")[0] as tag.AppDockTag).selectedApp = null;
});