]> git.lyx.org Git - features.git/commitdiff
don't show errors when auto saving, #7132
authorPeter Kümmel <syntheticpp@gmx.net>
Mon, 6 Dec 2010 20:54:03 +0000 (20:54 +0000)
committerPeter Kümmel <syntheticpp@gmx.net>
Mon, 6 Dec 2010 20:54:03 +0000 (20:54 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36745 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/GuiView.cpp
src/frontends/qt4/GuiView.h

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
 
 
index a7fd79e8ca66120026c71b5da3aff8a7a6afc9a3..38ace236767c82372eb2e3d3a36795b0447c9911 100644 (file)
@@ -232,7 +232,9 @@ private Q_SLOTS:
 
        /// For completion of autosave or export threads.
        void processingThreadStarted();
+  void processingThreadFinished(bool show_errors);
        void processingThreadFinished();
+  void autoSaveThreadFinished();
        void indicateProcessing();
 
        /// must be called in GUI thread