Commit e1fa1739 authored by Frederic Peters's avatar Frederic Peters

Put configuration data in XDG_CONFIG_DIRS (GNOME bug 494007)

parent 6af3cdc1
......@@ -432,7 +432,7 @@ empathy_account_widget_irc_new (EmpathyAccount *account)
settings = g_slice_new0 (EmpathyAccountWidgetIrc);
settings->account = g_object_ref (account);
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
g_mkdir_with_parents (dir, S_IRUSR | S_IWUSR | S_IXUSR);
user_file_with_path = g_build_filename (dir, IRC_NETWORKS_FILENAME, NULL);
g_free (dir);
......
......@@ -49,7 +49,7 @@ geometry_get_filename (void)
gchar *dir;
gchar *filename;
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
if (!g_file_test (dir, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR)) {
DEBUG ("Creating directory:'%s'", dir);
g_mkdir_with_parents (dir, GEOMETRY_DIR_CREATE_MODE);
......
......@@ -409,7 +409,7 @@ empathy_chatroom_manager_constructor (GType type,
/* Set the default file path */
gchar *dir;
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
if (!g_file_test (dir, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_DIR))
g_mkdir_with_parents (dir, S_IRUSR | S_IWUSR | S_IXUSR);
......
......@@ -67,7 +67,7 @@ empathy_contact_groups_get_all (void)
groups = NULL;
}
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
file_with_path = g_build_filename (dir, CONTACT_GROUPS_XML_FILENAME, NULL);
g_free (dir);
......@@ -190,7 +190,7 @@ contact_groups_file_save (void)
gchar *dir;
gchar *file;
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
g_mkdir_with_parents (dir, S_IRUSR | S_IWUSR | S_IXUSR);
file = g_build_filename (dir, CONTACT_GROUPS_XML_FILENAME, NULL);
g_free (dir);
......
......@@ -176,7 +176,7 @@ empathy_status_presets_get_all (void)
presets = NULL;
}
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
g_mkdir_with_parents (dir, S_IRUSR | S_IWUSR | S_IXUSR);
file_with_path = g_build_filename (dir, STATUS_PRESETS_XML_FILENAME, NULL);
g_free (dir);
......@@ -203,7 +203,7 @@ status_presets_file_save (void)
count[i] = 0;
}
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
g_mkdir_with_parents (dir, S_IRUSR | S_IWUSR | S_IXUSR);
file = g_build_filename (dir, STATUS_PRESETS_XML_FILENAME, NULL);
g_free (dir);
......
......@@ -611,7 +611,7 @@ main_window_accels_load (void)
{
gchar *filename;
filename = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, ACCELS_FILENAME, NULL);
filename = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, ACCELS_FILENAME, NULL);
if (g_file_test (filename, G_FILE_TEST_EXISTS)) {
DEBUG ("Loading from:'%s'", filename);
gtk_accel_map_load (filename);
......@@ -626,7 +626,7 @@ main_window_accels_save (void)
gchar *dir;
gchar *file_with_path;
dir = g_build_filename (g_get_home_dir (), ".gnome2", PACKAGE_NAME, NULL);
dir = g_build_filename (g_get_user_config_dir (), PACKAGE_NAME, NULL);
g_mkdir_with_parents (dir, S_IRUSR | S_IWUSR | S_IXUSR);
file_with_path = g_build_filename (dir, ACCELS_FILENAME, NULL);
g_free (dir);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment