From 20a4488a6470af846e00f1792f9f2d944c129687 Mon Sep 17 00:00:00 2001 From: Benedikt Ziemons Date: Sun, 2 Jun 2024 02:08:55 +0200 Subject: [PATCH] Fix redraw not iterating backingIdx --- listview.lua | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/listview.lua b/listview.lua index 402af3d..15c1a8c 100644 --- a/listview.lua +++ b/listview.lua @@ -54,10 +54,13 @@ local function redraw() local tw, th = frame.getSize() local backingIdx = paginationOffset for idx = 1, th, 1 do - if backingList[backingIdx] ~= nil then - frame.setCursorPos(1, idx) + frame.setCursorPos(1, idx) + if backingList[backingIdx] == nil then + frame.clearLine() + else drawLine(frame, backingList[backingIdx]) end + backingIdx = backingIdx + 1 end end end