added scrolling check