Changed mechanism of adjusting scrollview when the keyboard appears/disappears.