Viewing 5 replies - 16 through 20 (of 20 total)
  • Plugin Author Fabio Rinaldi

    (@fabiorino)

    Right button click:

    $('#theright').click(function() {
    	if(playing) {
    		$('.crellyslider-slider-myslider').data('crellySlider').nextSlide();
    		playing = true;
    	}
    	else {
    		$('.crellyslider-slider-myslider').data('crellySlider').nextSlide();
    		setTimeout(function() {
    			$('.crellyslider-slider-myslider').data('crellySlider').resume();
    			$('.crellyslider-slider-myslider').data('crellySlider').pause();
    			playing = false;
    		}, 400);
    	}
    });

    Controls click:

    $('#thecontrols .circle').click(function() {
    	var index = $(this).index();
    
    	if(playing) {
    		$('.crellyslider-slider-myslider').data('crellySlider').changeSlide(index);
    		playing = true;
    	}
    	else {
    		$('.crellyslider-slider-myslider').data('crellySlider').changeSlide(index);
    		setTimeout(function() {
    			$('.crellyslider-slider-myslider').data('crellySlider').resume();
    			$('.crellyslider-slider-myslider').data('crellySlider').pause();
    			playing = false;
    		}, 400);
    	}
    });

    The right and left is not what I meant, but it doesn’t really important as long as I can use the previousSlide and nextSlide functions.

    The Controls(it is important) didn’t work. I tried it as that:

    $('.cs-slide-link').click(function() {
    var index = $(this).index();
    if(playing) {
    $('.crellyslider-slider-myslider').data('crellySlider').changeSlide(index);
    playing = true;
    }
    else {
    $('.crellyslider-slider-myslider').data('crellySlider').changeSlide(index);
    setTimeout(function() {
    $('.crellyslider-slider-myslider').data('crellySlider').resume();
    $('.crellyslider-slider-myslider').data('crellySlider').pause();
    playing = false;
    }, 400);
    }
    });

    I also tried to change the .cs-slide-link for .cs-navigation > .cs-slide-link and for .cs-navigation and even for .cs-slide-link .cs-active – not working.

    Plugin Author Fabio Rinaldi

    (@fabiorino)

    What are you trying to target? I mean, did you create some custom buttons outside of the slider?

    No. If you go for your site’s main page(http://fabiorino1.altervista.org/projects/crellyslider/) you’ll see there’s buttons on the bottom of the slider it self, like radio-buttons, but they’re made with <span> tag. The div(parent element) of them is cs-navigation.

    Plugin Author Fabio Rinaldi

    (@fabiorino)

    Uhm ok, unfortunately you can’t do what you are asking with the default buttons because they are already programmed to work in a certain way. You should modify the slider source code in order to achieve what you’re asking, but I can’t give you support for that, it’s far beyond the help I can give you

Viewing 5 replies - 16 through 20 (of 20 total)

The topic ‘Pause button??’ is closed to new replies.