Avoid missing pages in expand scroll - fixes #1391

Signed-off-by: emanuele <emanuele45@gmail.com>