Add window creation to main