From: Enlightenment S. <no-...@en...> - 2011-02-25 06:11:13
|
Log: elfe: merge two heads Author: captainigloo Date: 2011-02-24 22:11:03 -0800 (Thu, 24 Feb 2011) New Revision: 57315 Trac: http://trac.enlightenment.org/e/changeset/57315 Modified: trunk/E-MODULES-EXTRA/elfe/src/desktop.c trunk/E-MODULES-EXTRA/elfe/src/desktop.h trunk/E-MODULES-EXTRA/elfe/src/gadgets.c trunk/E-MODULES-EXTRA/elfe/src/gadgets.h trunk/E-MODULES-EXTRA/elfe/src/main.c Modified: trunk/E-MODULES-EXTRA/elfe/src/desktop.c =================================================================== --- trunk/E-MODULES-EXTRA/elfe/src/desktop.c 2011-02-24 22:45:00 UTC (rev 57314) +++ trunk/E-MODULES-EXTRA/elfe/src/desktop.c 2011-02-25 06:11:03 UTC (rev 57315) @@ -227,7 +227,7 @@ } Evas_Object * -elfe_desktop_add(Evas_Object *parent) +elfe_desktop_add(Evas_Object *parent, E_Zone *zone) { Evas_Object *tb, *pad, *bx, *ly; @@ -303,7 +303,7 @@ elm_box_pack_end(bx, tb); desktop_name = eina_stringshare_printf("Elfe Desktop %d", i); - gad = elfe_gadgets_zone_add(tb, i, desktop_name); + gad = elfe_gadgets_zone_add(tb, zone, i, desktop_name); evas_object_show(gad); desk->gadgets = eina_list_append(desk->gadgets, gad); Modified: trunk/E-MODULES-EXTRA/elfe/src/desktop.h =================================================================== --- trunk/E-MODULES-EXTRA/elfe/src/desktop.h 2011-02-24 22:45:00 UTC (rev 57314) +++ trunk/E-MODULES-EXTRA/elfe/src/desktop.h 2011-02-25 06:11:03 UTC (rev 57315) @@ -3,7 +3,7 @@ #include <Elementary.h> -Evas_Object *elfe_desktop_add(Evas_Object *parent); +Evas_Object *elfe_desktop_add(Evas_Object *parent, E_Zone *zone); Evas_Object *elfe_desktop_gadget_list(Evas_Object *obj); #endif /* _DESKTOP_H_ */ Modified: trunk/E-MODULES-EXTRA/elfe/src/gadgets.c =================================================================== --- trunk/E-MODULES-EXTRA/elfe/src/gadgets.c 2011-02-24 22:45:00 UTC (rev 57314) +++ trunk/E-MODULES-EXTRA/elfe/src/gadgets.c 2011-02-25 06:11:03 UTC (rev 57315) @@ -87,6 +87,8 @@ x = i*w; y = j*h; gcc = cc->func.init(egad->gc, cc->name, "test", cc->default_style); + gcc->cf = NULL; + gcc->client_class = cc; ly = _item_add(egad, ELFE_DESKTOP_ITEM_GADGET, cc->name, gcc->o_base, i, j, x, y, w, h); if (ly) { @@ -203,7 +205,7 @@ Evas_Object * -elfe_gadgets_zone_add(Evas_Object *parent, int desktop, const char *desktop_name) +elfe_gadgets_zone_add(Evas_Object *parent, E_Zone *zone, int desktop, const char *desktop_name) { const char *location_name; Elfe_Gadget *egad; @@ -262,6 +264,7 @@ egad->gc->frame_request.func = NULL; egad->gc->resize_request.func = NULL; egad->gc->min_size_request.func = NULL; + e_gadcon_zone_set(egad->gc, zone); e_gadcon_custom_new(egad->gc); /* Fill zone with config items*/ Modified: trunk/E-MODULES-EXTRA/elfe/src/gadgets.h =================================================================== --- trunk/E-MODULES-EXTRA/elfe/src/gadgets.h 2011-02-24 22:45:00 UTC (rev 57314) +++ trunk/E-MODULES-EXTRA/elfe/src/gadgets.h 2011-02-25 06:11:03 UTC (rev 57315) @@ -3,6 +3,6 @@ #include <Elementary.h> -Evas_Object *elfe_gadgets_zone_add(Evas_Object *parent, int desktop, const char *desktop_name); +Evas_Object *elfe_gadgets_zone_add(Evas_Object *parent, E_Zone *zone, int desktop, const char *desktop_name); void elfe_gadgets_gadget_add(Evas_Object *obj, E_Gadcon_Client_Class *gcc); #endif /* _GADGETS_H_ */ Modified: trunk/E-MODULES-EXTRA/elfe/src/main.c =================================================================== --- trunk/E-MODULES-EXTRA/elfe/src/main.c 2011-02-24 22:45:00 UTC (rev 57314) +++ trunk/E-MODULES-EXTRA/elfe/src/main.c 2011-02-25 06:11:03 UTC (rev 57315) @@ -372,7 +372,7 @@ evas_object_show(hwin->allapps); elm_layout_content_set(hwin->layout, "apps-list-swallow", hwin->allapps); - hwin->desktop = elfe_desktop_add(hwin->layout); + hwin->desktop = elfe_desktop_add(hwin->layout, hwin->zone); elm_layout_content_set(hwin->layout, "launcher.swallow", hwin->desktop); evas_object_smart_callback_add(hwin->desktop, "longpressed", _desktop_longpressed_cb, hwin); evas_object_smart_callback_add(hwin->desktop, "gadget,added", _gadget_added_cb, hwin); |