aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMiculcy Brian <morlenxus@gmx.net>2013-01-29 16:33:16 +0000
committerMiculcy Brian <morlenxus@gmx.net>2013-01-29 16:33:16 +0000
commitbb375592d32465b3125f3c133d17659b9c73fef8 (patch)
tree743feebcce2bbc8b71711a0cd4898db81d476174
parentchlog (diff)
downloadenlightenment-bb375592d32465b3125f3c133d17659b9c73fef8.tar.gz
IBar fixes when using other sources than 'default'.
SVN revision: 83442
-rw-r--r--ChangeLog3
-rw-r--r--NEWS1
-rw-r--r--src/modules/ibar/e_mod_main.c49
3 files changed, 34 insertions, 19 deletions
diff --git a/ChangeLog b/ChangeLog
index 6c271fc73..68b7f49c6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,6 @@
+2013-01-29 Brian Miculcy
+ * IBar fixes when using other sources than 'default'.
+
2013-01-29 Carsten Haitzler
* fix map then unmap race condition for borders
diff --git a/NEWS b/NEWS
index 62c044c22..0f1f223d9 100644
--- a/NEWS
+++ b/NEWS
@@ -76,6 +76,7 @@ Improvements:
* add support for AltGr in illume2's E_Kbd_Buf_Key, fix related leak
Fixes:
+ * IBar fixes when using other sources than 'default'.
* Shelf option 'overlapping' made clearer and disabled when window automatic movement on shelf hide isn't set.
* Backlight, screenlock and screensaver don't check for fullscreen windows - we have presentation mode for that.
* Force check changed upon confirmation dialog closure for engine settings.
diff --git a/src/modules/ibar/e_mod_main.c b/src/modules/ibar/e_mod_main.c
index 1e87a72c9..8f75b2471 100644
--- a/src/modules/ibar/e_mod_main.c
+++ b/src/modules/ibar/e_mod_main.c
@@ -376,6 +376,26 @@ _ibar_cb_empty_mouse_down(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNU
if (ev->button != 3) return;
m = e_menu_new();
+
+ if (e_configure_registry_exists("applications/new_application"))
+ {
+ mi = e_menu_item_new(m);
+ e_menu_item_label_set(mi, _("Create new Icon"));
+ e_util_menu_item_theme_icon_set(mi, "document-new");
+ e_menu_item_callback_set(mi, _ibar_cb_menu_icon_new, NULL);
+
+ mi = e_menu_item_new(m);
+ e_menu_item_separator_set(mi, 1);
+ }
+
+ if (e_configure_registry_exists("applications/ibar_applications"))
+ {
+ mi = e_menu_item_new(m);
+ e_menu_item_label_set(mi, _("Contents"));
+ e_util_menu_item_theme_icon_set(mi, "list-add");
+ e_menu_item_callback_set(mi, _ibar_cb_menu_icon_add, b);
+ }
+
mi = e_menu_item_new(m);
e_menu_item_label_set(mi, _("Settings"));
e_util_menu_item_theme_icon_set(mi, "configure");
@@ -730,13 +750,17 @@ _ibar_cb_menu_icon_new(void *data __UNUSED__, E_Menu *m __UNUSED__, E_Menu_Item
}
static void
-_ibar_cb_menu_icon_add(void *data __UNUSED__, E_Menu *m __UNUSED__, E_Menu_Item *mi __UNUSED__)
+_ibar_cb_menu_icon_add(void *data, E_Menu *m __UNUSED__, E_Menu_Item *mi __UNUSED__)
{
- E_Container *con;
+ char path[PATH_MAX];
+ IBar *b;
- if (!e_configure_registry_exists("applications/ibar_applications")) return;
- con = e_container_current_get(e_manager_current_get());
- e_configure_registry_call("applications/ibar_applications", con, NULL);
+ b = data;
+ e_user_dir_snprintf(path, sizeof(path), "applications/bar/%s/.order",
+ b->inst->ci->dir);
+ e_configure_registry_call("internal/ibar_other",
+ e_container_current_get(e_manager_current_get()),
+ path);
}
static void
@@ -772,19 +796,6 @@ _ibar_cb_menu_configuration(void *data, E_Menu *m __UNUSED__, E_Menu_Item *mi __
_config_ibar_module(b->inst->ci);
}
-/*
- static void
- _ibar_cb_menu_add(void *data, E_Menu *m __UNUSED__, E_Menu_Item *mi __UNUSED__)
- {
- IBar *b;
-
- b = data;
- e_configure_registry_call("internal/ibar_other",
- b->inst->gcc->gadcon->zone->container,
- b->io->eo->path);
- }
- */
-
static void
_ibar_cb_icon_mouse_in(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUSED__, void *event_info __UNUSED__)
{
@@ -858,7 +869,7 @@ _ibar_cb_icon_mouse_down(void *data, Evas *e __UNUSED__, Evas_Object *obj __UNUS
mi = e_menu_item_new(m);
e_menu_item_label_set(mi, _("Contents"));
e_util_menu_item_theme_icon_set(mi, "list-add");
- e_menu_item_callback_set(mi, _ibar_cb_menu_icon_add, NULL);
+ e_menu_item_callback_set(mi, _ibar_cb_menu_icon_add, ic->ibar);
}
mi = e_menu_item_new(m);