Scroller: page indices are calculated while dragging (closes #831), organized refreshScrollValues() into smaller functions to improve readability.