MalisisCore

48M Downloads

Parent container won't scroll when container contentSize <= size

Barteks2x opened this issue ยท 0 comments

commented

The code for detecing "can't scroll more" looks like this return !(delta > 0 && o == 0 || delta < 0 && o == 1); which works fine when there is anything that can be scrolled. But when there isn't, the ofset is (currently) either NaN or 0. This means that scrolling in one direction may work if it's 0, but not in the other direction. And when the sizes are equal, it won't work at all because of the NaN.