Correct issue of triple clicking and scrolling up.

Fixes selecting text by triple click and scrolling up causes only the
visible contents to be selected.

Thanks to Shlomi Fish (shlomif@iglu.org.il) for research and patch.

BUG: 256353
REVIEW: 103724
FIXED-IN: 4.9
This commit is contained in:
Kurt Hindenburg
2012-01-28 11:26:57 -05:00
parent 19d7990b12
commit 6d9d49aafb

View File

@@ -128,7 +128,7 @@ void ScreenWindow::getSelectionEnd(int& column , int& line)
}
void ScreenWindow::setSelectionStart(int column , int line , bool columnMode)
{
_screen->setSelectionStart(column , qMin(line + currentLine(), endWindowLine()) , columnMode);
_screen->setSelectionStart(column , line + currentLine() , columnMode);
_bufferNeedsUpdate = true;
emit selectionChanged();
@@ -136,7 +136,7 @@ void ScreenWindow::setSelectionStart(int column , int line , bool columnMode)
void ScreenWindow::setSelectionEnd(int column , int line)
{
_screen->setSelectionEnd(column , qMin(line + currentLine(), endWindowLine()));
_screen->setSelectionEnd(column , line + currentLine());
_bufferNeedsUpdate = true;
emit selectionChanged();