TextEditor: move setIfdefedOutBlocks to TextDocument

The location of the blocks to marked ifdefed out are not tied to a
specific editor instance, but just depend on the document content.

Change-Id: I837730dc00e1d6060dd46bbb2cfccbfa5f72e6ce
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
David Schulz
2021-12-03 11:19:59 +01:00
parent 76024f6fcc
commit 7552c9958f
6 changed files with 61 additions and 61 deletions

View File

@@ -670,7 +670,7 @@ void CppEditorWidget::onIfdefedOutBlocksUpdated(unsigned revision,
{
if (revision != documentRevision())
return;
setIfdefedOutBlocks(ifdefedOutBlocks);
textDocument()->setIfdefedOutBlocks(ifdefedOutBlocks);
}
void CppEditorWidget::onShowInfoBarAction(const Id &id, bool show)