Skip to content

Commit

Permalink
Fixed: Native context menu: Auto reset Menu.isOpen after 120ms
Browse files Browse the repository at this point in the history
  • Loading branch information
mbnuqw committed Jul 28, 2023
1 parent dca82c9 commit 5acc18e
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/services/menu.actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,8 @@ export function open(type: MenuType, x?: number, y?: number, customForced?: bool
}
}
}

resetNativeMenu(120)
return
}

Expand Down Expand Up @@ -383,6 +385,10 @@ export function close(): void {
Menu.isOpen = false
}

const resetNativeMenu = Utils.debounce(() => {
Menu.isOpen = false
})

/**
* Block ctx menu for 500ms
*/
Expand Down

0 comments on commit 5acc18e

Please sign in to comment.