focus input when switching windows, fixes #259