Fix overflow bug on slides.