*Efreet_Ini: Add a new API call:

EAPI void efreet_ini_key_unset(Efreet_Ini *ini, const char *key);

With this you can remove keys from ini files



SVN revision: 43245
This commit is contained in:
Davide Andreoli 2009-10-24 09:23:51 +00:00
parent c9533023ad
commit a59b9655b2
2 changed files with 16 additions and 0 deletions

View File

@ -603,6 +603,20 @@ efreet_ini_localestring_set(Efreet_Ini *ini, const char *key, const char *value)
FREE(buf);
}
/**
* @param ini: The ini struct to work with
* @param key: The key to remove
* @return Returns no value
* @brief Remove the given key from the ini struct
*/
EAPI void
efreet_ini_key_unset(Efreet_Ini *ini, const char *key)
{
if (!ini || !key || !ini->section) return;
eina_hash_del(ini->section, key, NULL);
}
/**
* @param str The string to unescape
* @return An allocated unescaped string

View File

@ -52,6 +52,8 @@ EAPI double efreet_ini_double_get(Efreet_Ini *ini, const char *key);
EAPI void efreet_ini_double_set(Efreet_Ini *ini, const char *key,
double value);
EAPI void efreet_ini_key_unset(Efreet_Ini *ini, const char *key);
/**
* @}
*/