Editor: Collect keyboard selections to the clipboard

Fixes: QTCREATORBUG-26492
Change-Id: I36c3ae73d8d5b2ea92cee3fd7c568b958c3235ae
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
David Schulz
2021-10-29 11:03:01 +02:00
parent 17a545115b
commit d5467917d0

View File

@@ -1572,6 +1572,7 @@ void TextEditorWidgetPrivate::slotSelectionChanged()
m_selectBlockAnchor = QTextCursor();
// Clear any link which might be showing when the selection changes
clearLink();
setClipboardSelection();
}
void TextEditorWidget::gotoBlockStart()
@@ -5244,7 +5245,6 @@ void TextEditorWidget::mouseReleaseEvent(QMouseEvent *e)
return;
QPlainTextEdit::mouseReleaseEvent(e);
d->setClipboardSelection();
}
void TextEditorWidget::mouseDoubleClickEvent(QMouseEvent *e)
@@ -5259,7 +5259,6 @@ void TextEditorWidget::mouseDoubleClickEvent(QMouseEvent *e)
}
QPlainTextEdit::mouseDoubleClickEvent(e);
d->setClipboardSelection();
}
void TextEditorWidgetPrivate::setClipboardSelection()