fixes to new window implementation