-- EFL LuaJIT bindings: elm_hoversel.eo (class Elm.Hoversel)
-- 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_class_get()
    eo.class_register("Elm_Hoversel", {"Elm_Button"}, {"Efl_Ui_Selectable", "Efl_Ui_Clickable", "Elm_Interface_Atspi_Widget_Action"}, __body, __class)
end

cutil.init_module(init, function() end)

ffi.cdef [[
    const Eo_Class *elm_hoversel_class_get(void);
    void elm_obj_hoversel_horizontal_set(Eina_Bool horizontal);
    Eina_Bool elm_obj_hoversel_horizontal_get(void);
    void elm_obj_hoversel_hover_parent_set(Efl_Canvas_Object * parent);
    Efl_Canvas_Object *elm_obj_hoversel_hover_parent_get(void);
    Eina_Bool elm_obj_hoversel_expanded_get(void);
    const Eina_List *elm_obj_hoversel_items_get(void);
    void elm_obj_hoversel_auto_update_set(Eina_Bool auto_update);
    Eina_Bool elm_obj_hoversel_auto_update_get(void);
    void elm_obj_hoversel_hover_begin(void);
    void elm_obj_hoversel_clear(void);
    void elm_obj_hoversel_hover_end(void);
    Elm_Widget_Item *elm_obj_hoversel_item_add(const char * label, const char * icon_file, Elm_Icon_Type icon_type, Evas_Smart_Cb func, const void * data);
    extern const Eo_Event_Description _ELM_HOVERSEL_EVENT_DISMISSED;
    extern const Eo_Event_Description _ELM_HOVERSEL_EVENT_EXPANDED;
    extern const Eo_Event_Description _ELM_HOVERSEL_EVENT_ITEM_FOCUSED;
    extern const Eo_Event_Description _ELM_HOVERSEL_EVENT_ITEM_UNFOCUSED;
]]

__body = {
    __eo_ctor = function(self, __func)
        if __func then __func() end
    end,

    horizontal_set = function(self, horizontal)
        eo.__do_start(self, __class)
        __lib.elm_obj_hoversel_horizontal_set(horizontal)
        eo.__do_end()
    end,

    horizontal_get = function(self)
        eo.__do_start(self, __class)
        local v = __lib.elm_obj_hoversel_horizontal_get()
        eo.__do_end()
        return ((v) ~= 0)
    end,

    hover_parent_set = function(self, parent)
        eo.__do_start(self, __class)
        __lib.elm_obj_hoversel_hover_parent_set(parent)
        eo.__do_end()
    end,

    hover_parent_get = function(self)
        eo.__do_start(self, __class)
        local v = __lib.elm_obj_hoversel_hover_parent_get()
        eo.__do_end()
        return v
    end,

    expanded_get = function(self)
        eo.__do_start(self, __class)
        local v = __lib.elm_obj_hoversel_expanded_get()
        eo.__do_end()
    end,

    items_get = function(self)
        eo.__do_start(self, __class)
        local v = __lib.elm_obj_hoversel_items_get()
        eo.__do_end()
    end,

    auto_update_set = function(self, auto_update)
        eo.__do_start(self, __class)
        __lib.elm_obj_hoversel_auto_update_set(auto_update)
        eo.__do_end()
    end,

    auto_update_get = function(self)
        eo.__do_start(self, __class)
        local v = __lib.elm_obj_hoversel_auto_update_get()
        eo.__do_end()
        return ((v) ~= 0)
    end,

    hover_begin = function(self)
        eo.__do_start(self, __class)
        __lib.elm_obj_hoversel_hover_begin()
        eo.__do_end()
    end,

    clear = function(self)
        eo.__do_start(self, __class)
        __lib.elm_obj_hoversel_clear()
        eo.__do_end()
    end,

    hover_end = function(self)
        eo.__do_start(self, __class)
        __lib.elm_obj_hoversel_hover_end()
        eo.__do_end()
    end,

    item_add = function(self, label, icon_file, icon_type, func, data)
        eo.__do_start(self, __class)
        local v = __lib.elm_obj_hoversel_item_add(label, icon_file, icon_type, func, data)
        eo.__do_end()
        return v
    end,

    __events = {
        ["dismissed"] = __lib._ELM_HOVERSEL_EVENT_DISMISSED,
        ["expanded"] = __lib._ELM_HOVERSEL_EVENT_EXPANDED,
        ["item,focused"] = __lib._ELM_HOVERSEL_EVENT_ITEM_FOCUSED,
        ["item,unfocused"] = __lib._ELM_HOVERSEL_EVENT_ITEM_UNFOCUSED
    },

    __properties = {
        ["expanded"] = { 0, 0, 1, 0, true, false },
        ["items"] = { 0, 0, 1, 0, true, false },
        ["horizontal"] = { 0, 0, 1, 1, true, true },
        ["auto_update"] = { 0, 0, 1, 1, true, true },
        ["hover_parent"] = { 0, 0, 1, 1, true, true }
    }
}

M.Hoversel = function(parent, ...)
    return eo.__ctor_common(__class, parent, eo.class_get("Elm_Hoversel").__eo_ctor,
                            1, ...)
end

return M
