gengrid: fix serach items in genlist by text

If a part name is NULL get text for search from TEXT part 'elm.text".

@fix
This commit is contained in:
Vyacheslav Reutskiy 2017-01-26 10:54:30 +02:00
parent f958921177
commit d37de735eb
2 changed files with 2 additions and 2 deletions

View File

@ -398,7 +398,7 @@ _elm_gengrid_search_by_text_item_get(Eo *obj EINA_UNUSED,
{
if (!it->itc->func.text_get) continue;
str = it->itc->func.text_get((void *)WIDGET_ITEM_DATA_GET(EO_OBJ(it)),
WIDGET(it), part_name);
WIDGET(it), part_name ? part_name : "elm.text");
if (!str) continue;
if (!fnmatch(pattern, str, fnflags))
{

View File

@ -518,7 +518,7 @@ class Elm.Gengrid (Elm.Layout, Elm.Interface_Scrollable,
Pointer to item to start search from. If $null, search will
be started from the first item of the gengrid.
]]
@in part_name: string; [[Name of the TEXT part of gengrid item to search string in.]]
@in part_name: string; [[Name of the TEXT part of gengrid item to search string in. If $null, search by "elm.text" parts.]]
@in pattern: string; [[The search pattern.]]
@in flags: Elm.Glob.Match_Flags; [[Search flags.]]
}