Fix null pointer trying to alt-tab without windows