feat(TerminalDisplay): Copy to X11 selection immediately on mouse release

This commit is contained in:
owan wang
2025-03-12 07:37:55 +08:00
parent bd5ed3d424
commit 3c2f1bec91

View File

@@ -1517,6 +1517,7 @@ void TerminalDisplay::mouseReleaseEvent(QMouseEvent *ev)
clearSelection();
} else {
if (_actSel > 1) {
copyToX11Selection();
if (_possibleTripleClick) {
const QString text = _screenWindow->selectedText(currentDecodingOptions());
if (!text.isEmpty()) {
@@ -1525,8 +1526,6 @@ void TerminalDisplay::mouseReleaseEvent(QMouseEvent *ev)
_doubleClickSelectedHtml = _screenWindow->selectedText(currentDecodingOptions() | Screen::ConvertToHtml);
}
}
} else {
copyToX11Selection();
}
}