Add $XDG_RUNTIME_DIR support.

SVN revision: 77666
devs/devilhorns/wayland_egl
Gustavo Sverzut Barbieri 10 years ago
parent fe34dc2b72
commit 4cd60a96e1
  1. 4
      legacy/efreet/ChangeLog
  2. 5
      legacy/efreet/NEWS
  3. 10
      legacy/efreet/src/lib/efreet_base.c
  4. 7
      legacy/efreet/src/lib/efreet_base.h

@ -139,3 +139,7 @@
* Fix long lurking bug where desktop/icon cache updates get
delayed by silly long amounts of time.
2012-10-09 Gustavo Sverzut Barbieri (k-s)
* Add $XDG_RUNTIME_DIR support

@ -6,6 +6,11 @@ Changes since Efreet 1.7.0:
Fixes:
* Fix insane delay added to desktop/icon updates.
Additions:
* Support XDG_RUNTIME_DIR
Changes since Efreet 1.2.0:
---------------------------

@ -46,6 +46,7 @@ static const char *efreet_home_dir = NULL;
static const char *xdg_data_home = NULL;
static const char *xdg_config_home = NULL;
static const char *xdg_cache_home = NULL;
static const char *xdg_runtime_dir = NULL;
static Eina_List *xdg_data_dirs = NULL;
static Eina_List *xdg_config_dirs = NULL;
static const char *xdg_desktop_dir = NULL;
@ -87,6 +88,7 @@ efreet_base_shutdown(void)
IF_RELEASE(xdg_data_home);
IF_RELEASE(xdg_config_home);
IF_RELEASE(xdg_cache_home);
IF_RELEASE(xdg_runtime_dir);
IF_FREE_LIST(xdg_data_dirs, eina_stringshare_del);
IF_FREE_LIST(xdg_config_dirs, eina_stringshare_del);
@ -179,6 +181,14 @@ efreet_cache_home_get(void)
return xdg_cache_home;
}
EAPI const char *
efreet_runtime_dir_get(void)
{
if (xdg_runtime_dir) return xdg_runtime_dir;
xdg_runtime_dir = efreet_dir_get("XDG_RUNTIME_DIR", "/tmp");
return xdg_runtime_dir;
}
EAPI const char *
efreet_hostname_get(void)
{

@ -59,6 +59,13 @@ EAPI Eina_List *efreet_config_dirs_get(void);
*/
EAPI const char *efreet_cache_home_get(void);
/**
* @return Returns the XDG User Runtime directory.
* @brief Retrieves the XDG User Runtime directory.
* @since 1.8
*/
EAPI const char *efreet_runtime_dir_get(void);
/**
* @return Returns the current hostname
* @brief Returns the current hostname or empty string if not found

Loading…
Cancel
Save