Moved 'Startup' and 'Restart' app calls from the Appearance->Startup screen
to their own 'Applications' section in config panel as they were difficult for users to find. SVN revision: 27319
This commit is contained in:
parent
c50e449cbe
commit
c3ffa11082
|
@ -401,6 +401,10 @@ _e_configure_fill_cat_list(void *data)
|
||||||
_e_configure_item_add(cat, _("Transitions"), "enlightenment/transitions", e_int_config_transitions);
|
_e_configure_item_add(cat, _("Transitions"), "enlightenment/transitions", e_int_config_transitions);
|
||||||
_e_configure_item_add(cat, _("Startup"), "enlightenment/startup", e_int_config_startup);
|
_e_configure_item_add(cat, _("Startup"), "enlightenment/startup", e_int_config_startup);
|
||||||
|
|
||||||
|
cat = _e_configure_category_add(eco, _("Applications"), "enlightenment/applications");
|
||||||
|
_e_configure_item_add(cat, _("Restart Applications"), "enlightenment/applications", e_int_config_apps_restart);
|
||||||
|
_e_configure_item_add(cat, _("Startup Applications"), "enlightenment/applications", e_int_config_apps_startup);
|
||||||
|
|
||||||
cat = _e_configure_category_add(eco, _("Screen"), "enlightenment/screen_setup");
|
cat = _e_configure_category_add(eco, _("Screen"), "enlightenment/screen_setup");
|
||||||
_e_configure_item_add(cat, _("Virtual Desktops"), "enlightenment/desktops", e_int_config_desks);
|
_e_configure_item_add(cat, _("Virtual Desktops"), "enlightenment/desktops", e_int_config_desks);
|
||||||
_e_configure_item_add(cat, _("Screen Resolution"), "enlightenment/screen_resolution", e_int_config_display);
|
_e_configure_item_add(cat, _("Screen Resolution"), "enlightenment/screen_resolution", e_int_config_display);
|
||||||
|
|
|
@ -53,7 +53,6 @@ struct _E_Config_Once
|
||||||
void *data;
|
void *data;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
EAPI E_Config_Dialog *
|
EAPI E_Config_Dialog *
|
||||||
e_int_config_apps_once(E_Container *con, const char *title, const char *label, const char *path, int (*func) (void *data, const char *path), void *data)
|
e_int_config_apps_once(E_Container *con, const char *title, const char *label, const char *path, int (*func) (void *data, const char *path), void *data)
|
||||||
{
|
{
|
||||||
|
@ -94,6 +93,24 @@ e_int_config_apps(E_Container *con)
|
||||||
return e_int_config_apps_once(con, NULL, NULL, NULL, NULL, NULL);
|
return e_int_config_apps_once(con, NULL, NULL, NULL, NULL, NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
EAPI E_Config_Dialog *
|
||||||
|
e_int_config_apps_restart(E_Container *con)
|
||||||
|
{
|
||||||
|
char path[4096];
|
||||||
|
|
||||||
|
snprintf(path, sizeof(path), "%s/.e/e/applications/restart", e_user_homedir_get());
|
||||||
|
return e_int_config_apps_once(con, _("Restart"), NULL, path, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
|
EAPI E_Config_Dialog *
|
||||||
|
e_int_config_apps_startup(E_Container *con)
|
||||||
|
{
|
||||||
|
char path[4096];
|
||||||
|
|
||||||
|
snprintf(path, sizeof(path), "%s/.e/e/applications/startup", e_user_homedir_get());
|
||||||
|
return e_int_config_apps_once(con, _("Startup"), NULL, path, NULL, NULL);
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
_fill_data(E_Config_Dialog_Data *cfdata)
|
_fill_data(E_Config_Dialog_Data *cfdata)
|
||||||
{
|
{
|
||||||
|
|
|
@ -8,6 +8,8 @@
|
||||||
|
|
||||||
EAPI E_Config_Dialog *e_int_config_apps(E_Container *con);
|
EAPI E_Config_Dialog *e_int_config_apps(E_Container *con);
|
||||||
EAPI E_Config_Dialog *e_int_config_apps_once(E_Container *con, const char *title, const char *label, const char *path, int (*func) (void *data, const char *path), void *data);
|
EAPI E_Config_Dialog *e_int_config_apps_once(E_Container *con, const char *title, const char *label, const char *path, int (*func) (void *data, const char *path), void *data);
|
||||||
|
EAPI E_Config_Dialog *e_int_config_apps_restart(E_Container *con);
|
||||||
|
EAPI E_Config_Dialog *e_int_config_apps_startup(E_Container *con);
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -110,7 +110,6 @@ _cb_files_selected(void *data, Evas_Object *obj, void *event_info)
|
||||||
E_Config_Dialog_Data *cfdata;
|
E_Config_Dialog_Data *cfdata;
|
||||||
|
|
||||||
cfdata = data;
|
cfdata = data;
|
||||||
printf("SEL\n");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
|
@ -165,30 +164,6 @@ _cb_dir(void *data, Evas_Object *obj, void *event_info)
|
||||||
e_fm2_path_set(cfdata->o_fm, path, "/");
|
e_fm2_path_set(cfdata->o_fm, path, "/");
|
||||||
}
|
}
|
||||||
|
|
||||||
static void
|
|
||||||
_cb_button_add_startup(void *data1, void *data2)
|
|
||||||
{
|
|
||||||
const char *homedir;
|
|
||||||
char path[PATH_MAX];
|
|
||||||
|
|
||||||
homedir = e_user_homedir_get();
|
|
||||||
snprintf(path, sizeof(path), "%s/.e/e/applications/startup", homedir);
|
|
||||||
e_int_config_apps_once(e_container_current_get(e_manager_current_get()),
|
|
||||||
"Startup", NULL, path, NULL, NULL);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
|
||||||
_cb_button_add_restart(void *data1, void *data2)
|
|
||||||
{
|
|
||||||
const char *homedir;
|
|
||||||
char path[PATH_MAX];
|
|
||||||
|
|
||||||
homedir = e_user_homedir_get();
|
|
||||||
snprintf(path, sizeof(path), "%s/.e/e/applications/restart", homedir);
|
|
||||||
e_int_config_apps_once(e_container_current_get(e_manager_current_get()),
|
|
||||||
"Restart", NULL, path, NULL, NULL);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void
|
static void
|
||||||
_fill_data(E_Config_Dialog_Data *cfdata)
|
_fill_data(E_Config_Dialog_Data *cfdata)
|
||||||
{
|
{
|
||||||
|
@ -370,13 +345,5 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
|
||||||
&(cfdata->show_splash));
|
&(cfdata->show_splash));
|
||||||
e_widget_table_object_append(ot, o, 1, 3, 1, 1, 1, 0, 0, 0);
|
e_widget_table_object_append(ot, o, 1, 3, 1, 1, 1, 0, 0, 0);
|
||||||
|
|
||||||
o = e_widget_button_add(evas, _("Add startup Application"), "enlightenment/e",
|
|
||||||
_cb_button_add_startup, cfdata, NULL);
|
|
||||||
e_widget_table_object_append(ot, o, 0, 3, 1, 1, 1, 0, 0, 0);
|
|
||||||
|
|
||||||
o = e_widget_button_add(evas, _("Add restart Application"), "enlightenment/e",
|
|
||||||
_cb_button_add_restart, cfdata, NULL);
|
|
||||||
e_widget_table_object_append(ot, o, 0, 4, 1, 1, 1, 0, 0, 0);
|
|
||||||
|
|
||||||
return ot;
|
return ot;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue