mirror of
https://github.com/siyuan-note/siyuan.git
synced 2025-12-23 01:50:12 +01:00
This commit is contained in:
parent
b93945faf9
commit
2d0e35c120
2 changed files with 58 additions and 84 deletions
|
|
@ -5,6 +5,7 @@ import {isMobile} from "../util/functions";
|
|||
|
||||
export class Menu {
|
||||
public element: HTMLElement;
|
||||
public removeCB: () => void;
|
||||
private wheelEvent: string;
|
||||
|
||||
constructor() {
|
||||
|
|
@ -64,6 +65,10 @@ export class Menu {
|
|||
}
|
||||
|
||||
public remove() {
|
||||
if (window.siyuan.menus.menu.removeCB) {
|
||||
window.siyuan.menus.menu.removeCB();
|
||||
window.siyuan.menus.menu.removeCB = undefined;
|
||||
}
|
||||
if (isMobile()) {
|
||||
window.removeEventListener("touchmove", this.preventDefault, false);
|
||||
} else {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue