fixed window bug again, maybe again?