From 8108009ba7f47e3b7eb58e62b3a6a0e280e29b07 Mon Sep 17 00:00:00 2001 From: "ethan.li" Date: Tue, 9 Jul 2013 11:07:18 +1000 Subject: [PATCH 1/3] fix issue: onTouchEnd did not call the correct mouse up handler --- src/mousetracker.js | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/mousetracker.js b/src/mousetracker.js index c7a937f4..22596eb7 100644 --- a/src/mousetracker.js +++ b/src/mousetracker.js @@ -789,7 +789,13 @@ event.changedTouches.length == 1 ){ THIS[ tracker.hash ].lastTouch = null; - onMouseUp( tracker, event.changedTouches[ 0 ] ); + + if ($.Browser.vendor == $.BROWSERS.IE && $.Browser.version < 9) { + onMouseUpIE(tracker, event); + } else { + onMouseUpWindow(tracker, event); + } + onMouseOut( tracker, event.changedTouches[ 0 ] ); } if( event.touches.length + event.changedTouches.length == 2 ){ From 0ef98be0b7df9acf3c85396f7bb9dcbe61963c24 Mon Sep 17 00:00:00 2001 From: "ethan.li" Date: Fri, 12 Jul 2013 10:29:44 +1000 Subject: [PATCH 2/3] for fix I made to onTouchEnd: 1. remove IE8 related code as it does not support touch anyway 2. use event.changedTouches [ 0 ] rather than event --- src/mousetracker.js | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/mousetracker.js b/src/mousetracker.js index 22596eb7..b3d15737 100644 --- a/src/mousetracker.js +++ b/src/mousetracker.js @@ -790,12 +790,7 @@ THIS[ tracker.hash ].lastTouch = null; - if ($.Browser.vendor == $.BROWSERS.IE && $.Browser.version < 9) { - onMouseUpIE(tracker, event); - } else { - onMouseUpWindow(tracker, event); - } - + onMouseUpWindow( tracker, event.changedTouches[ 0 ] ); onMouseOut( tracker, event.changedTouches[ 0 ] ); } if( event.touches.length + event.changedTouches.length == 2 ){ From aa7111aef154eec817137803d1c2607a0b3a893c Mon Sep 17 00:00:00 2001 From: Ian Gilman Date: Fri, 12 Jul 2013 09:03:34 -0700 Subject: [PATCH 3/3] changelog update for #159 --- changelog.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/changelog.txt b/changelog.txt index 5bc0d8dd..3de46009 100644 --- a/changelog.txt +++ b/changelog.txt @@ -4,6 +4,7 @@ OPENSEADRAGON CHANGELOG 0.9.130: (In progress) * OpenSeadragon.now() returned undefined the first time; fixed +* onTouchEnd did not call the correct mouse up handler; fixed (#159) 0.9.129: