summaryrefslogtreecommitdiff
path: root/src/plugins/cpptools/editordocumenthandle.cpp
diff options
context:
space:
mode:
authorNikolai Kosjar <nikolai.kosjar@theqtcompany.com>2014-12-02 12:11:05 +0100
committerNikolai Kosjar <nikolai.kosjar@theqtcompany.com>2014-12-03 10:53:39 +0100
commitcb0d13692657d171e031d48c2879f8d8ce8e0e6a (patch)
tree263ef82a51f3d64bdbbe9bbcfdf852db4f7353e3 /src/plugins/cpptools/editordocumenthandle.cpp
parent9cd552a1656c04c1f3ccc92fefc62e2bd36fad37 (diff)
downloadqt-creator-cb0d13692657d171e031d48c2879f8d8ce8e0e6a.tar.gz
CppTools: Update document on activation
...if the project was updated in the meanwhile. If a project is updated mark invisible editor documents dirty and update them if they get focus. This also fixes document highlighting when restoring a session for documents that the user "switched away" before the project info is pushed to CppModelManager. This completes CppTools: Update visible documents on project update commit c2eb91e053332d010adc8b9e7918d9de28ef4c90 which only takes care of visible documents. Task-number: QTCREATORBUG-13270 Change-Id: Id445e7f509deac5d03194aecc54ce4629b7926ce Reviewed-by: Erik Verbruggen <erik.verbruggen@theqtcompany.com>
Diffstat (limited to 'src/plugins/cpptools/editordocumenthandle.cpp')
-rw-r--r--src/plugins/cpptools/editordocumenthandle.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/plugins/cpptools/editordocumenthandle.cpp b/src/plugins/cpptools/editordocumenthandle.cpp
index 58d93372ca..9e40aca5b2 100644
--- a/src/plugins/cpptools/editordocumenthandle.cpp
+++ b/src/plugins/cpptools/editordocumenthandle.cpp
@@ -40,6 +40,7 @@ namespace CppTools {
*/
EditorDocumentHandle::EditorDocumentHandle()
+ : m_needsRefresh(false)
{
}
@@ -47,4 +48,14 @@ EditorDocumentHandle::~EditorDocumentHandle()
{
}
+bool EditorDocumentHandle::needsRefresh() const
+{
+ return m_needsRefresh;
+}
+
+void EditorDocumentHandle::setNeedsRefresh(bool needsRefresh)
+{
+ m_needsRefresh = needsRefresh;
+}
+
} // namespace CppTools