[jQuery] Re: one div, multiple clicks

2009-06-25 Thread Charlie
here's a working example , using addClass() and removeClass to test which animation to use. Works on multiple clicks http://jsbin.com/ulafa mkauppinen wrote: Ok, but it works only once. What if I want to open it again? On Jun 25, 3:20 pm, Charlie wrote: in your click function

[jQuery] Re: one div, multiple clicks

2009-06-25 Thread mkauppinen
Ok, but it works only once. What if I want to open it again? On Jun 25, 3:20 pm, Charlie wrote: > in your click function: > if ($(this).is(":animated")){ >        //do whatever you mean by "close" >      } >      //original animation here and remove $(this).animate from mouseleave

[jQuery] Re: one div, multiple clicks

2009-06-25 Thread Charlie
in your click function: if ($(this).is(":animated")){        //do whatever you mean by "close"      }      //original animation here and remove $(this).animate from mouseleave mkauppinen wrote: Hi! I have one div (.masterpiece) and now i can open it by click and close it by move mouse o