Fix window init