Skip to content
Snippets Groups Projects
Commit fdb2eb25 authored by dg's avatar dg
Browse files

fix

git-svn-id: http://svn.net-core.org/repos/t-engine4@2936 51575b47-30f0-44d4-a5cc-537603b46e54
parent 17c84a1c
No related branches found
No related tags found
No related merge requests found
......@@ -128,6 +128,13 @@ function _M:generate()
self:onSelect()
end
function _M:select(i)
if self.sel and self.list[self.sel] then self.list[self.sel].focus_decay = self.focus_decay_max end
self.sel = util.bound(i, 1, #self.list)
self.scroll = util.scroll(self.sel, self.scroll, self.max_display)
self:onSelect()
end
function _M:onSelect()
local item = self.list[self.sel]
if not item then return end
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment