Add signal emit hook to gengrid.

Like was already done to other widgets by bdilly, this patch adds the
possibility to send signals to elm_gengrid's theme.

P.S: lfelipe, ahi esta mi primer commit :P



SVN revision: 52109
This commit is contained in:
Rafael Fonseca 2010-09-09 22:01:30 +00:00
parent 139985f471
commit 9c4eb78705
1 changed files with 10 additions and 0 deletions

View File

@ -227,6 +227,15 @@ _del_hook(Evas_Object *obj)
free(wd);
}
static void
_signal_emit_hook(Evas_Object *obj, const char *emission, const char *source)
{
Widget_Data *wd = elm_widget_data_get(obj);
if (!wd) return;
edje_object_signal_emit(elm_smart_scroller_edje_object_get(wd->scr),
emission, source);
}
static void
_mouse_move(void *data, Evas *evas __UNUSED__, Evas_Object *obj, void *event_info)
{
@ -935,6 +944,7 @@ elm_gengrid_add(Evas_Object *parent)
elm_widget_data_set(obj, wd);
elm_widget_del_hook_set(obj, _del_hook);
elm_widget_theme_hook_set(obj, _theme_hook);
elm_widget_signal_emit_hook_set(obj, _signal_emit_hook);
wd->scr = elm_smart_scroller_add(e);
elm_smart_scroller_widget_set(wd->scr, obj);