Created
December 7, 2012 14:11
-
-
Save fredleblanc/4233488 to your computer and use it in GitHub Desktop.
Touch Stuff
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// bindEvents | |
// binds all applicable events | |
bindEvents: function() { | |
var self = $(this), | |
settings = self.data("slideshow"); | |
settings.stage | |
.find(".thumbs") | |
.on("click", "img", function() { | |
var index = settings.stage.find(".thumbs img").index($(this)); | |
methods.select.apply(self, [index]); | |
}) | |
.on("touchstart", "img", function() { | |
var index = settings.stage.find(".thumbs img").index($(this)); | |
methods.select.apply(self, [index]); | |
return false; | |
}); | |
}, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment