Improve scroller logic