]> git.lyx.org Git - features.git/commitdiff
don't eat a CPU core when using Qt < 4.4 or EXPORT_in_THREAD == 1
authorPeter Kümmel <syntheticpp@gmx.net>
Mon, 8 Nov 2010 08:40:12 +0000 (08:40 +0000)
committerPeter Kümmel <syntheticpp@gmx.net>
Mon, 8 Nov 2010 08:40:12 +0000 (08:40 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36208 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/GuiView.cpp

index 23e9b5e45126435bfbc51307e271a33e8ff3a97a..66b621f82ff9971d34d5c12f89bab0f2a99e5bdf 100644 (file)
@@ -2951,13 +2951,15 @@ bool GuiView::GuiViewPrivate::asyncBufferProcessing(
        // We are asynchronous, so we don't know here anything about the success
        return true;
 #else
-       bool const update_unincluded =
-               used_buffer->params().maintain_unincluded_children &&
-               !used_buffer->params().getIncludedChildren().empty();
        if (syncFunc) {
+               // TODO check here if it breaks exporting with Qt < 4.4
+               bool const update_unincluded =
+                               used_buffer->params().maintain_unincluded_children &&
+                               !used_buffer->params().getIncludedChildren().empty();
                return (used_buffer->*syncFunc)(format, true, update_unincluded);
        } else if (previewFunc) {
-               return (used_buffer->*previewFunc)(format, update_unincluded);
+    // TODO includeall must be false or we get a 100% busy thread, a bug?
+               return (used_buffer->*previewFunc)(format, false);
        }
        (void) asyncFunc;
        return false;