forked from qt-creator/qt-creator
ClangTools: Simplify/clarify labels in toolbar
Change-Id: I64b8fdb4484bf920944d86ad01675dbda516d6c4 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Ivan Donchevskii <ivan.donchevskii@qt.io>
This commit is contained in:
@@ -263,6 +263,7 @@ ClangTidyClazyTool::ClangTidyClazyTool()
|
|||||||
// Filter line edit
|
// Filter line edit
|
||||||
m_filterLineEdit = new Utils::FancyLineEdit();
|
m_filterLineEdit = new Utils::FancyLineEdit();
|
||||||
m_filterLineEdit->setFiltering(true);
|
m_filterLineEdit->setFiltering(true);
|
||||||
|
m_filterLineEdit->setPlaceholderText(tr("Filter Issues"));
|
||||||
m_filterLineEdit->setHistoryCompleter("CppTools.ClangTidyClazyIssueFilter", true);
|
m_filterLineEdit->setHistoryCompleter("CppTools.ClangTidyClazyIssueFilter", true);
|
||||||
connect(m_filterLineEdit, &Utils::FancyLineEdit::filterChanged, [this](const QString &filter) {
|
connect(m_filterLineEdit, &Utils::FancyLineEdit::filterChanged, [this](const QString &filter) {
|
||||||
m_diagnosticFilterModel->setFilterRegExp(
|
m_diagnosticFilterModel->setFilterRegExp(
|
||||||
@@ -427,16 +428,17 @@ void ClangTidyClazyTool::handleStateUpdate()
|
|||||||
m_goNext->setEnabled(issuesVisible > 1);
|
m_goNext->setEnabled(issuesVisible > 1);
|
||||||
|
|
||||||
QString message;
|
QString message;
|
||||||
if (m_running)
|
if (m_running) {
|
||||||
message = tr("Clang-Tidy and Clazy are running.");
|
if (issuesFound)
|
||||||
|
message = tr("Running - %n issues found", nullptr, issuesFound);
|
||||||
else
|
else
|
||||||
message = tr("Clang-Tidy and Clazy finished.");
|
message = tr("Running - No issues found", nullptr, issuesFound);
|
||||||
|
} else {
|
||||||
message += QLatin1Char(' ');
|
if (issuesFound)
|
||||||
if (issuesFound == 0)
|
message = tr("Finished - %n issues found", nullptr, issuesFound);
|
||||||
message += tr("No issues found.");
|
|
||||||
else
|
else
|
||||||
message += tr("%n issues found.", nullptr, issuesFound);
|
message = tr("Finished - No issues found", nullptr, issuesFound);
|
||||||
|
}
|
||||||
|
|
||||||
Debugger::showPermanentStatusMessage(message);
|
Debugger::showPermanentStatusMessage(message);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user