AutoTest: Cancel possible running tasks on shutdown

If tasks are running while shutting down we might end up in a crash,
so cancel all tasks and handle possible invalid accesses of the
current running processing.

Change-Id: I69f7cac5f44390e322fa301af6d6794270c95c2a
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Christian Stenger
2016-07-08 12:53:57 +02:00
parent e70adf820e
commit 48b2af5e77
6 changed files with 32 additions and 4 deletions

View File

@@ -48,7 +48,8 @@ public:
Idle,
PartialParse,
FullParse,
Disabled
Disabled,
Shutdown
};
explicit TestCodeParser(TestTreeModel *parent = 0);
@@ -77,6 +78,7 @@ public:
void onQmlDocumentUpdated(const QmlJS::Document::Ptr &document);
void onStartupProjectChanged(ProjectExplorer::Project *project);
void onProjectPartsUpdated(ProjectExplorer::Project *project);
void aboutToShutdown();
private:
bool postponed(const QStringList &fileList);