Last active
December 21, 2015 20:19
-
-
Save spacegauch0/6360676 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
| // init and stop the inner slideshows | |
| var inners = $('.gallery-project .gallery-images').cycle().cycle('stop'); | |
| var slideshow = $('#slideshow').cycle({ | |
| fx: 'fade', | |
| speed: 300, | |
| timeout: 0, | |
| prev: '#prev', | |
| next: '#next', | |
| before: function() { | |
| // stop all inner slideshows | |
| inners.cycle('stop'); | |
| // start the new slide's slideshow | |
| $(this).find('.gallery-images').cycle({ | |
| fx: 'fade', | |
| timeout: 2000, | |
| pager: $(this).find('.slidesjs-pagination'), | |
| autostop: true, | |
| end: function() { | |
| // when inner slideshow ends, advance the outer slideshow | |
| slideshow.cycle('next'); | |
| } | |
| }); | |
| } | |
| }); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment