summaryrefslogtreecommitdiff
path: root/src/plugins/cppeditor/fileandtokenactions_test.cpp
diff options
context:
space:
mode:
authorhjk <hjk121@nokiamail.com>2014-05-07 16:25:04 +0200
committerhjk <hjk121@nokiamail.com>2014-05-13 11:48:30 +0200
commit6e584b5b4953b996ef07c4625adf178c59de24f7 (patch)
tree2af702c76bf5323c331154b553aacbe5523592f5 /src/plugins/cppeditor/fileandtokenactions_test.cpp
parent226c1abc89888fa2f272d92c466725fd6dad65db (diff)
downloadqt-creator-6e584b5b4953b996ef07c4625adf178c59de24f7.tar.gz
DocumentModel: Make interface static
Move item model implementation to private, adjust user code. Change-Id: Ifbe94e7c7b9b1e8be1b4c531958dbd7a9413af13 Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Diffstat (limited to 'src/plugins/cppeditor/fileandtokenactions_test.cpp')
-rw-r--r--src/plugins/cppeditor/fileandtokenactions_test.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/plugins/cppeditor/fileandtokenactions_test.cpp b/src/plugins/cppeditor/fileandtokenactions_test.cpp
index a5e6601a32..2cc10c1359 100644
--- a/src/plugins/cppeditor/fileandtokenactions_test.cpp
+++ b/src/plugins/cppeditor/fileandtokenactions_test.cpp
@@ -183,12 +183,12 @@ TestActionsTestCase::TestActionsTestCase(const Actions &tokenActions, const Acti
undoAllChangesAndCloseAllEditors();
// Open editor
- QCOMPARE(EditorManager::documentModel()->openedDocuments().size(), 0);
+ QCOMPARE(DocumentModel::openedDocuments().size(), 0);
CPPEditor *editor;
CPPEditorWidget *editorWidget;
QVERIFY(openCppEditor(filePath, &editor, &editorWidget));
- QCOMPARE(EditorManager::documentModel()->openedDocuments().size(), 1);
+ QCOMPARE(DocumentModel::openedDocuments().size(), 1);
QVERIFY(m_modelManager->isCppEditor(editor));
QVERIFY(m_modelManager->workingCopy().contains(filePath));
@@ -268,7 +268,7 @@ void TestActionsTestCase::undoChangesInDocument(BaseTextDocument *editorDocument
void TestActionsTestCase::undoChangesInAllEditorWidgets()
{
- foreach (IDocument *document, EditorManager::documentModel()->openedDocuments()) {
+ foreach (IDocument *document, DocumentModel::openedDocuments()) {
BaseTextDocument *baseTextDocument = qobject_cast<BaseTextDocument *>(document);
undoChangesInDocument(baseTextDocument);
}
@@ -309,7 +309,7 @@ void TestActionsTestCase::undoAllChangesAndCloseAllEditors()
undoChangesInAllEditorWidgets();
EditorManager::closeAllEditors(/*askAboutModifiedEditors =*/ false);
QApplication::processEvents();
- QCOMPARE(EditorManager::documentModel()->openedDocuments().size(), 0);
+ QCOMPARE(DocumentModel::openedDocuments().size(), 0);
}
void TestActionsTestCase::configureAllProjects(const QList<QPointer<ProjectExplorer::Project> >