diff --git a/TODO b/TODO index fff672b67..0a714ae73 100644 --- a/TODO +++ b/TODO @@ -52,7 +52,6 @@ Some of the things (in very short form) that need to be done to E17... ------------------------------------------------------------------------------- * actions to make current zone different (warp mouse to there) -* titlebar/border expansion/gadget panel for modules to put window widgets in * language packs: need to have a tool to load/setup a language pack (which means .mo compiled files from a .po, an optional font and a config file that specifies the locale and font) and then install the font(s) either as a user @@ -62,8 +61,6 @@ Some of the things (in very short form) that need to be done to E17... * add a "taskbar" module * add cpu load module * add a way to access "all" apps app dir -* ibar need to support label pop-ups -* ibar should support subdirs with pop-up icons... * add setup/install wizard to seed eap files etc. etc. * support text and color classes * add clientinfo pane/popdown for borders @@ -72,11 +69,8 @@ Some of the things (in very short form) that need to be done to E17... * make it possible to disable border buttons/actions (tell theme what is disabled) * shelf gui config is ugly and badly arranged -* shelf needs a way to register a menu item appender for right click menu for - gadcon items * pager should be able to be configured to control more than the current zone (select which zone they control) -* ibar maybe should move bar dirs to subdirectories in "bar" to limit scope * ibar should support creating and deleting bar dirs ]]] diff --git a/data/other/applications.tar.gz b/data/other/applications.tar.gz index f987c0962..6b55a49a4 100644 Binary files a/data/other/applications.tar.gz and b/data/other/applications.tar.gz differ diff --git a/data/themes/default_ibar.edc b/data/themes/default_ibar.edc index e35bddddd..63113304e 100644 --- a/data/themes/default_ibar.edc +++ b/data/themes/default_ibar.edc @@ -194,6 +194,32 @@ group { color: 0 0 0 0; } } + part { + name: "label"; + type: TEXT; + effect: SOFT_SHADOW; + mouse_events: 0; + description { + state: "default" 0.0; + align: 0.5 0.5; + color: 255 255 255 0; + color3: 0 0 0 0; + text { + text: "Icon Name"; + font: "Edje-Vera-Bold"; + size: 10; + min: 1 1; + align: 0.5 0.5; + text_class: "module_normal"; + } + } + description { + state: "visible" 0.0; + inherit: "default" 0.0; + color: 255 255 255 255; + color3: 0 0 0 42; + } + } } programs { program { @@ -204,6 +230,14 @@ group { target: "background"; after: "go_active2"; } + program { + name: "go_activeB"; + signal: "label_active"; + source: ""; + action: STATE_SET "visible" 0.0; + transition: SINUSOIDAL 1.0; + target: "label"; + } program { name: "go_active2"; signal: ""; @@ -222,6 +256,14 @@ group { target: "go_active2"; after: "go_passive2"; } + program { + name: "go_passiveB"; + signal: "label_passive"; + source: ""; + action: STATE_SET "default" 0.0; + transition: SINUSOIDAL 2.0; + target: "label"; + } program { name: "go_passive2"; signal: ""; diff --git a/src/bin/e_int_config_display.c b/src/bin/e_int_config_display.c index 3d9e1c009..37cb2fc01 100644 --- a/src/bin/e_int_config_display.c +++ b/src/bin/e_int_config_display.c @@ -242,23 +242,36 @@ _basic_apply_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *cfdata) man = e_manager_current_get(); sizes = ecore_x_randr_screen_sizes_get(man->root, &n); - for (i = 0; i < n; i++) + if (!sizes) { - if ((sizes[i].width == w) && - (sizes[i].height == h)) + e_util_dialog_show(_("Missing Features"), + _("Your X Display Server is missing support for
" + "The XRandr (X Resize and Rotate) extension.
" + "You cannot change screen resolutions without
" + "The support of this extension. It could also be
" + "That at the time ecore was built there
" + "was no XRandr support detected.")); + } + else + { + for (i = 0; i < n; i++) { - size = sizes[i]; - int k, rr; - rates = ecore_x_randr_screen_refresh_rates_get(man->root, i, &rr); - for (k = 0; k < rr; k++) + if ((sizes[i].width == w) && + (sizes[i].height == h)) { - if (rates[k].rate == r) + size = sizes[i]; + int k, rr; + rates = ecore_x_randr_screen_refresh_rates_get(man->root, i, &rr); + for (k = 0; k < rr; k++) { - rate = rates[k]; - break; - } + if (rates[k].rate == r) + { + rate = rates[k]; + break; + } + } + break; } - break; } } diff --git a/src/bin/e_main.c b/src/bin/e_main.c index a40c96a05..2fa3519ec 100644 --- a/src/bin/e_main.c +++ b/src/bin/e_main.c @@ -806,6 +806,7 @@ _e_main_dirs_init(void) "%s/.e/e/applications/all", "%s/.e/e/applications/favorite", "%s/.e/e/applications/bar", + "%s/.e/e/applications/bar/default", "%s/.e/e/applications/startup", "%s/.e/e/applications/restart", "%s/.e/e/applications/trash", @@ -835,7 +836,7 @@ _e_main_dirs_init(void) /* err dont just disable it - replace it with a proper wizard tool */ /* outside e's main source to populate these directories from gnome/kde */ /* app menu data etc. */ - snprintf(buf, sizeof(buf), "%s/.e/e/applications/bar/.order", homedir); + snprintf(buf, sizeof(buf), "%s/.e/e/applications/bar/default/.order", homedir); if (!ecore_file_exists(buf)) { snprintf(buf, sizeof(buf), diff --git a/src/bin/e_shelf.c b/src/bin/e_shelf.c index 7b45c9ad9..8f8423f45 100644 --- a/src/bin/e_shelf.c +++ b/src/bin/e_shelf.c @@ -724,6 +724,16 @@ _e_shelf_cb_menu_edit(void *data, E_Menu *m, E_Menu_Item *mi) e_gadcon_edit_begin(es->gadcon); } +static void +_e_shelf_cb_menu_contents(void *data, E_Menu *m, E_Menu_Item *mi) +{ + E_Shelf *es; + + es = data; + if (!es->gadcon->config_dialog) + e_int_gadcon_config(es->gadcon); +} + static void _e_shelf_cb_menu_post(void *data, E_Menu *m) { @@ -766,6 +776,11 @@ _e_shelf_cb_mouse_down(void *data, Evas *evas, Evas_Object *obj, void *event_inf e_util_menu_item_edje_icon_set(mi, "enlightenment/edit"); e_menu_item_callback_set(mi, _e_shelf_cb_menu_edit, es); + mi = e_menu_item_new(mn); + e_menu_item_label_set(mi, _("Configure Contents")); + e_util_menu_item_edje_icon_set(mi, "enlightenment/config"); + e_menu_item_callback_set(mi, _e_shelf_cb_menu_contents, es); + e_gadcon_canvas_zone_geometry_get(es->gadcon, &cx, &cy, &cw, &ch); e_menu_activate_mouse(mn, e_util_zone_current_get(e_manager_current_get()), diff --git a/src/modules/ibar/e_mod_config.c b/src/modules/ibar/e_mod_config.c index 6d71bb12d..fb93b91c0 100644 --- a/src/modules/ibar/e_mod_config.c +++ b/src/modules/ibar/e_mod_config.c @@ -7,6 +7,7 @@ struct _E_Config_Dialog_Data { char *dir; + int show_label; }; /* Protos */ @@ -46,6 +47,7 @@ _fill_data(Config_Item *ci, E_Config_Dialog_Data *cfdata) cfdata->dir = strdup(ci->dir); else cfdata->dir = strdup(""); + cfdata->show_label = ci->show_label; } static void * @@ -71,19 +73,21 @@ _free_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *cfdata) static Evas_Object * _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cfdata) { - Evas_Object *o, *of, *ol; + Evas_Object *o, *of, *ol, *ob; Ecore_List *dirs; char *home, buf[4096], *file; int selnum = -1; - o = e_widget_framelist_add(evas, _("Selected Bar Source"), 0); + o = e_widget_list_add(evas, 0, 0); + + of = e_widget_framelist_add(evas, _("Selected Bar Source"), 0); ol = e_widget_tlist_add(evas, &(cfdata->dir)); - e_widget_min_size_set(ol, 160, 200); - e_widget_framelist_object_append(o, ol); + e_widget_min_size_set(ol, 160, 160); + e_widget_framelist_object_append(of, ol); home = e_user_homedir_get(); - snprintf(buf, sizeof(buf), "%s/.e/e/applications", home); + snprintf(buf, sizeof(buf), "%s/.e/e/applications/bar", home); dirs = ecore_file_ls(buf); if (dirs) @@ -94,7 +98,7 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf while ((file = ecore_list_next(dirs))) { if (file[0] == '.') continue; - snprintf(buf, sizeof(buf), "%s/.e/e/applications/%s", home, file); + snprintf(buf, sizeof(buf), "%s/.e/e/applications/bar/%s", home, file); if (ecore_file_is_dir(buf)) { e_widget_tlist_append(ol, file, NULL, NULL, file); @@ -109,6 +113,12 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf e_widget_tlist_go(ol); if (selnum >= 0) e_widget_tlist_selected_set(ol, selnum); + + e_widget_list_object_append(o, of, 1, 1, 0.5); + + ob = e_widget_check_add(evas, _("Show Icon Label"), &(cfdata->show_label)); + e_widget_list_object_append(o, ob, 1, 1, 0.5); + return o; } @@ -121,6 +131,7 @@ _basic_apply_data(E_Config_Dialog *cfd, E_Config_Dialog_Data *cfdata) if (ci->dir) evas_stringshare_del(ci->dir); ci->dir = NULL; if (cfdata->dir) ci->dir = evas_stringshare_add(cfdata->dir); + ci->show_label = cfdata->show_label; _ibar_config_update(); e_config_save_queue(); return 1; diff --git a/src/modules/ibar/e_mod_main.c b/src/modules/ibar/e_mod_main.c index 6c161bf18..ff64d765c 100644 --- a/src/modules/ibar/e_mod_main.c +++ b/src/modules/ibar/e_mod_main.c @@ -53,6 +53,7 @@ struct _IBar int drop_before; E_App *apps; Evas_List *icons; + int show_label; }; struct _IBar_Icon @@ -126,9 +127,10 @@ _gc_init(E_Gadcon *gc, char *name, char *id, char *style) inst = E_NEW(Instance, 1); ci = _ibar_config_item_get(id); - if (!ci->dir) ci->dir = evas_stringshare_add("bar"); + if (!ci->dir) ci->dir = evas_stringshare_add("default"); inst->dir = evas_stringshare_add(ci->dir); b = _ibar_new(gc->evas, ci->dir); + b->show_label = ci->show_label; b->inst = inst; inst->ibar = b; o = b->o_box; @@ -249,7 +251,7 @@ _ibar_new(Evas *evas, char *dir) homedir = e_user_homedir_get(); if (homedir) { - snprintf(buf, sizeof(buf), "%s/.e/e/applications/%s", homedir, dir); + snprintf(buf, sizeof(buf), "%s/.e/e/applications/bar/%s", homedir, dir); free(homedir); } } @@ -281,6 +283,7 @@ _ibar_fill(IBar *b) Evas_List *l; E_App *a; + if (!b->apps) return; for (l = b->apps->subapps; l; l = l->next) { a = l->data; @@ -360,6 +363,7 @@ _ibar_config_item_get(char *id) } ci = E_NEW(Config_Item, 1); ci->id = evas_stringshare_add(id); + ci->show_label = 1; ibar_config->items = evas_list_append(ibar_config->items, ci); return ci; } @@ -403,6 +407,7 @@ _ibar_config_update(void) _ibar_resize_handle(inst->ibar); _gc_orient(inst->gcc); } + inst->ibar->show_label = ci->show_label; } } @@ -450,6 +455,7 @@ _ibar_icon_new(IBar *b, E_App *a) ic->o_holder = edje_object_add(evas_object_evas_get(b->o_box)); e_theme_edje_object_set(ic->o_holder, "base/theme/modules/ibar", "modules/ibar/icon"); + edje_object_part_text_set(ic->o_holder, "label", a->name); evas_object_event_callback_add(ic->o_holder, EVAS_CALLBACK_MOUSE_IN, _ibar_cb_icon_mouse_in, ic); evas_object_event_callback_add(ic->o_holder, EVAS_CALLBACK_MOUSE_OUT, _ibar_cb_icon_mouse_out, ic); evas_object_event_callback_add(ic->o_holder, EVAS_CALLBACK_MOUSE_DOWN, _ibar_cb_icon_mouse_down, ic); @@ -462,6 +468,7 @@ _ibar_icon_new(IBar *b, E_App *a) ic->o_holder2 = edje_object_add(evas_object_evas_get(b->o_box)); e_theme_edje_object_set(ic->o_holder2, "base/theme/modules/ibar", "modules/ibar/icon_overlay"); + edje_object_part_text_set(ic->o_holder2, "label", a->name); evas_object_layer_set(ic->o_holder2, 9999); evas_object_pass_events_set(ic->o_holder2, 1); evas_object_show(ic->o_holder2); @@ -710,6 +717,8 @@ _ibar_cb_icon_mouse_in(void *data, Evas *e, Evas_Object *obj, void *event_info) ev = event_info; ic = data; _ibar_icon_signal_emit(ic, "active", ""); + if (ic->ibar->show_label) + _ibar_icon_signal_emit(ic, "label_active", ""); } static void @@ -721,6 +730,8 @@ _ibar_cb_icon_mouse_out(void *data, Evas *e, Evas_Object *obj, void *event_info) ev = event_info; ic = data; _ibar_icon_signal_emit(ic, "passive", ""); + if (ic->ibar->show_label) + _ibar_icon_signal_emit(ic, "label_passive", ""); } static void @@ -1137,6 +1148,7 @@ e_modapi_init(E_Module *m) #define D conf_item_edd E_CONFIG_VAL(D, T, id, STR); E_CONFIG_VAL(D, T, dir, STR); + E_CONFIG_VAL(D, T, show_label, INT); conf_edd = E_CONFIG_DD_NEW("IBar_Config", Config); #undef T @@ -1155,7 +1167,8 @@ e_modapi_init(E_Module *m) ci = E_NEW(Config_Item, 1); ci->id = evas_stringshare_add("0"); - ci->dir = evas_stringshare_add("bar"); + ci->dir = evas_stringshare_add("default"); + ci->show_label = 1; ibar_config->items = evas_list_append(ibar_config->items, ci); } diff --git a/src/modules/ibar/e_mod_main.h b/src/modules/ibar/e_mod_main.h index b9d30b9b9..33bc580a6 100644 --- a/src/modules/ibar/e_mod_main.h +++ b/src/modules/ibar/e_mod_main.h @@ -23,6 +23,7 @@ struct _Config_Item { char *id; char *dir; + int show_label; }; EAPI extern E_Module_Api e_modapi;