From bd52f387883c0305c52f8aa4400273117db9bcd7 Mon Sep 17 00:00:00 2001 From: Mark Salsbery Date: Wed, 23 Apr 2014 08:38:55 -0700 Subject: [PATCH] iOS touch enter/exit fix for BUttonGroup --- src/buttongroup.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/src/buttongroup.js b/src/buttongroup.js index b8e92119..a05e9084 100644 --- a/src/buttongroup.js +++ b/src/buttongroup.js @@ -103,9 +103,17 @@ $.ButtonGroup = function( options ) { } } }, + pressHandler: function ( event ) { + if ( event.pointerType === 'touch' && !$.MouseTracker.haveTouchEnter ) { + var i; + for ( i = 0; i < _this.buttons.length; i++ ) { + _this.buttons[ i ].notifyGroupEnter(); + } + } + }, releaseHandler: function ( event ) { var i; - if ( !event.insideElementReleased ) { + if ( !event.insideElementReleased || ( event.pointerType === 'touch' && !$.MouseTracker.haveTouchEnter ) ) { for ( i = 0; i < _this.buttons.length; i++ ) { _this.buttons[ i ].notifyGroupExit(); }