This would be a great feature to stop the carousel when we hover over the animated carousel. Any plan or hack to do that?

Thank you sharing.

CommentFileSizeAuthor
#13 253553_stop_on_hover_5.x.patch819 bytesdeviantintegral

Comments

jcfiala’s picture

Hmm. Well, you could do a mouseover on the carousel that would turn off the autoscroll...

I'd have to consider it.

deviantintegral’s picture

This is also something I'm interested in. I was thinking that the carousel would stop when an index was clicked, but a mouseover would achieve a similar effect.

--Andrew

mulogic’s picture

I am also looking for this feature. would be great, if auto scroll stops after the user clicks an index. This may give time for user to read the slide.

thanks

Mike Sances’s picture

Also in need of this.

Perhaps the code from this comment would be helpful: http://drupal.org/node/184428#comment-615804

Just paste a variant of this in the "Javascript Scroll Event Handler:" field on the nodecarousel block settings page?

2c’s picture

Subscribing

rick hood’s picture

Title: Stopping the carousel on hover » Just chiming that I could use this too.

Just chiming in that I could use this myself. Not good enough with JavaScipt to figure this out myself. Also not sure how to implement comment #4 above.

rick hood’s picture

Sorry changed title by mistake - changing back.

ultimateboy’s picture

Title: Just chiming that I could use this too. » Stopping the carousel on hover
Status: Active » Postponed

Interesting idea.. will keep in mind for the next release.

artscientific’s picture

This would be a Very Good Thing(tm)

jacerider’s picture

Yeah, very easy to get working.

Search nodecarousel.module for:

    jQuery('div#nc_last_%d').click(function(e) {
      carousel.scroll($("#nc_" + carouselName + " li").length, true);
    });

And add the below code directly after:

    // Pause autoscrolling if the user moves with the cursor over the clip.
    carousel.clip.hover(function() {
        carousel.stopAuto();
    }, function() {
        carousel.startAuto();
    });

Would be a simple addition to module core -- ideally with an option to enable/disable the functionality in the module admin.

iamwhoiam’s picture

thanks!

jason ruyle’s picture

I wanted to know if anyone has a suggestion on how to get this working with the class index_control_list?
The index_control information is created after the hover function is created, so if I try and put that code in, it says the function hasn't been created.

Not sure how to go about fixing this.

deviantintegral’s picture

Version: 5.x-1.0 » 5.x-1.x-dev
Category: support » feature
Status: Postponed » Needs work
StatusFileSize
new819 bytes

Here's a patch against 5.x-dev of the code in #10. It doesn't implement this as a toggleable setting yet, though IMO carousels should never move when it has focus anyways.

nbchip’s picture

Concerning index_control_list
After Line 1542 add:

outermostDiv.children(".index_control_list").children(".index_control_item").hover(function() {
        carousel.scroll(parseInt($(this).attr('li_index')), true);
        carousel.startAuto(0);
      }, 
      function () {
        carousel.startAuto(4); //4 = number of secodns , it saved in  $nc->autoscroll
      }
    );