Core: Use new MessageManager API

Bring messages pane to front when triggering an external tool or
command, write output silently and flash when tool finishes or fails.

Also bring pane to front if file renaming or removing fails (this should
happen only as a direct consequence of the user choosing this action).

Task-number: QTCREATORBUG-24430
Change-Id: Ib47431bd57a9c05bfdbfb03ad4c7cd38bdf3ddd1
Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
Eike Ziller
2020-12-01 13:02:12 +01:00
parent a0079b171f
commit 5738418d41
6 changed files with 59 additions and 41 deletions

View File

@@ -231,7 +231,7 @@ void ExternalToolManager::setToolsByCategory(const QMap<QString, QList<ExternalT
connect(action, &QAction::triggered, tool, [tool] {
auto runner = new ExternalToolRunner(tool);
if (runner->hasError())
MessageManager::write(runner->errorString());
MessageManager::writeFlashing(runner->errorString());
});
command = ActionManager::registerAction(action, externalToolsPrefix.withSuffix(toolId));