revert mainwindow.cpp