javascript - A question about the mousdown event
世界只因有你
世界只因有你 2017-05-19 10:14:34
0
1
431

Help, I used $.animate to implement an event based on the page element mousdown. After doing it, I found a problem. After clicking the mouse multiple times in succession, the animation will be played repeatedly multiple times. The effect I want to achieve is that every time I click The animation is always played from the beginning. Multiple clicks will generate multiple mousdown events. How to judge whether the playback is completed based on the duration of the animation? If the playback is not completed, terminate the current animation and restart the playback?

世界只因有你
世界只因有你

reply all(1)
世界只因有你

When you click, terminate it first, and then continue the work, and it will be fine.

Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template