diff options
author | Nikolai Kosjar <nikolai.kosjar@theqtcompany.com> | 2015-07-10 12:34:40 +0200 |
---|---|---|
committer | Nikolai Kosjar <nikolai.kosjar@theqtcompany.com> | 2015-07-10 14:04:14 +0000 |
commit | 5902a622985158eda3f47bc98d8c4d4c80426eba (patch) | |
tree | 8ea781e7d3e631a7133df90880608de03842e13e /src/plugins/cpptools/baseeditordocumentparser.h | |
parent | 442bdbded2b2268efcb3be1a969d432533023366 (diff) | |
download | qt-creator-5902a622985158eda3f47bc98d8c4d4c80426eba.tar.gz |
CppTools: Let BaseEditorDocumentParser acquire the mutex
...so derived classes are freed from doing this.
Change-Id: I73f3eca54be14cfd6542a466f0e9c024457bef07
Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
Diffstat (limited to 'src/plugins/cpptools/baseeditordocumentparser.h')
-rw-r--r-- | src/plugins/cpptools/baseeditordocumentparser.h | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/src/plugins/cpptools/baseeditordocumentparser.h b/src/plugins/cpptools/baseeditordocumentparser.h index 42ce6c12b3..c5a1974811 100644 --- a/src/plugins/cpptools/baseeditordocumentparser.h +++ b/src/plugins/cpptools/baseeditordocumentparser.h @@ -56,11 +56,10 @@ public: virtual ~BaseEditorDocumentParser(); QString filePath() const; - Configuration configuration() const; void setConfiguration(const Configuration &configuration); - virtual void update(WorkingCopy workingCopy) = 0; + void update(WorkingCopy workingCopy); ProjectPart::Ptr projectPart() const; @@ -69,7 +68,6 @@ protected: QByteArray editorDefines; ProjectPart::Ptr projectPart; }; - State state() const; void setState(const State &state); @@ -77,14 +75,15 @@ protected: const Configuration &config, const State &state); - mutable QMutex m_updateIsRunning; mutable QMutex m_stateAndConfigurationMutex; private: - const QString m_filePath; + virtual void updateHelper(WorkingCopy workingCopy) = 0; + const QString m_filePath; Configuration m_configuration; State m_state; + mutable QMutex m_updateIsRunning; }; } // namespace CppTools |