From 853ee8330dd968b8de9fc33a6e55fd61df3b1d7e Mon Sep 17 00:00:00 2001 From: Carsten Haitzler Date: Sat, 19 Aug 2006 15:18:00 +0000 Subject: [PATCH] add more mime type locations - but this is bad - where do we stop? SVN revision: 24911 --- src/bin/e_fm_mime.c | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/src/bin/e_fm_mime.c b/src/bin/e_fm_mime.c index 52978fe04..12a7162a1 100644 --- a/src/bin/e_fm_mime.c +++ b/src/bin/e_fm_mime.c @@ -89,6 +89,21 @@ _e_fm_mime_update(void) homedir = e_user_homedir_get(); if (!homedir) return; + { + static time_t last_changed = 0; + time_t ch; + + snprintf(buf, sizeof(buf), "/usr/local/etc/mime.types"); + ch = ecore_file_mod_time(buf); + if ((ch != last_changed) || (reload)) + { + _e_fm_mime_all_free(); + last_changed = ch; + _e_fm_mime_mime_types_load(buf); + reload = 1; + } + } + { static time_t last_changed = 0; time_t ch; @@ -104,6 +119,19 @@ _e_fm_mime_update(void) } } + { + static time_t last_changed = 0; + time_t ch; + + snprintf(buf, sizeof(buf), "/usr/local/share/mime/globs"); + ch = ecore_file_mod_time(buf); + if ((ch != last_changed) || (reload)) + { + last_changed = ch; + _e_fm_mime_shared_mimeinfo_globs_load(buf); + } + } + { static time_t last_changed = 0; time_t ch;