TextEditor: always return a valid assist interface

It is required for updating currently visible proposals. Also guard
against potential null assist interfaces.

Amends 0bd6d7a69f

Fixes: QTCREATORBUG-29096
Change-Id: Ic34d70561b471e7e529f2fb7c239b49712aca502
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
David Schulz
2023-04-28 14:04:50 +02:00
parent 8aecf0d749
commit ba5e09f03f
4 changed files with 16 additions and 18 deletions

View File

@@ -1042,7 +1042,7 @@ std::unique_ptr<AssistInterface> QmlJSEditorWidget::createAssistInterface(
return std::make_unique<Internal::QmlJSQuickFixAssistInterface>(
const_cast<QmlJSEditorWidget *>(this), reason);
}
return nullptr;
return TextEditorWidget::createAssistInterface(assistKind, reason);
}
QString QmlJSEditorWidget::foldReplacementText(const QTextBlock &block) const