efl.ui.image: fix icon_get API
If icon set is failed, icon_get should return NULL, not the old icon name. @fix
This commit is contained in:
parent
67a91ddd5f
commit
5882d343f0
|
@ -1704,6 +1704,8 @@ _internal_efl_ui_image_icon_set(Evas_Object *obj, const char *name, Eina_Bool *f
|
||||||
_efl_ui_image_sizing_eval(obj);
|
_efl_ui_image_sizing_eval(obj);
|
||||||
return EINA_TRUE;
|
return EINA_TRUE;
|
||||||
}
|
}
|
||||||
|
else
|
||||||
|
eina_stringshare_replace(&sd->stdicon, NULL);
|
||||||
|
|
||||||
if (_path_is_absolute(name))
|
if (_path_is_absolute(name))
|
||||||
{
|
{
|
||||||
|
|
|
@ -197,7 +197,7 @@ START_TEST (efl_ui_image_icon)
|
||||||
ok = efl_ui_image_icon_set(image, "None");
|
ok = efl_ui_image_icon_set(image, "None");
|
||||||
ck_assert(ok == 0);
|
ck_assert(ok == 0);
|
||||||
icon_name = efl_ui_image_icon_get(image);
|
icon_name = efl_ui_image_icon_get(image);
|
||||||
ck_assert_str_eq(icon_name, NULL);
|
ck_assert(icon_name == NULL);
|
||||||
|
|
||||||
elm_run();
|
elm_run();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue