forked from qt-creator/qt-creator
BuildManager: Only pop up build issues if there are relevant issues.
Previously it also poped up and showed a build failure if there were any error-type tasks in 'My Tasks', 'Analyser' or 'QML'. Change-Id: Ie86be0afe1f0b7571b2cb764b7c53f282183b513 Reviewed-on: http://codereview.qt.nokia.com/2807 Reviewed-by: Tobias Hunger <tobias.hunger@nokia.com>
This commit is contained in:
@@ -876,19 +876,38 @@ void TaskWindow::filterCategoryTriggered(QAction *action)
|
||||
setCategoryVisibility(categoryId, action->isChecked());
|
||||
}
|
||||
|
||||
int TaskWindow::taskCount() const
|
||||
int TaskWindow::taskCount(const QString &category) const
|
||||
{
|
||||
return d->m_model->taskCount();
|
||||
if (category.isEmpty())
|
||||
return d->m_model->taskCount();
|
||||
|
||||
return d->m_model->tasks(category).size();
|
||||
}
|
||||
|
||||
int TaskWindow::errorTaskCount() const
|
||||
int TaskWindow::errorTaskCount(const QString &category) const
|
||||
{
|
||||
return d->m_model->errorTaskCount();
|
||||
if (category.isEmpty())
|
||||
return d->m_model->errorTaskCount();
|
||||
|
||||
int count = 0;
|
||||
foreach (const Task &task, d->m_model->tasks(category)) {
|
||||
if (task.type == Task::Error)
|
||||
++count;
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int TaskWindow::warningTaskCount() const
|
||||
int TaskWindow::warningTaskCount(const QString &category) const
|
||||
{
|
||||
return d->m_model->warningTaskCount();
|
||||
if (category.isEmpty())
|
||||
return d->m_model->warningTaskCount();
|
||||
|
||||
int count = 0;
|
||||
foreach (const Task &task, d->m_model->tasks(category)) {
|
||||
if (task.type == Task::Warning)
|
||||
++count;
|
||||
}
|
||||
return count;
|
||||
}
|
||||
|
||||
int TaskWindow::priorityInStatusBar() const
|
||||
|
||||
Reference in New Issue
Block a user