jQuery has a .scrollTop() method, that can let you know where the page currently is. You can remember that value and return it back to where it was after toggling things.
But, I don’t think that toggle normally scrolls things, so can we please investigate a test page that exhibits the problem at hand?