A few fixes ready for some more E config things
authorhandyande <handyande>
Wed, 1 Dec 2004 23:07:43 +0000 (23:07 +0000)
committerhandyande <handyande@7cbeb6ba-43b4-40fd-8cce-4c39aea84d33>
Wed, 1 Dec 2004 23:07:43 +0000 (23:07 +0000)
recommend that folk remove their config.eets of convenient, doing so will remove the e tab from examine :)

SVN revision: 12326

legacy/ecore/src/lib/ecore_config/Ecore_Config.h
legacy/ecore/src/lib/ecore_config/ecore_config.c
legacy/ecore/src/lib/ecore_config/ecore_config_extra.c

index 66499a2..6fbd8f1 100644 (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);
index b985ac6..fc0e748 100644 (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();
 }
 
index a0df820..8e6c428 100644 (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;