prevent multiple copies of the main window at a time