[evolution-kolab] libekolab: populate KolabDataFolderMetadata with members needed for folder (un)hide
- From: Christian Hilberg <chilberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-kolab] libekolab: populate KolabDataFolderMetadata with members needed for folder (un)hide
- Date: Fri, 14 Sep 2012 17:13:49 +0000 (UTC)
commit 1db5a58f9805ae12603d97edd65612e81a228653
Author: Christian Hilberg <hilberg kernelconcepts de>
Date: Fri Sep 14 18:48:34 2012 +0200
libekolab: populate KolabDataFolderMetadata with members needed for folder (un)hide
src/libekolab/kolab-data-folder-metadata.c | 17 +++++++++++++----
src/libekolab/kolab-data-folder-metadata.h | 6 +++++-
2 files changed, 18 insertions(+), 5 deletions(-)
---
diff --git a/src/libekolab/kolab-data-folder-metadata.c b/src/libekolab/kolab-data-folder-metadata.c
index d6cfc88..34a4313 100644
--- a/src/libekolab/kolab-data-folder-metadata.c
+++ b/src/libekolab/kolab-data-folder-metadata.c
@@ -35,7 +35,12 @@ kolab_data_folder_metadata_new (void)
{
KolabDataFolderMetadata *data = NULL;
data = g_new0 (KolabDataFolderMetadata, 1);
- /* FIXME set field defaults */
+
+ /* set field defaults */
+ data->foldername = NULL;
+ data->foldertype = KOLAB_FOLDER_TYPE_INVAL;
+ data->show_all = FALSE;
+
return data;
}
@@ -49,8 +54,9 @@ kolab_data_folder_metadata_clone (const KolabDataFolderMetadata *srcdata)
data = g_new0 (KolabDataFolderMetadata, 1);
- /* FIXME set fields from srcdata */
- data->foo = srcdata->foo;
+ data->foldername = g_strdup (srcdata->foldername);
+ data->foldertype = srcdata->foldertype;
+ data->show_all = srcdata->show_all;
return data;
}
@@ -60,7 +66,10 @@ kolab_data_folder_metadata_free (KolabDataFolderMetadata *data)
{
if (data == NULL)
return;
- /* FIXME free fields */
+
+ if (data->foldername != NULL)
+ g_free (data->foldername);
+
g_free (data);
}
diff --git a/src/libekolab/kolab-data-folder-metadata.h b/src/libekolab/kolab-data-folder-metadata.h
index 9884607..2e9b9ab 100644
--- a/src/libekolab/kolab-data-folder-metadata.h
+++ b/src/libekolab/kolab-data-folder-metadata.h
@@ -33,11 +33,15 @@
#include <glib.h>
+#include <libekolabutil/kolab-util-folder.h>
+
/*----------------------------------------------------------------------------*/
typedef struct _KolabDataFolderMetadata KolabDataFolderMetadata;
struct _KolabDataFolderMetadata {
- gboolean foo; /* FIXME */
+ gchar *foldername;
+ KolabFolderTypeID foldertype;
+ gboolean show_all; /* whether to unhide PIM folders */
};
/*----------------------------------------------------------------------------*/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]