Some refactoring to remove static instances of MainWindow and Mediator, interfaces around Medator logic added