Index: gutils.c
===================================================================
--- gutils.c	(révision 7740)
+++ gutils.c	(copie de travail)
@@ -2794,6 +2794,44 @@ g_get_system_config_dirs (void)
   return (G_CONST_RETURN gchar * G_CONST_RETURN *) conf_dir_vector;
 }
 
+/**
+ * g_lookup_data_dirs:
+ * @filename: 
+ * 
+ * Returns the full path of the first file named @filename in the paths
+ * returned from @g_get_user_data_dir() and @g_get_system_data_dirs().
+ *
+ * Return value: a newly allocated string holding the full path of the found file,
+ *               or %NULL if no such file could be found
+ * Since: 2.20
+ **/
+gchar*
+g_lookup_data_dirs (const gchar *filename)
+{
+  const gchar * const *system_data_dirs;
+  const char *user_data_dir;
+  char *path;
+  int i;
+
+  user_data_dir = g_get_user_data_dir ();
+
+  path = g_build_filename (user_data_dir, filename, NULL);
+  if (g_file_test (path, G_FILE_TEST_EXISTS))
+    return path;
+  g_free (path);
+
+  system_data_dirs = g_get_system_data_dirs ();
+  for (i = 0; system_data_dirs[i]; i++)
+    {
+      path = g_build_filename (system_data_dirs[i], filename, NULL);
+      if (g_file_test (path, G_FILE_TEST_EXISTS))
+        return path;
+      g_free (path);
+    }
+
+  return NULL;
+}
+
 #ifndef G_OS_WIN32
 
 static GHashTable *alias_table = NULL;
Index: gutils.h
===================================================================
--- gutils.h	(révision 7740)
+++ gutils.h	(copie de travail)
@@ -131,6 +131,7 @@ G_CONST_RETURN gchar*    g_get_user_data
 G_CONST_RETURN gchar*    g_get_user_config_dir    (void);
 G_CONST_RETURN gchar*    g_get_user_cache_dir     (void);
 G_CONST_RETURN gchar* G_CONST_RETURN * g_get_system_data_dirs   (void);
+gchar*                   g_lookup_data_dirs (const gchar *filename);
 
 #ifdef G_OS_WIN32
 G_CONST_RETURN gchar* G_CONST_RETURN * g_win32_get_system_data_dirs_for_module (gconstpointer address);
