[Grandmas-svn-commit] SF.net SVN: grandmas-svn: [162] trunk/src/dialogs/progress.cpp
Brought to you by:
matthiasmiller
From: <hig...@us...> - 2007-01-20 20:59:19
|
Revision: 162 http://svn.sourceforge.net/grandmas-svn/?rev=162&view=rev Author: highjinx Date: 2007-01-20 12:59:20 -0800 (Sat, 20 Jan 2007) Log Message: ----------- Display new text in the progress immediately by flushing message queues Modified Paths: -------------- trunk/src/dialogs/progress.cpp Modified: trunk/src/dialogs/progress.cpp =================================================================== --- trunk/src/dialogs/progress.cpp 2007-01-20 02:49:31 UTC (rev 161) +++ trunk/src/dialogs/progress.cpp 2007-01-20 20:59:20 UTC (rev 162) @@ -33,6 +33,12 @@ mpUi->statusLabel->setText(title); show(); + + // Force title and description to be displayed immediately + repaint(); + QApplication::flush(); + QApplication::sendPostedEvents(NULL, 0); + QApplication::processEvents(); } ProgressDialog::~ProgressDialog() @@ -48,7 +54,15 @@ QApplication::processEvents(); if (textToAdd != "") + { mpUi->statusTextEdit->append(textToAdd); + + // Force new text to display immediately + repaint(); + QApplication::flush(); + QApplication::sendPostedEvents(NULL, 0); + QApplication::processEvents(); + } } bool ProgressDialog::shouldCancel() This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |