Permalink
Browse files

removed vclick + click combined event binding, which was in there as …

…a workaround for a not-consistently-occurring bug in Android 2.1. I think the real issue is related to lack of dynamic base tag support, and that occasionally, a relative href click will use default handling in 2.1 and go where it shouldn't (ignoring the base href). Either way, this double binding causes history problems in Safari, so I'm removing it while we search for a better 2.1 workaround. Fixes #1870
  • Loading branch information...
1 parent 3e3a574 commit c227535bd7c5d7e60b535eaba178cf6aa5af7389 scottjehl committed Jun 21, 2011
Showing with 1 addition and 6 deletions.
  1. +1 −6 js/jquery.mobile.navigation.js
@@ -999,12 +999,7 @@
});
// click routing - direct to HTTP or Ajax, accordingly
- // TODO: most of the time, vclick will be all we need for fastClick bulletproofing.
- // However, it seems that in Android 2.1, a click event
- // will occasionally arrive independently of the bound vclick
- // binding to click as well seems to help in this edge case
- // we'll dig into this further in the next release cycle
- $( document ).bind( $.mobile.useFastClick ? "vclick click" : "click", function( event ) {
+ $( document ).bind( $.mobile.useFastClick ? "vclick" : "click", function( event ) {
@jblas
jblas Jun 21, 2011 Contributor

Scott, this is one of those cases where vclick is triggered on the touchend event and the mouse click is triggered on a different element, in this case the home button that appears on in the same region that was tapped.

I can't repro 1870 at all on the desktop, but I do see it on touch based devices.

@smeder
smeder Jun 27, 2011

Definitely seeing the described behavior (Android 2.3 in my case)

var link = findClosestLink( event.target );
if ( !link ) {
return;

0 comments on commit c227535

Please sign in to comment.