Is there a way to detect if an element is currently located within a div?
I have scrolling vertical menu. I set the height of the navigation div and then overflow:hidden so I only see a few of the links at a time.
So, I click a graphic at the bottom of the navigation to move the links down. I have another graphic at the top to get the opposite effect.
But, I can’t find a reliable way to stopping the animation. So the movement keeps going way past the first and last menu links.
You can see the problem at http://test2omniforce.co.uk/test
You need to test the current value of the div#content top margin when the buttons are clicked. So for example, the top button’s animation should only play if div#content margin-top is less than 0, and the bottom button’s animation when the margin-top is greater than -500.