Throttle and debounce scroll events.