summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorChristian Stenger <christian.stenger@theqtcompany.com>2016-02-29 11:14:40 +0100
committerChristian Stenger <christian.stenger@theqtcompany.com>2016-03-04 13:46:51 +0000
commitf99f5dcdc6f1ae26145242712985ca42d724e34d (patch)
treeed0a652d5903f42144caac06695fc44c8e281e94 /src
parentbfd84c3437e555960b5d57dc66ff1d6a7a46762e (diff)
downloadqt-creator-f99f5dcdc6f1ae26145242712985ca42d724e34d.tar.gz
AutoTest: Fix enabled state of Run buttons of results pane
Run buttons of the results pane might stay disabled after a parse if no items would be swept. Change-Id: I3df800ec0b42fa7de2b010a911922427da51df3c Reviewed-by: David Schulz <david.schulz@theqtcompany.com>
Diffstat (limited to 'src')
-rw-r--r--src/plugins/autotest/testtreemodel.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/plugins/autotest/testtreemodel.cpp b/src/plugins/autotest/testtreemodel.cpp
index 502a24507f..0d00fdc7c4 100644
--- a/src/plugins/autotest/testtreemodel.cpp
+++ b/src/plugins/autotest/testtreemodel.cpp
@@ -561,14 +561,13 @@ void TestTreeModel::markForRemoval(const QString &filePath)
void TestTreeModel::sweep()
{
- bool hasChanged = false;
Type types[] = { AutoTest, QuickTest, GoogleTest };
for (Type type : types) {
TestTreeItem *root = rootItemForType(type);
- hasChanged |= sweepChildren(root);
+ sweepChildren(root);
}
- if (hasChanged)
- emit testTreeModelChanged();
+ // even if nothing has changed by the sweeping we might had parse which added or modified items
+ emit testTreeModelChanged();
#ifdef WITH_TESTS
if (m_parser->state() == TestCodeParser::Idle && !m_parser->furtherParsingExpected())
emit sweepingDone();