diff --git a/api/js/egw_action/EgwPopupActionImplementation.ts b/api/js/egw_action/EgwPopupActionImplementation.ts index 3f2fdecdab..09d5688e8d 100644 --- a/api/js/egw_action/EgwPopupActionImplementation.ts +++ b/api/js/egw_action/EgwPopupActionImplementation.ts @@ -526,7 +526,8 @@ export class EgwPopupActionImplementation implements EgwActionImplementation { const tree = {"root": []}; // Automatically add in Drag & Drop actions - if (this.auto_paste && !window.egwIsMobile()&& !this._context.event.type.match(/touch/)) { + if(this.auto_paste && !window.egwIsMobile() && !this._context.event?.type.match(/touch/)) + { this._addCopyPaste(_links, _selected); } diff --git a/api/js/egw_action/egw_keymanager.ts b/api/js/egw_action/egw_keymanager.ts index 849e5092f3..cb528d49c2 100755 --- a/api/js/egw_action/egw_keymanager.ts +++ b/api/js/egw_action/egw_keymanager.ts @@ -139,7 +139,10 @@ ready(() => {//waits for DOM ready window.addEventListener("contextmenu", function(event) { // Check for actual key press - if (!(event.originalEvent.x == 1 && event.originalEvent.y == 1)) return true; + if(!(event.x == 1 && event.y == 1)) + { + return true; + } if (!event.ctrlKey && egw_keyHandler(EGW_KEY_MENU, event.shiftKey, event.ctrlKey || event.metaKey, event.altKey)) { // If the key handler successfully passed the key event to some