aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules/temperature/e_mod_main.c
diff options
context:
space:
mode:
authorHannes Janetzek <hannes.janetzek@gmail.com>2011-03-17 17:08:36 +0000
committerHannes Janetzek <hannes.janetzek@gmail.com>2011-03-17 17:08:36 +0000
commit7f457f191146c8ce1c2a8149a34a0ae037f2087a (patch)
tree2807173d45c7d2bb0d79fa9460ce41e1a123ddcb /src/modules/temperature/e_mod_main.c
parentSet v_mic to 99 (less than 256) to please OS X (diff)
downloadenlightenment-7f457f191146c8ce1c2a8149a34a0ae037f2087a.tar.gz
e17: add option to have gadcon client settings menu in toplevel again.
added e_menu_item_new_relative(E_Menu, E_Menu_Item *rel) which appends new item to rel or prepends it when rel is NULL. changed e_gadcon_util_client_menu_append to to take only the gadget menu and returns the new toplevel menu that should be shown by gcc depending on the setting this is a new menu with gadget menu as submenu or the gadet_menu with gadget menu items appended updated e-modules-extra comes in a minute SVN revision: 57826
Diffstat (limited to 'src/modules/temperature/e_mod_main.c')
-rw-r--r--src/modules/temperature/e_mod_main.c17
1 files changed, 7 insertions, 10 deletions
diff --git a/src/modules/temperature/e_mod_main.c b/src/modules/temperature/e_mod_main.c
index e55dce635..e46f73d81 100644
--- a/src/modules/temperature/e_mod_main.c
+++ b/src/modules/temperature/e_mod_main.c
@@ -217,26 +217,23 @@ _temperature_face_cb_mouse_down(void *data, Evas *e __UNUSED__, Evas_Object *obj
ev = event_info;
if ((ev->button == 3) && (!inst->menu))
{
- E_Menu *ma, *mg;
+ E_Menu *m;
E_Menu_Item *mi;
int cx, cy;
- ma = e_menu_new();
- e_menu_post_deactivate_callback_set(ma, _temperature_face_cb_post_menu, inst);
- inst->menu = ma;
-
- mg = e_menu_new();
-
- mi = e_menu_item_new(mg);
+ m = e_menu_new();
+ mi = e_menu_item_new(m);
e_menu_item_label_set(mi, _("Settings"));
e_util_menu_item_theme_icon_set(mi, "configure");
e_menu_item_callback_set(mi, _temperature_face_cb_menu_configure, inst);
- e_gadcon_client_util_menu_items_append(inst->gcc, ma, mg, 0);
+ m = e_gadcon_client_util_menu_items_append(inst->gcc, m, 0);
+ e_menu_post_deactivate_callback_set(m, _temperature_face_cb_post_menu, inst);
+ inst->menu = m;
e_gadcon_canvas_zone_geometry_get(inst->gcc->gadcon,
&cx, &cy, NULL, NULL);
- e_menu_activate_mouse(ma,
+ e_menu_activate_mouse(m,
e_util_zone_current_get(e_manager_current_get()),
cx + ev->output.x, cy + ev->output.y, 1, 1,
E_MENU_POP_DIRECTION_AUTO, ev->timestamp);