From 9c64c3b7080880e4a596ac44e6b0086ce4783bb9 Mon Sep 17 00:00:00 2001 From: Hadi Nategh Date: Mon, 8 Feb 2016 10:48:12 +0000 Subject: [PATCH] Mobile theme W.I.P.: - Fix triggering contextmenu --- phpgwapi/js/egw_action/egw_action_popup.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/phpgwapi/js/egw_action/egw_action_popup.js b/phpgwapi/js/egw_action/egw_action_popup.js index c5e824870a..c995c9fe35 100644 --- a/phpgwapi/js/egw_action/egw_action_popup.js +++ b/phpgwapi/js/egw_action/egw_action_popup.js @@ -257,6 +257,7 @@ function egwPopupActionImplementation() ai._registerContext = function(_node, _callback, _context) { var contextHandler = function(e) { + if(egwIsMobile() && e.originalEvent.which == 3) return; //Obtain the event object if (!e) { @@ -281,12 +282,8 @@ function egwPopupActionImplementation() } return !e.cancelBubble; }; - - if (egwIsMobile()) { - $j(_node).bind('taphold', contextHandler); - } else { - $j(_node).on('contextmenu', contextHandler); - } + + $j(_node).on('contextmenu', contextHandler); }; ai.doRegisterAction = function(_aoi, _callback, _context)