javascript - How to ignore mouse activity until function completes -
I use the following code to slide a div over the mouse over, waiting a few seconds and div Slide back. ("Slide", {direction: "left"}, 1000). Pose (2000). Hyde ("slide", {direction: "left"}, 1000);});});
I'm sure this is easy, but I have limited knowledge of JavaScript / jQuery. How can I do this so that any mouse activity on the trigger is ignored until the animation is complete? Right now, if you open the divas on the trigger area, it "remembers" and when you move the pointer through the trigger area, then plays for animation several times.
Do not bind and bind and instead of using a flag to fix it For whether you should take care about the event. $ (Document) .ready (function () {$ ("#party"). Mouseover (function () {var $ this = $ (this); if ($ this. $ ("Slide", {direction: "left "}, 1000) .Pause (2000); Data ('emmos'); $. (" Slide ", {direction:" left "}, 1000, function () {$ this.data ('nomouse' , False);});});}); In the
Comments
Post a Comment