aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/copilot
diff options
context:
space:
mode:
authorDavid Schulz <[email protected]>2025-03-19 12:47:21 +0100
committerDavid Schulz <[email protected]>2025-04-01 06:23:01 +0000
commit6256484385238ad0eae6bab413dd11048b07c6c1 (patch)
treedcc46518f510c47685eab6cd90d83a658ad373ac /src/plugins/copilot
parent24f13b90290e81129352056ff3296a7ff9366d24 (diff)
Editor: move block related infos out of the layout
All the static TextDocumentLayout functions operating on block user data are not related to the TextDocumentLayout. So move them to the TextBlockUserData and replace the member functions there with the static functions from TextDocumentLayout. Change-Id: Ief34a0dfce5917f064e5d06e661f2111f87f0aa7 Reviewed-by: Christian Stenger <[email protected]>
Diffstat (limited to 'src/plugins/copilot')
-rw-r--r--src/plugins/copilot/copilotplugin.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/copilot/copilotplugin.cpp b/src/plugins/copilot/copilotplugin.cpp
index 077331655f8..231a149a30c 100644
--- a/src/plugins/copilot/copilotplugin.cpp
+++ b/src/plugins/copilot/copilotplugin.cpp
@@ -35,7 +35,7 @@ static void cycleSuggestion(TextEditor::TextEditorWidget *editor, Direction dire
{
QTextBlock block = editor->textCursor().block();
if (auto suggestion = dynamic_cast<TextEditor::CyclicSuggestion *>(
- TextEditor::TextDocumentLayout::suggestion(block))) {
+ TextEditor::TextBlockUserData::suggestion(block))) {
int index = suggestion->currentSuggestion();
if (direction == Previous)
--index;