Completed the management of monitors in main window