Adjust overflow handling so that it works consistently on IE7+