fixed variable scope to allow simultaneous scrolling