A few fixes ready for some more E config things

recommend that folk remove their config.eets of convenient, doing so will remove the e tab from examine :)


SVN revision: 12326
This commit is contained in:
handyande 2004-12-01 23:07:43 +00:00 committed by handyande
parent 3e490d9197
commit b186e3a476
3 changed files with 15 additions and 2 deletions

View File

@ -244,6 +244,8 @@ extern "C"
/* FIXME: this should only be included if evas is present */
EAPI int ecore_config_evas_font_path_apply(Evas * evas);
EAPI char *ecore_config_theme_search_path_get(void);
EAPI int ecore_config_theme_search_path_append(char *append);
EAPI char *ecore_config_theme_default_path_get(void);
EAPI char *ecore_config_theme_with_path_from_name_get(char *name);
EAPI char *ecore_config_theme_with_path_get(const char *key);

View File

@ -1472,11 +1472,17 @@ ecore_config_init(char *name)
__ecore_config_bundle_local->data = list;
path = ecore_config_theme_default_path_get();
ecore_config_string_default("/e/themes/search_path", path);
if (path)
free(path);
list = ecore_config_get("/e/themes/search_path");
if (list)
{
ecore_config_string_default("/e/themes/search_path", path);
free(path);
list->flags |= PF_SYSTEM;
list->flags &= ~PF_MODIFIED;
}
return _ecore_config_system_load();
}

View File

@ -440,6 +440,7 @@ ecore_config_theme_search_path_append(char *path)
{
char *search_path, *loc, *new_search_path;
int len, search_len;
Ecore_Config_Prop *prop;
if (!path)
return ECORE_CONFIG_ERR_NODATA;
@ -458,6 +459,10 @@ ecore_config_theme_search_path_append(char *path)
strncat(new_search_path, path, len);
ecore_config_string_set("/e/themes/search_path", new_search_path);
prop = ecore_config_get("/e/themes/search_path");
if (prop)
prop->flags &= ~PF_MODIFIED;
free(new_search_path);
return ECORE_CONFIG_ERR_SUCC;