aboutsummaryrefslogtreecommitdiffstats
path: root/calendar/gui
diff options
context:
space:
mode:
authorRodrigo Moya <rodrigo@gnome-db.org>2011-10-13 22:18:42 +0800
committerRodrigo Moya <rodrigo@gnome-db.org>2011-10-13 22:18:42 +0800
commit805d8c25ac6c8f58c8e17f3b89fa50f17cfdf27b (patch)
tree8e5a44fd32dfb5b5ab6621196fde70352ac44b9b /calendar/gui
parent93f489a9a4bebc6b1f2331ba2aa5804669b41a9a (diff)
downloadgsoc2013-evolution-805d8c25ac6c8f58c8e17f3b89fa50f17cfdf27b.tar.gz
gsoc2013-evolution-805d8c25ac6c8f58c8e17f3b89fa50f17cfdf27b.tar.zst
gsoc2013-evolution-805d8c25ac6c8f58c8e17f3b89fa50f17cfdf27b.zip
Use a GPtrArray instead of GArray to build the array string to use for g_settings_set_strv
Diffstat (limited to 'calendar/gui')
-rw-r--r--calendar/gui/alarm-notify/config-data.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/calendar/gui/alarm-notify/config-data.c b/calendar/gui/alarm-notify/config-data.c
index 3275c4d219..b9f2be49a3 100644
--- a/calendar/gui/alarm-notify/config-data.c
+++ b/calendar/gui/alarm-notify/config-data.c
@@ -341,18 +341,18 @@ config_data_save_blessed_program (const gchar *program)
{
gchar **list;
gint i;
- GArray *array = g_array_new (TRUE, FALSE, sizeof (gchar *));
+ GPtrArray *array = g_ptr_array_new ();
list = g_settings_get_strv (calendar_settings, "notify-programs");
for (i = 0; i < g_strv_length (list); i++)
- g_array_append_val (array, list[i]);
+ g_ptr_array_add (array, list[i]);
- g_array_append_val (array, program);
- g_array_append_val (array, NULL);
- g_settings_set_strv (calendar_settings, "notify-programs", (const gchar *const *) array->data);
+ g_ptr_array_add (array, program);
+ g_ptr_array_add (array, NULL);
+ g_settings_set_strv (calendar_settings, "notify-programs", (const gchar *const *) array->pdata);
g_strfreev (list);
- g_array_free (array, TRUE);
+ g_ptr_array_free (array, TRUE);
}
/**