Jonathan2 Posted May 3, 2019 Share Posted May 3, 2019 Hello, Im using a script to scroll the scrollbar on browser resize. If there is no scrollbar and it is resized until there is a scrollbar it will be centered so I use a calculation like this: scrollbar length / scroll bar divider When it is centered the divider is 2. Now I want to remember the relative scrollbar position when scrolling, for this I calculate the scroll bar divider onscroll, but the event also fires when the resize script is called. I somehow only want the onscroll script to fire when the scrollbar is used by mouse or mousewheel. Link to comment Share on other sites More sharing options...
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!Register a new account
Already have an account? Sign in here.Sign In Now