connected with main window