Bugfix with windows destroying