29 lines
493 B
Lua
29 lines
493 B
Lua
|
|
---@class BaseCell : LuaComponent
|
|
local BaseCell = class("BaseCell", LuaComponent)
|
|
|
|
function BaseCell:init()
|
|
end
|
|
|
|
function BaseCell:refresh(data)
|
|
end
|
|
|
|
function BaseCell:setIndex(index)
|
|
self.index = index
|
|
end
|
|
|
|
function BaseCell:getIndex()
|
|
return self.index
|
|
end
|
|
|
|
function BaseCell:getUIMap()
|
|
return self.baseObject:genAllChildren()
|
|
end
|
|
|
|
function BaseCell:addClickListener(callback)
|
|
if callback then
|
|
self.baseObject:addClickListener(callback)
|
|
end
|
|
end
|
|
|
|
return BaseCell |