summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Dransfeld <sd@tango.flipp.net>2010-12-09 13:15:57 +0000
committerSebastian Dransfeld <sd@tango.flipp.net>2010-12-09 13:15:57 +0000
commit12cada2f42fd7393312ddee4228dfc8e973a69cb (patch)
tree7e82b1eeec847452b526a26f44bff0aea1178de2
parent79534e3bdb71e90d8ad941a1d1795504139f1e40 (diff)
Revert clock change and fix theme
eventarea must be visible for users to click, alpha 0 makes the user not see it. SVN revision: 55412
-rw-r--r--src/modules/clock/e_mod_main.c26
1 files changed, 1 insertions, 25 deletions
diff --git a/src/modules/clock/e_mod_main.c b/src/modules/clock/e_mod_main.c
index 31da6fe08..efaa921f0 100644
--- a/src/modules/clock/e_mod_main.c
+++ b/src/modules/clock/e_mod_main.c
@@ -9,8 +9,6 @@ static char *_gc_label(E_Gadcon_Client_Class *client_class);
9static Evas_Object *_gc_icon(E_Gadcon_Client_Class *client_class, Evas *evas); 9static Evas_Object *_gc_icon(E_Gadcon_Client_Class *client_class, Evas *evas);
10static const char *_gc_id_new(E_Gadcon_Client_Class *client_class); 10static const char *_gc_id_new(E_Gadcon_Client_Class *client_class);
11 11
12static void _clock_cb_obj_moveresize(void *data, Evas *e, Evas_Object *obj, void *event_info);
13
14/* and actually define the gadcon class that this module provides (just 1) */ 12/* and actually define the gadcon class that this module provides (just 1) */
15static const E_Gadcon_Client_Class _gadcon_class = 13static const E_Gadcon_Client_Class _gadcon_class =
16{ 14{
@@ -29,7 +27,6 @@ struct _Instance
29{ 27{
30 E_Gadcon_Client *gcc; 28 E_Gadcon_Client *gcc;
31 Evas_Object *o_clock; 29 Evas_Object *o_clock;
32 Evas_Object *o_event;
33}; 30};
34 31
35static E_Module *clock_module = NULL; 32static E_Module *clock_module = NULL;
@@ -47,20 +44,12 @@ _gc_init(E_Gadcon *gc, const char *name, const char *id, const char *style)
47 e_theme_edje_object_set(o, "base/theme/modules/clock", 44 e_theme_edje_object_set(o, "base/theme/modules/clock",
48 "e/modules/clock/main"); 45 "e/modules/clock/main");
49 evas_object_show(o); 46 evas_object_show(o);
50 inst->o_clock = o;
51 o = evas_object_rectangle_add(gc->evas);
52 evas_object_color_set(o, 0, 0, 0, 0);
53 inst->o_event = o;
54 evas_object_event_callback_add(o, EVAS_CALLBACK_MOVE,
55 _clock_cb_obj_moveresize, inst);
56 evas_object_event_callback_add(o, EVAS_CALLBACK_RESIZE,
57 _clock_cb_obj_moveresize, inst);
58 evas_object_show(o);
59 47
60 gcc = e_gadcon_client_new(gc, name, id, style, o); 48 gcc = e_gadcon_client_new(gc, name, id, style, o);
61 gcc->data = inst; 49 gcc->data = inst;
62 50
63 inst->gcc = gcc; 51 inst->gcc = gcc;
52 inst->o_clock = o;
64 53
65 e_gadcon_client_util_menu_attach(gcc); 54 e_gadcon_client_util_menu_attach(gcc);
66 55
@@ -74,7 +63,6 @@ _gc_shutdown(E_Gadcon_Client *gcc)
74 63
75 inst = gcc->data; 64 inst = gcc->data;
76 evas_object_del(inst->o_clock); 65 evas_object_del(inst->o_clock);
77 evas_object_del(inst->o_event);
78 free(inst); 66 free(inst);
79} 67}
80 68
@@ -148,15 +136,3 @@ e_modapi_save(E_Module *m __UNUSED__)
148{ 136{
149 return 1; 137 return 1;
150} 138}
151
152static void
153_clock_cb_obj_moveresize(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
154{
155 Evas_Coord x, y, w, h;
156 Instance *inst;
157
158 inst = data;
159 evas_object_geometry_get(inst->o_event, &x, &y, &w, &h);
160 evas_object_move(inst->o_clock, x, y);
161 evas_object_resize(inst->o_clock, w, h);
162}