Lines Matching full:item
50 * @brief Represents one item of the context menu object.
53 Ewk_Context_Menu_Item_Type type; /**< contains the type of the item */
54 Ewk_Context_Menu_Action action; /**< contains the action of the item */
56 const char* title; /**< contains the title of the item */
57 Ewk_Context_Menu* submenu; /**< contains the pointer to the submenu of the item */
84 void* item;
89 EINA_LIST_FREE(menu->items, item)
90 ewk_context_menu_item_free(static_cast<Ewk_Context_Menu_Item*>(item));
129 * Creates a new item of the context menu.
131 * @param type specifies a type of the item
132 * @param action specifies a action of the item
133 * @param submenu specifies a submenu of the item
134 * @param title specifies a title of the item
136 * @param enabled @c EINA_TRUE to enable the item or @c EINA_FALSE to disable
137 * @return the pointer to the new item on success or @c 0 on failure
145 Ewk_Context_Menu_Item* item = (Ewk_Context_Menu_Item*) malloc(sizeof(*item));
146 if (!item)
149 item->type = type;
150 item->action = action;
151 item->title = eina_stringshare_add(title);
152 item->submenu = submenu;
153 item->checked = checked;
154 item->enabled = enabled;
156 return item;
160 * Selects the item from the context menu object.
163 * @param item the item is selected
166 Eina_Bool ewk_context_menu_item_select(Ewk_Context_Menu* menu, Ewk_Context_Menu_Item* item)
170 EINA_SAFETY_ON_NULL_RETURN_VAL(item, EINA_FALSE);
171 WebCore::ContextMenuAction action = static_cast<WebCore::ContextMenuAction>(item->action);
172 WebCore::ContextMenuItemType type = static_cast<WebCore::ContextMenuItemType>(item->type);
184 * Destroys the item of the context menu object.
186 * @param item the item to destroy
191 void ewk_context_menu_item_free(Ewk_Context_Menu_Item* item)
193 EINA_SAFETY_ON_NULL_RETURN(item);
195 eina_stringshare_del(item->title);
196 free(item);
200 * Gets type of the item.
202 * @param o the item to get the type
203 * @return type of the item on success or @c EWK_ACTION_TYPE on failure
214 * Sets the type of item.
216 * @param o the item to set the type
217 * @param type a new type for the item object
230 * Gets an action of the item.
232 * @param o the item to get the action
233 * @return an action of the item on success or @c EWK_CONTEXT_MENU_ITEM_TAG_NO_ACTION on failure
244 * Sets an action of the item.
246 * @param o the item to set the action
247 * @param action a new action for the item object
260 * Gets a title of the item.
262 * @param o the item to get the title
263 * @return a title of the item on success, or @c 0 on failure
274 * Sets a title of the item.
276 * @param o the item to set the title
277 * @param title a new title for the item object
278 * @return a new title of the item on success or @c 0 on failure
303 * Gets if the item is enabled.
305 * @param o the item to get enabled state
317 * Enables/disables the item.
319 * @param o the item to enable/disable
320 * @param enabled @c EINA_TRUE to enable the item or @c EINA_FALSE to disable
392 * Appends the WebCore's item to the context menu object.
395 * @param core the WebCore's context menu item that will be added to the context menu
396 * @note emits a signal "contextmenu,item,appended"
411 evas_object_smart_callback_call(o->view, "contextmenu,item,appended", o);