mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-01-06 08:36:15 +00:00
Utilities: Add fix for 'less' not buffering the correct number of lines
'down_n()' now correctly buffers the needed number of lines, previously there were issues with using it to scroll much more than the existing buffer.
This commit is contained in:
committed by
Andreas Kling
parent
4e4d8d6905
commit
a071dba1ef
@@ -141,7 +141,7 @@ public:
|
||||
{
|
||||
clear_status();
|
||||
|
||||
while (n - (m_lines.size() - m_line) > 0) {
|
||||
while (n - (m_lines.size() - m_line) + m_height - 1 > 0) {
|
||||
if (!read_line())
|
||||
break;
|
||||
}
|
||||
@@ -158,8 +158,6 @@ public:
|
||||
|
||||
void bottom()
|
||||
{
|
||||
while (read_line())
|
||||
;
|
||||
down_n(m_lines.size() - m_line);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user