Fixing window issues