fix incorrect window height bug