Commit 7e1b512f authored by Fawzi Mohamed's avatar Fawzi Mohamed Committed by Fawzi Mohamed
Browse files

qmljs: add isIdle method to detect background parsing/scannig



If the qmljsmodel has no background task, then isIdle returns true

Change-Id: I31420343c560c5ed118f371f7be347eadb6622f4
Reviewed-by: default avatarThomas Hartmann <Thomas.Hartmann@digia.com>
parent 7c9c5bda
......@@ -629,6 +629,11 @@ ModelManagerInterface::ProjectInfo ModelManagerInterface::projectInfoForPath(QSt
return res;
}
bool ModelManagerInterface::isIdle() const
{
return m_synchronizer.futures().isEmpty();
}
void ModelManagerInterface::emitDocumentChangedOnDisk(Document::Ptr doc)
{ emit documentChangedOnDisk(doc); }
......
......@@ -182,6 +182,7 @@ public:
void emitDocumentChangedOnDisk(QmlJS::Document::Ptr doc);
void updateQrcFile(const QString &path);
ProjectInfo projectInfoForPath(QString path) const;
bool isIdle() const ;
PathsAndLanguages importPaths() const;
QmlJS::QmlLanguageBundles activeBundles() const;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment