Commit e2167eb0 authored by Glenn Coombs's avatar Glenn Coombs Committed by Kurt Hindenburg
Browse files

Preserve double/triple click mode when extending the selection

Summary:
When extending the selection using the mouse the double or triple click
mode that initiated the selection should be preserved.  If the user double
clicked to select a word, then extending the selection should extend
"word at a time" rather than "character at a time". Similarly if the user
triple clicked to select a whole line initially, then extending the selection
should extend "line at a time" rather than "character at a time".

BUG: 374454
FIXED-IN: 18.12

Reviewers: #konsole, hindenburg

Reviewed By: #konsole, hindenburg

Subscribers: konsole-devel

Tags: #konsole

Differential Revision: https://phabricator.kde.org/D16660
parent 7dbcfdf1
......@@ -2309,8 +2309,10 @@ void TerminalDisplay::mousePressEvent(QMouseEvent* ev)
}
}
_lineSelectionMode = false;
_wordSelectionMode = false;
if (!ev->modifiers()) {
_lineSelectionMode = false;
_wordSelectionMode = false;
}
// The user clicked inside selected text
bool selected = _screenWindow->isSelected(pos.x(), pos.y());
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment