1 #ifndef _ELM_MENU_EO_LEGACY_H_
2 #define _ELM_MENU_EO_LEGACY_H_
3 
4 #ifndef _ELM_MENU_EO_CLASS_TYPE
5 #define _ELM_MENU_EO_CLASS_TYPE
6 
7 typedef Eo Elm_Menu;
8 
9 #endif
10 
11 #ifndef _ELM_MENU_EO_TYPES
12 #define _ELM_MENU_EO_TYPES
13 
14 
15 #endif
16 
17 /**
18  * @brief Get the selected item in the widget.
19  *
20  * @param[in] obj The object.
21  *
22  * @return The selected item or @c null.
23  *
24  * @ingroup Elm_Menu_Group
25  */
26 EAPI Elm_Widget_Item *elm_menu_selected_item_get(const Elm_Menu *obj);
27 
28 /**
29  * @brief Get the first item in the widget.
30  *
31  * @param[in] obj The object.
32  *
33  * @return The first item or @c null.
34  *
35  * @ingroup Elm_Menu_Group
36  */
37 EAPI Elm_Widget_Item *elm_menu_first_item_get(const Elm_Menu *obj);
38 
39 /**
40  * @brief Get the last item in the widget.
41  *
42  * @param[in] obj The object.
43  *
44  * @return The last item or @c null.
45  *
46  * @ingroup Elm_Menu_Group
47  */
48 EAPI Elm_Widget_Item *elm_menu_last_item_get(const Elm_Menu *obj);
49 
50 /**
51  * @brief Returns a list of the widget item.
52  *
53  * @param[in] obj The object.
54  *
55  * @return const list to widget items
56  *
57  * @ingroup Elm_Menu_Group
58  */
59 EAPI const Eina_List *elm_menu_items_get(const Elm_Menu *obj);
60 
61 /**
62  * @brief Move the menu to a new position
63  *
64  * Sets the top-left position of the menu to ($x, @c y).
65  *
66  * @note @c x and @c y coordinates are relative to parent.
67  *
68  * @param[in] obj The object.
69  * @param[in] x The new X coordinate
70  * @param[in] y The new Y coordinate
71  *
72  * @ingroup Elm_Menu_Group
73  */
74 EAPI void elm_menu_move(Elm_Menu *obj, int x, int y);
75 
76 /**
77  * @brief Add an item at the end of the given menu widget.
78  *
79  * @note This function does not accept relative icon path.
80  *
81  * @param[in] obj The object.
82  * @param[in] parent The parent menu item (optional).
83  * @param[in] icon An icon display on the item. The icon will be destroyed by
84  * the menu.
85  * @param[in] label The label of the item.
86  * @param[in] func Function called when the user select the item.
87  * @param[in] data Data sent by the callback.
88  *
89  * @return The new menu item.
90  *
91  * @ingroup Elm_Menu_Group
92  */
93 EAPI Elm_Widget_Item *elm_menu_item_add(Elm_Menu *obj, Elm_Widget_Item *parent, const char *icon, const char *label, Evas_Smart_Cb func, const void *data);
94 
95 /**
96  * @brief Open a closed menu
97  *
98  * Show the menu with no child sub-menus expanded..
99  * @param[in] obj The object.
100  *
101  * @ingroup Elm_Menu_Group
102  */
103 EAPI void elm_menu_open(Elm_Menu *obj);
104 
105 /**
106  * @brief Close a opened menu
107  *
108  * Hides the menu and all it's sub-menus.
109  * @param[in] obj The object.
110  *
111  * @ingroup Elm_Menu_Group
112  */
113 EAPI void elm_menu_close(Elm_Menu *obj);
114 
115 /**
116  * @brief Add a separator item to menu @c obj under @c parent.
117  *
118  * @param[in] obj The object.
119  * @param[in] parent The item to add the separator under.
120  *
121  * @return The created item or @c null.
122  *
123  * @ingroup Elm_Menu_Group
124  */
125 EAPI Elm_Widget_Item *elm_menu_item_separator_add(Elm_Menu *obj, Elm_Widget_Item *parent);
126 
127 #endif
128