expand and collapse icon problem on slideToggle in jQuery
<p>i am implementing a tree view with juqery.</p>

<p>i use slideToggle() to expand-collapse sub trees and change the image showing its status(expand or collapse) in slideToggle method as a function and by using what Nick learn me at this question:</p>

<p><a href="http://stackoverflow.com/questions/4482351/is-there-a-togglesrc-method-in-jquery/4482375#4482375">is there a toggleSrc method in jQuery?</a></p>

<p>but its image changing is not natural.i mean it shows collapse image when sub tree opens completely and shows expand image when sub tree closes completely.the expand changing is natural but the collapse not.i mean the collapse image should be shown when sub tree start to collapse not after it complete it.</p>

<p>hope i could describe my mean clearly.</p>

<p>is it possible to do what i mean?</p>

<p>thank you in advance.</p>
