Fix display tab methods using static offset
This commit is contained in:
parent
6c54f462db
commit
2a0176888a
|
@ -35,7 +35,7 @@ local function displayTab(self)
|
||||||
local tw,th = self.window.getSize()
|
local tw,th = self.window.getSize()
|
||||||
for i, val in pairs(orders) do
|
for i, val in pairs(orders) do
|
||||||
local line_num = (i-self.scrollPos)*2+1
|
local line_num = (i-self.scrollPos)*2+1
|
||||||
if line_num > 2 and line_num < th-1 then
|
if line_num > 0 and line_num < th-1 then
|
||||||
self.window.setTextColor(colors.lightGray)
|
self.window.setTextColor(colors.lightGray)
|
||||||
self.window.setCursorPos(1,line_num)
|
self.window.setCursorPos(1,line_num)
|
||||||
self.window.write(val.id)
|
self.window.write(val.id)
|
||||||
|
|
|
@ -51,7 +51,7 @@ local function displayTab(self)
|
||||||
display_list = {}
|
display_list = {}
|
||||||
for i, val in pairs(requests) do
|
for i, val in pairs(requests) do
|
||||||
local line_num = i-self.scrollPos+1
|
local line_num = i-self.scrollPos+1
|
||||||
if line_num > 2 and line_num < th then
|
if line_num > 0 and line_num < th then
|
||||||
self.window.setTextColor(colors.white)
|
self.window.setTextColor(colors.white)
|
||||||
self.window.setCursorPos(1,line_num)
|
self.window.setCursorPos(1,line_num)
|
||||||
self.window.write(val.req.name)
|
self.window.write(val.req.name)
|
||||||
|
|
Loading…
Reference in a new issue