jenkins-bot has submitted this change and it was merged.

Change subject: Fix tap event fallback
......................................................................


Fix tap event fallback

Previously the click event callback was called before mouseup which
led to JS errors.

Change-Id: I3c31199fb1d7d3a5eec26efd20aca4551700d63a
---
M javascripts/externals/micro.tap.js
1 file changed, 3 insertions(+), 2 deletions(-)

Approvals:
  Jdlrobson: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/javascripts/externals/micro.tap.js 
b/javascripts/externals/micro.tap.js
index f3f997a..2468538 100644
--- a/javascripts/externals/micro.tap.js
+++ b/javascripts/externals/micro.tap.js
@@ -11,7 +11,7 @@
     if (!moved) $(ev.target).trigger(tapEv);
   }
 
-  // jQuery's on() doesn't allow useCapture argument (last argument, true)
+  // FIXME: jQuery's on() doesn't allow useCapture argument (last argument, 
true)
   window.addEventListener('click', function(ev) {
     if (tapEv.isDefaultPrevented()) {
       ev.stopPropagation();
@@ -29,7 +29,8 @@
       }).
       on('touchend', handleTap);
   } else {
-    $window.on('mouseup', handleTap);
+    // FIXME: jQuery's on() doesn't allow useCapture argument (last argument, 
true)
+    window.addEventListener('mouseup', handleTap, true);
   }
 }(jQuery));
 

-- 
To view, visit https://gerrit.wikimedia.org/r/79814
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I3c31199fb1d7d3a5eec26efd20aca4551700d63a
Gerrit-PatchSet: 2
Gerrit-Project: mediawiki/extensions/MobileFrontend
Gerrit-Branch: master
Gerrit-Owner: JGonera <[email protected]>
Gerrit-Reviewer: Jdlrobson <[email protected]>
Gerrit-Reviewer: jenkins-bot

_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to