forked from enlightenment/enlightenment
Modules can use module.desktop instead of module.eap now. module.edj is
also currently supported for those too lazy to write a .desktop, just rename your module.eap. SVN revision: 25332
This commit is contained in:
parent
0a4101f9ea
commit
816872b607
|
@ -372,10 +372,35 @@ e_module_dialog_show(E_Module *m, const char *title, const char *body)
|
|||
|
||||
e_dialog_title_set(dia, title);
|
||||
if (m)
|
||||
{
|
||||
/* Lots of fallbacks coz we are in a transition period, and the modules are still suffering from the last API change. */
|
||||
snprintf(eap, sizeof(eap), "%s/module.desktop", e_module_dir_get(m));
|
||||
if (ecore_file_exists(eap))
|
||||
{
|
||||
EAPI E_App *app;
|
||||
|
||||
app = e_app_new(eap, 0);
|
||||
if (app)
|
||||
{
|
||||
dia->icon_object = e_app_icon_add(e_win_evas_get(dia->win), app);
|
||||
edje_extern_object_min_size_set(dia->icon_object, 64, 64);
|
||||
edje_object_part_swallow(dia->bg_object, "icon_swallow", dia->icon_object);
|
||||
evas_object_show(dia->icon_object);
|
||||
e_object_unref(E_OBJECT(app));
|
||||
}
|
||||
}
|
||||
else /* FIXME: Remove the fallbacks when everything in cvs is converted. B-) */
|
||||
{
|
||||
snprintf(eap, sizeof(eap), "%s/module.edj", e_module_dir_get(m));
|
||||
if (ecore_file_exists(eap))
|
||||
_e_module_dialog_icon_set(dia, eap);
|
||||
else
|
||||
{
|
||||
snprintf(eap, sizeof(eap), "%s/module.eap", e_module_dir_get(m));
|
||||
_e_module_dialog_icon_set(dia, eap);
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
e_dialog_icon_set(dia, "enlightenment/modules", 64);
|
||||
|
||||
|
|
Loading…
Reference in New Issue