Fix requests pagination onTouch, wrong itemAt usage

This commit is contained in:
Ben 2024-06-02 14:46:28 +02:00
parent 0cb62033ef
commit 35a5aeabb8
Signed by: ben
GPG key ID: 0F54A7ED232D3319

View file

@ -94,7 +94,7 @@ end
local function onTouch(self, touch_x, touch_y)
local tw, th = self.window.getSize()
if touch_x > tw-5 then
local obj = listview.itemAt(touch_y)
local obj = listview.itemAt(touch_y+self.scrollPos-1)
if obj ~= nil and obj.answer ~= nil then
if permset.has(allowed_items, obj.answer.name) then
permset.remove(allowed_items, obj.answer.name)