-- EFL LuaJIT bindings: elm_hoversel_item.eo (class Elm.Hoversel.Item)
-- For use with Elua; automatically generated, do not modify

local cutil = require("cutil")
local util  = require("util")
local ffi   = require("ffi")
local eo    = require("eo")

local M, __lib = ...

local __class
local __body

local init = function()
    __class = __lib.elm_hoversel_item_class_get()
    eo.class_register("Elm_Hoversel_Item", {"Elm_Widget_Item"}, nil, __body, __class)
end

cutil.init_module(init, function() end)

ffi.cdef [[
    const Eo_Class *elm_hoversel_item_class_get(void);
    void elm_obj_hoversel_item_icon_set(const char * icon_file, const char * icon_group, Elm_Icon_Type icon_type);
    void elm_obj_hoversel_item_icon_get(const char * *icon_file, const char * *icon_group, Elm_Icon_Type *icon_type);
]]

local __M = util.get_namespace(M, { "hoversel" })
__body = {
    __eo_ctor = function(self, __func)
        if __func then __func() end
    end,

    icon_set = function(self, icon_file, icon_group, icon_type)
        eo.__do_start(self, __class)
        __lib.elm_obj_hoversel_item_icon_set(icon_file, icon_group, icon_type)
        eo.__do_end()
    end,

    icon_get = function(self)
        eo.__do_start(self, __class)
        local icon_file = ffi.new("const char *[1]")
        local icon_group = ffi.new("const char *[1]")
        local icon_type = ffi.new("Elm_Icon_Type[1]")
        __lib.elm_obj_hoversel_item_icon_get(icon_file, icon_group, icon_type)
        eo.__do_end()
        return icon_file[0], icon_group[0], icon_type[0]
    end,

    __properties = {
        ["icon"] = { 0, 0, 3, 3, true, true }
    }
}

__M.Item = function(parent, ...)
    return eo.__ctor_common(__class, parent, eo.class_get("Elm_Hoversel_Item").__eo_ctor,
                            1, ...)
end

return M
