diff options
author | Fawzi Mohamed <fawzi.mohamed@digia.com> | 2014-02-13 11:11:40 +0100 |
---|---|---|
committer | Fawzi Mohamed <fawzi.mohamed@digia.com> | 2014-02-19 21:24:34 +0100 |
commit | 13349331e86589242c1a8daeb9bb89376ce8407d (patch) | |
tree | e42f890ab22257fc37d312ab7bff0816551663e0 /src/libs/qmljs/qmljsmodelmanagerinterface.cpp | |
parent | d24cb60d487e2241c8364b83658f31178305176a (diff) | |
download | qt-creator-13349331e86589242c1a8daeb9bb89376ce8407d.tar.gz |
qmljs: fixing attributes naming (code style)
Change-Id: I3d5916483b99a8d6839b9cb6b9bde119a9da351a
Reviewed-by: Fawzi Mohamed <fawzi.mohamed@digia.com>
Diffstat (limited to 'src/libs/qmljs/qmljsmodelmanagerinterface.cpp')
-rw-r--r-- | src/libs/qmljs/qmljsmodelmanagerinterface.cpp | 30 |
1 files changed, 16 insertions, 14 deletions
diff --git a/src/libs/qmljs/qmljsmodelmanagerinterface.cpp b/src/libs/qmljs/qmljsmodelmanagerinterface.cpp index d9aa6aa118..6188b145be 100644 --- a/src/libs/qmljs/qmljsmodelmanagerinterface.cpp +++ b/src/libs/qmljs/qmljsmodelmanagerinterface.cpp @@ -121,6 +121,8 @@ ModelManagerInterface::ModelManagerInterface(QObject *parent) ModelManagerInterface::~ModelManagerInterface() { + m_cppQmlTypesUpdater.cancel(); + m_cppQmlTypesUpdater.waitForFinished(); Q_ASSERT(g_instance == this); g_instance = 0; } @@ -248,13 +250,13 @@ void ModelManagerInterface::loadQmlTypeDescriptionsInternal(const QString &resou Snapshot ModelManagerInterface::snapshot() const { QMutexLocker locker(&m_mutex); - return _validSnapshot; + return m_validSnapshot; } Snapshot ModelManagerInterface::newestSnapshot() const { QMutexLocker locker(&m_mutex); - return _newestSnapshot; + return m_newestSnapshot; } void ModelManagerInterface::updateSourceFiles(const QStringList &files, @@ -321,8 +323,8 @@ void ModelManagerInterface::removeFiles(const QStringList &files) QMutexLocker locker(&m_mutex); foreach (const QString &file, files) { - _validSnapshot.remove(file); - _newestSnapshot.remove(file); + m_validSnapshot.remove(file); + m_newestSnapshot.remove(file); } } @@ -459,7 +461,7 @@ void ModelManagerInterface::updateProjectInfo(const ProjectInfo &pinfo, ProjectE QMutexLocker locker(&m_mutex); oldInfo = m_projects.value(p); m_projects.insert(p, pinfo); - snapshot = _validSnapshot; + snapshot = m_validSnapshot; } if (oldInfo.qmlDumpPath != pinfo.qmlDumpPath @@ -551,8 +553,8 @@ void ModelManagerInterface::updateDocument(Document::Ptr doc) { { QMutexLocker locker(&m_mutex); - _validSnapshot.insert(doc); - _newestSnapshot.insert(doc, true); + m_validSnapshot.insert(doc); + m_newestSnapshot.insert(doc, true); } emit documentUpdated(doc); } @@ -564,8 +566,8 @@ void ModelManagerInterface::updateLibraryInfo(const QString &path, const Library { QMutexLocker locker(&m_mutex); - _validSnapshot.insertLibraryInfo(path, info); - _newestSnapshot.insertLibraryInfo(path, info); + m_validSnapshot.insertLibraryInfo(path, info); + m_newestSnapshot.insertLibraryInfo(path, info); } // only emit if we got new useful information if (info.isValid()) @@ -1013,7 +1015,7 @@ void ModelManagerInterface::updateImportPaths() // check if any file in the snapshot imports something new in the new paths - Snapshot snapshot = _validSnapshot; + Snapshot snapshot = m_validSnapshot; QStringList importedFiles; QSet<QString> scannedPaths; QSet<QString> newLibraries; @@ -1195,7 +1197,7 @@ LibraryInfo ModelManagerInterface::builtins(const Document::Ptr &doc) const if (!info.isValid()) return LibraryInfo(); - return _validSnapshot.libraryInfo(info.qtImportsPath); + return m_validSnapshot.libraryInfo(info.qtImportsPath); } ViewerContext ModelManagerInterface::completeVContext(const ViewerContext &vCtx, @@ -1241,12 +1243,12 @@ void ModelManagerInterface::resetCodeModel() QMutexLocker locker(&m_mutex); // find all documents currently in the code model - foreach (Document::Ptr doc, _validSnapshot) + foreach (Document::Ptr doc, m_validSnapshot) documents.append(doc->fileName()); // reset the snapshot - _validSnapshot = Snapshot(); - _newestSnapshot = Snapshot(); + m_validSnapshot = Snapshot(); + m_newestSnapshot = Snapshot(); } // start a reparse thread |