filepanel: Use edi_theme_icon_path_get.
Let's try to ensure our file panel will always display icons even if the installed system has no icon themes installed. I think this is the whole point of edi_theme_icon_path.. that we are able to provide a UI that looks "okay" without messing about with themes. People can do that themselves if they like but an empty app GUI might put people off...let's not do it. Again lovely icons from Faenza's author Mattieu James.
After Width: | Height: | Size: 7.5 KiB |
After Width: | Height: | Size: 7.5 KiB |
After Width: | Height: | Size: 3.1 KiB |
After Width: | Height: | Size: 2.0 KiB |
Before Width: | Height: | Size: 3.0 KiB After Width: | Height: | Size: 3.4 KiB |
Before Width: | Height: | Size: 1.8 KiB After Width: | Height: | Size: 662 B |
Before Width: | Height: | Size: 1.7 KiB After Width: | Height: | Size: 625 B |
After Width: | Height: | Size: 6.5 KiB |
|
@ -10,7 +10,10 @@ install_data(['document-new.png', 'window-close.png', 'window-close.png',
|
||||||
'object-flip-horizontal.png', 'object-flip-vertical.png',
|
'object-flip-horizontal.png', 'object-flip-vertical.png',
|
||||||
'edit-clear.png','applications-electronics.png', 'mail-send.png',
|
'edit-clear.png','applications-electronics.png', 'mail-send.png',
|
||||||
'dialog-error.png', 'go-home.png', 'network-server.png',
|
'dialog-error.png', 'go-home.png', 'network-server.png',
|
||||||
'edit-delete.png',
|
'edit-delete.png', 'text-x-generic.png', 'text-x-csrc.png',
|
||||||
|
'image-x-generic.png', 'empty.png',
|
||||||
|
'document-save-as.png', 'dialog-question.png', 'dialog-error.png',
|
||||||
|
'dialog-information.png',
|
||||||
],
|
],
|
||||||
install_dir: join_paths(get_option('prefix'), get_option('datadir'), 'edi', 'icons')
|
install_dir: join_paths(get_option('prefix'), get_option('datadir'), 'edi', 'icons')
|
||||||
)
|
)
|
||||||
|
|
After Width: | Height: | Size: 6.9 KiB |
After Width: | Height: | Size: 6.6 KiB |
|
@ -95,17 +95,17 @@ _icon_status(Edi_Scm_Status_Code code, Eina_Bool *staged)
|
||||||
*staged = EINA_TRUE;
|
*staged = EINA_TRUE;
|
||||||
return NULL;
|
return NULL;
|
||||||
case EDI_SCM_STATUS_ADDED:
|
case EDI_SCM_STATUS_ADDED:
|
||||||
return "document-new";
|
return edi_theme_icon_path_get("document-new");
|
||||||
case EDI_SCM_STATUS_ADDED_STAGED:
|
case EDI_SCM_STATUS_ADDED_STAGED:
|
||||||
*staged = EINA_TRUE;
|
*staged = EINA_TRUE;
|
||||||
return "document-new";
|
return edi_theme_icon_path_get("document-new");
|
||||||
case EDI_SCM_STATUS_MODIFIED:
|
case EDI_SCM_STATUS_MODIFIED:
|
||||||
return "document-save-as";
|
return edi_theme_icon_path_get("document-save-as");
|
||||||
case EDI_SCM_STATUS_MODIFIED_STAGED:
|
case EDI_SCM_STATUS_MODIFIED_STAGED:
|
||||||
*staged = EINA_TRUE;
|
*staged = EINA_TRUE;
|
||||||
return "document-save-as";
|
return edi_theme_icon_path_get("document-save-as");
|
||||||
case EDI_SCM_STATUS_UNTRACKED:
|
case EDI_SCM_STATUS_UNTRACKED:
|
||||||
return "dialog-question";
|
return edi_theme_icon_path_get("dialog-question");
|
||||||
}
|
}
|
||||||
|
|
||||||
return NULL;
|
return NULL;
|
||||||
|
@ -461,7 +461,7 @@ _item_menu_filetype_create(Evas_Object *menu, Elm_Object_Item *parent, const cha
|
||||||
if (!provider)
|
if (!provider)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
elm_menu_item_add(menu, parent, provider->icon, provider->id, func, sd);
|
elm_menu_item_add(menu, parent, edi_theme_icon_path_get(provider->icon), provider->id, func, sd);
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -722,9 +722,9 @@ _content_get(void *data, Evas_Object *obj, const char *source)
|
||||||
|
|
||||||
provider = _get_provider_from_hashset(sd->path);
|
provider = _get_provider_from_hashset(sd->path);
|
||||||
if (provider)
|
if (provider)
|
||||||
icon_name = provider->icon;
|
icon_name = edi_theme_icon_path_get(provider->icon);
|
||||||
else
|
else
|
||||||
icon_name = "empty";
|
icon_name = edi_theme_icon_path_get("empty");
|
||||||
|
|
||||||
box = elm_box_add(obj);
|
box = elm_box_add(obj);
|
||||||
elm_box_horizontal_set(box, EINA_TRUE);
|
elm_box_horizontal_set(box, EINA_TRUE);
|
||||||
|
@ -767,7 +767,7 @@ _content_get(void *data, Evas_Object *obj, const char *source)
|
||||||
if (staged)
|
if (staged)
|
||||||
{
|
{
|
||||||
ic = elm_icon_add(mbox);
|
ic = elm_icon_add(mbox);
|
||||||
elm_icon_standard_set(ic, "dialog-information");
|
elm_icon_standard_set(ic, edi_theme_icon_path_get("dialog-information"));
|
||||||
evas_object_size_hint_min_set(ic, ELM_SCALE_SIZE(16), ELM_SCALE_SIZE(16));
|
evas_object_size_hint_min_set(ic, ELM_SCALE_SIZE(16), ELM_SCALE_SIZE(16));
|
||||||
evas_object_show(ic);
|
evas_object_show(ic);
|
||||||
elm_box_pack_end(rbox, ic);
|
elm_box_pack_end(rbox, ic);
|
||||||
|
@ -777,7 +777,7 @@ _content_get(void *data, Evas_Object *obj, const char *source)
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
ic = elm_icon_add(mbox);
|
ic = elm_icon_add(mbox);
|
||||||
elm_icon_standard_set(ic, "dialog-error");
|
elm_icon_standard_set(ic, edi_theme_icon_path_get("dialog-error"));
|
||||||
evas_object_size_hint_min_set(ic, ELM_SCALE_SIZE(16), ELM_SCALE_SIZE(16));
|
evas_object_size_hint_min_set(ic, ELM_SCALE_SIZE(16), ELM_SCALE_SIZE(16));
|
||||||
evas_object_show(ic);
|
evas_object_show(ic);
|
||||||
elm_box_pack_end(rbox, ic);
|
elm_box_pack_end(rbox, ic);
|
||||||
|
|