aboutsummaryrefslogtreecommitdiffstats
path: root/src/bin/efreet
diff options
context:
space:
mode:
authorSebastian Dransfeld <sd@tango.flipp.net>2014-09-25 08:47:18 +0200
committerSebastian Dransfeld <sd@tango.flipp.net>2014-09-25 08:47:45 +0200
commit793fd5e84775931cf491bf81ccbbee174feda05c (patch)
treeae7a7eb7692bad4944abc0e9dabd9f17bf4cef99 /src/bin/efreet
parentefreet: Accept both only_show_in and not_show_in (diff)
downloadefl-793fd5e84775931cf491bf81ccbbee174feda05c.tar.gz
efreet: Implement fields added by desktop spec 1.1
Diffstat (limited to 'src/bin/efreet')
-rw-r--r--src/bin/efreet/efreet_desktop_cache_create.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/bin/efreet/efreet_desktop_cache_create.c b/src/bin/efreet/efreet_desktop_cache_create.c
index ff0a106437..4fa3ef4397 100644
--- a/src/bin/efreet/efreet_desktop_cache_create.c
+++ b/src/bin/efreet/efreet_desktop_cache_create.c
@@ -40,6 +40,7 @@ static Eina_Hash *generic_name = NULL;
static Eina_Hash *comment = NULL;
static Eina_Hash *exec = NULL;
static Eina_Hash *environments = NULL;
+static Eina_Hash *keywords = NULL;
static int
cache_add(const char *path, const char *file_id, int priority EINA_UNUSED, int *changed)
@@ -112,6 +113,7 @@ cache_add(const char *path, const char *file_id, int priority EINA_UNUSED, int *
array->array[array->array_count++] = desk->orig_path; \
eina_hash_set((hash), data, array); \
}
+ /* Desktop Spec 1.0 */
ADD_LIST(desk->mime_types, mime_types);
ADD_LIST(desk->categories, categories);
ADD_ELEM(desk->startup_wm_class, startup_wm_class);
@@ -123,6 +125,8 @@ cache_add(const char *path, const char *file_id, int priority EINA_UNUSED, int *
ADD_LIST(desk->not_show_in, environments);
eina_hash_add(file_ids, file_id, desk->orig_path);
eina_hash_add(desktops, desk->orig_path, desk);
+ /* Desktop Spec 1.1 */
+ ADD_LIST(desk->keywords, keywords);
}
else
efreet_desktop_free(desk);
@@ -388,6 +392,7 @@ main(int argc, char **argv)
comment = eina_hash_string_superfast_new(EINA_FREE_CB(efreet_cache_array_string_free));
exec = eina_hash_string_superfast_new(EINA_FREE_CB(efreet_cache_array_string_free));
environments = eina_hash_string_superfast_new(EINA_FREE_CB(efreet_cache_array_string_free));
+ keywords = eina_hash_string_superfast_new(EINA_FREE_CB(efreet_cache_array_string_free));
dirs = efreet_default_dirs_get(efreet_data_home_get(), efreet_data_dirs_get(),
"applications");
@@ -438,6 +443,7 @@ main(int argc, char **argv)
STORE_HASH_ARRAY(comment);
STORE_HASH_ARRAY(exec);
STORE_HASH_ARRAY(environments);
+ STORE_HASH_ARRAY(keywords);
if (eina_hash_population(file_ids) > 0)
{
hash.hash = file_ids;
@@ -452,6 +458,7 @@ main(int argc, char **argv)
eina_hash_free(comment);
eina_hash_free(exec);
eina_hash_free(environments);
+ eina_hash_free(keywords);
if (old_file_ids)
{