DocumentModel: Make interface static

Move item model implementation to private, adjust user code.

Change-Id: Ifbe94e7c7b9b1e8be1b4c531958dbd7a9413af13
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
This commit is contained in:
hjk
2014-05-07 16:25:04 +02:00
parent 226c1abc89
commit 6e584b5b49
41 changed files with 259 additions and 246 deletions

View File

@@ -1083,7 +1083,7 @@ bool QmakePriFileNode::priFileWritable(const QString &path)
bool QmakePriFileNode::saveModifiedEditors()
{
Core::IDocument *document
= Core::EditorManager::documentModel()->documentForFilePath(m_projectFilePath);
= Core::DocumentModel::documentForFilePath(m_projectFilePath);
if (!document || !document->isModified())
return true;
@@ -1250,7 +1250,7 @@ void QmakePriFileNode::save(const QStringList &lines)
// We manually tell each editor to reload it's file.
// (The .pro files are notified by the file system watcher.)
QStringList errorStrings;
Core::IDocument *document = Core::EditorManager::documentModel()->documentForFilePath(m_projectFilePath);
Core::IDocument *document = Core::DocumentModel::documentForFilePath(m_projectFilePath);
if (document) {
QString errorString;
if (!document->reload(&errorString, Core::IDocument::FlagReload, Core::IDocument::TypeContents))