Remove unnecessary check for MainWindow instance

The error-callback is installed in the MainWindow constructor.
Therefore, in the error-callback the existence of the MainWindow
instance is guaranteed.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2018-01-26 18:39:46 +01:00 committed by Jan Mulder
parent a25f54e3c2
commit df81a39aa5

View file

@ -91,9 +91,7 @@ MainWindow *MainWindow::m_Instance = NULL;
extern "C" void showErrorFromC()
{
MainWindow *mainwindow = MainWindow::instance();
if (mainwindow)
emit mainwindow->showError(get_error_string());
emit MainWindow::instance()->showError(get_error_string());
}
MainWindow::MainWindow() : QMainWindow(),