Removed the client part from the mainwindow also. Everything is connected through signals and slots now.