ProjectExplorer: Do not add too many newlines

Do not add newlines when output gets flushed.

Task-number: QTCREATORBUG-17403
Change-Id: I0dea3a15611fcde8aa8cbc5fbc6b7f22c9c40dd7
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Tobias Hunger
2017-11-23 17:29:20 +01:00
parent 4c8db5e9b7
commit 58fd29e0ed
4 changed files with 6 additions and 6 deletions

View File

@@ -1810,9 +1810,9 @@ void RunWorker::reportFailure(const QString &msg)
* Appends a message in the specified \a format to
* the owning RunControl's \uicontrol{Application Output} pane.
*/
void RunWorker::appendMessage(const QString &msg, OutputFormat format)
void RunWorker::appendMessage(const QString &msg, OutputFormat format, bool appendNewLine)
{
if (msg.endsWith('\n'))
if (!appendNewLine || msg.endsWith('\n'))
d->runControl->appendMessage(msg, format);
else
d->runControl->appendMessage(msg + '\n', format);