Incorrect array index calculation in case of scrolling only part of the
screen (as vim does for instance). Should fix #2382 and #2386. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@25973 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -1116,7 +1116,7 @@ BasicTerminalBuffer::_Scroll(int32 top, int32 bottom, int32 numLines)
|
|||||||
// lines).
|
// lines).
|
||||||
for (int32 i = bottom + 1; i < fHeight; i++) {
|
for (int32 i = bottom + 1; i < fHeight; i++) {
|
||||||
std::swap(fScreen[_LineIndex(i)],
|
std::swap(fScreen[_LineIndex(i)],
|
||||||
fScreen[_LineIndex(i) + numLines]);
|
fScreen[_LineIndex(i + numLines)]);
|
||||||
}
|
}
|
||||||
|
|
||||||
// update the screen offset and clear the new lines
|
// update the screen offset and clear the new lines
|
||||||
|
|||||||
Reference in New Issue
Block a user