diff options
author | Eike Ziller <eike.ziller@qt.io> | 2018-05-28 11:05:37 +0200 |
---|---|---|
committer | Eike Ziller <eike.ziller@qt.io> | 2018-05-28 13:45:20 +0000 |
commit | 6e66b2a078c53c3c2ce18578acfd346274213762 (patch) | |
tree | f775c74fcf1a149654ac51e2084259bae81ea621 /src/plugins/coreplugin/editormanager | |
parent | 8d9942300f715a4b9355062c3b709698ec6ea1f1 (diff) | |
download | qt-creator-6e66b2a078c53c3c2ce18578acfd346274213762.tar.gz |
Remove some lambdas from Utils::transform calls
It is often possible to user (member) functions or members directly.
That improves readablility and potentially reduces the total number of
symbols.
Also use qobject_container_cast at places where it is appropriate.
Change-Id: Ia2591bca356591e001e2c53eeebcf753e5bc3c37
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
Reviewed-by: hjk <hjk@qt.io>
Diffstat (limited to 'src/plugins/coreplugin/editormanager')
-rw-r--r-- | src/plugins/coreplugin/editormanager/editormanager.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/coreplugin/editormanager/editormanager.cpp b/src/plugins/coreplugin/editormanager/editormanager.cpp index da0772dc44..4671f17422 100644 --- a/src/plugins/coreplugin/editormanager/editormanager.cpp +++ b/src/plugins/coreplugin/editormanager/editormanager.cpp @@ -2210,7 +2210,7 @@ void EditorManagerPrivate::autoSuspendDocuments() return; auto visibleDocuments = Utils::transform<QSet>(EditorManager::visibleEditors(), - [](IEditor *editor) { return editor->document(); }); + &IEditor::document); int keptEditorCount = 0; QList<IDocument *> documentsToSuspend; foreach (const EditLocation &editLocation, d->m_globalHistory) { |