update other build systems, cleanup progress output

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@32611 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Peter Kümmel 2009-12-22 10:33:01 +00:00
parent 7afdba6b06
commit 1e7c296557
5 changed files with 17 additions and 11 deletions

View File

@ -756,6 +756,7 @@ src_frontends_qt4_header_files = Split('''
GuiPrintindex.h
GuiPrintNomencl.h
GuiProgress.h
GuiProgressView.h
GuiRef.h
GuiSearch.h
GuiSelection.h
@ -855,6 +856,7 @@ src_frontends_qt4_files = Split('''
GuiPrintindex.cpp
GuiPrintNomencl.cpp
GuiProgress.cpp
GuiProgressView.cpp
GuiRef.cpp
GuiSearch.cpp
GuiSelection.cpp

View File

@ -77,13 +77,15 @@ void GuiProgress::doProcessFinished(QString const & cmd)
void GuiProgress::doAppendMessage(QString const & msg)
{
appendText(msg);
QString time = QTime::currentTime().toString();
appendText(time + " : " + msg);
}
void GuiProgress::doAppendError(QString const & msg)
{
appendText(msg);
QString time = QTime::currentTime().toString();
appendText(time + " : " + msg);
}

View File

@ -15,6 +15,7 @@
#include "qt_helpers.h"
#include <QTime>
namespace lyx {
@ -34,10 +35,10 @@ GuiProgressView::GuiProgressView(GuiView & parent, Qt::DockWidgetArea area,
if (progress) {
connect(progress, SIGNAL(processStarted(QString const &)), this, SLOT(appendText(QString const &)));
connect(progress, SIGNAL(processFinished(QString const &)), this, SLOT(appendText(QString const &)));
//connect(progress, SIGNAL(processFinished(QString const &)), this, SLOT(appendText(QString const &)));
connect(progress, SIGNAL(appendMessage(QString const &)), this, SLOT(appendText(QString const &)));
connect(progress, SIGNAL(appendError(QString const &)), this, SLOT(appendText(QString const &)));
connect(progress, SIGNAL(clearMessages()), this, SLOT(clearText(QString const &)));
connect(progress, SIGNAL(clearMessages()), this, SLOT(clearText()));
}
}
@ -50,14 +51,15 @@ void GuiProgressView::clearText()
void GuiProgressView::appendText(QString const & text)
{
text_edit.insertPlainText(text);
if (text.isEmpty())
return;
QString time = QTime::currentTime().toString();
text_edit.insertPlainText(time + ": " + text + "\n");
text_edit.ensureCursorVisible();
}
Dialog * createGuiProgressView(GuiView & guiview)
{
#ifdef Q_WS_MACX

View File

@ -2707,8 +2707,7 @@ bool GuiView::dispatch(FuncRequest const & cmd)
format = doc_buffer->getDefaultOutputFormat();
#if EXPORT_in_THREAD && (QT_VERSION >= 0x040400)
ProgressInterface::instance()->clearMessages();
QString time = QTime::currentTime().toString();
ProgressInterface::instance()->appendMessage(time + ": Exporting ...\n");
ProgressInterface::instance()->appendMessage("Exporting ...");
QFuture<docstring> f = QtConcurrent::run(exportAndDestroy,
doc_buffer->clone(), format);
d.setPreviewFuture(f);
@ -2725,8 +2724,7 @@ bool GuiView::dispatch(FuncRequest const & cmd)
format = doc_buffer->getDefaultOutputFormat();
#if EXPORT_in_THREAD && (QT_VERSION >= 0x040400)
ProgressInterface::instance()->clearMessages();
QString time = QTime::currentTime().toString();
ProgressInterface::instance()->appendMessage(time + ": Previewing ...\n");
ProgressInterface::instance()->appendMessage("Previewing ...");
QFuture<docstring> f = QtConcurrent::run(previewAndDestroy,
doc_buffer->clone(), format);
d.setPreviewFuture(f);

View File

@ -109,6 +109,7 @@ SOURCEFILES = \
GuiPrintindex.cpp \
GuiPrintNomencl.cpp \
GuiProgress.cpp \
GuiProgressView.cpp \
GuiRef.cpp \
GuiSearch.cpp \
GuiSelection.cpp \
@ -210,6 +211,7 @@ MOCHEADER = \
GuiPrintindex.h \
GuiPrintNomencl.h \
GuiProgress.h \
GuiProgressView.h \
GuiRef.h \
GuiSearch.h \
GuiSelection.h \