I'm using Mike Alsup's awesome Cycle2 jquery plugin on a slideshow that features both a custom pager element (thumbnails) and previous/next buttons. How can I trigger an action using the cycle-after event only if the pager was clicked.
$('#myslideshow').on('cycle-after',function(e, optionHash, outgoingSlideEl, incomingSlideEl, forwardFlag){
// Do something here only if the pager was clicked.
});
I don't want to use the click event from the pager element - that won't wait until the slide transition is complete, it fires right away, and seems to conflict with the slideshow animations sometimes.