forked from enlightenment/efl
fix fixme in elm_toolbar_item_menu_get: no longer modifies a toolbar item
SVN revision: 63756
This commit is contained in:
parent
e4e61d12c0
commit
5bc9d81812
|
@ -14847,7 +14847,7 @@ extern "C" {
|
||||||
*
|
*
|
||||||
* @ingroup Toolbar
|
* @ingroup Toolbar
|
||||||
*/
|
*/
|
||||||
EAPI Evas_Object *elm_toolbar_item_menu_get(Elm_Toolbar_Item *item) EINA_ARG_NONNULL(1);
|
EAPI Evas_Object *elm_toolbar_item_menu_get(const Elm_Toolbar_Item *item) EINA_ARG_NONNULL(1);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Add a new state to @p item.
|
* Add a new state to @p item.
|
||||||
|
|
|
@ -1755,14 +1755,11 @@ elm_toolbar_item_cursor_engine_only_get(const Elm_Toolbar_Item *item)
|
||||||
}
|
}
|
||||||
|
|
||||||
EAPI Evas_Object *
|
EAPI Evas_Object *
|
||||||
elm_toolbar_item_menu_get(Elm_Toolbar_Item *item)
|
elm_toolbar_item_menu_get(const Elm_Toolbar_Item *item)
|
||||||
{
|
{
|
||||||
ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item, NULL);
|
ELM_WIDGET_ITEM_WIDTYPE_CHECK_OR_RETURN(item, NULL);
|
||||||
Widget_Data *wd = elm_widget_data_get(item->base.widget);
|
Widget_Data *wd = elm_widget_data_get(item->base.widget);
|
||||||
if (!wd) return NULL;
|
if ((!wd) || (!item->menu)) return NULL;
|
||||||
/* FIXME: It's not ok. This function needs to be reviewed. And should
|
|
||||||
* receive a const item */
|
|
||||||
elm_toolbar_item_menu_set(item, 1);
|
|
||||||
return item->o_menu;
|
return item->o_menu;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue