]> git.lyx.org Git - features.git/blobdiff - src/frontends/qt4/GuiView.cpp
don't show errors when auto saving, #7132
[features.git] / src / frontends / qt4 / GuiView.cpp
index 554fd90afc03141c40ef5af7efdc14ec4d4f6b0f..8585fb4cb1471ac8b62518517a0da8dba7822e86 100644 (file)
@@ -446,7 +446,7 @@ GuiView::GuiView(int id)
 
 #if (QT_VERSION >= 0x040400)
        connect(&d.autosave_watcher_, SIGNAL(finished()), this,
-               SLOT(processingThreadFinished()));
+               SLOT(autoSaveThreadFinished()));
        connect(&d.processing_thread_watcher_, SIGNAL(finished()), this,
                SLOT(processingThreadFinished()));
 
@@ -548,18 +548,30 @@ void GuiView::processingThreadStarted()
 }
 
 
-void GuiView::processingThreadFinished()
+void GuiView::processingThreadFinished(bool show_errors)
 {
        QFutureWatcher<docstring> const * watcher =
                static_cast<QFutureWatcher<docstring> const *>(sender());
        message(watcher->result());
        updateToolbars();
-       errors(d.last_export_format);
+       if (show_errors) {
+               errors(d.last_export_format);
+       }
        d.processing_cursor_timer_.stop();
        restoreCursorShapes();
        d.indicates_processing_ = false;
 }
 
+void GuiView::processingThreadFinished()
+{
+       processingThreadFinished(true);
+}
+
+void GuiView::autoSaveThreadFinished()
+{
+       processingThreadFinished(false);
+}
+
 #else
 
 void GuiView::setCursorShapes(Qt::CursorShape)
@@ -587,9 +599,19 @@ void GuiView::processingThreadStarted()
 }
 
 
+void GuiView::processingThreadFinished(bool)
+{
+}
+
+
 void GuiView::processingThreadFinished()
 {
 }
+
+
+void GuiView::autoSaveThreadFinished()
+{
+}
 #endif