[nautilus-actions] Remove -not yet released- na_data_types_copy() and na_data_types_free() functions



commit 47fb0653ee1de0bedf0db14924bdd78597d13e6d
Author: Pierre Wieser <pwieser trychlos org>
Date:   Wed Jan 12 01:36:15 2011 +0100

    Remove -not yet released- na_data_types_copy() and na_data_types_free() functions

 ChangeLog                |    4 ++
 src/api/na-data-types.h  |    6 +---
 src/core/na-data-types.c |   86 ----------------------------------------------
 3 files changed, 5 insertions(+), 91 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 819da68..b4be4ea 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -33,6 +33,10 @@
 
 	* configure.ac: Enable silent rules by default.
 
+	* src/api/na-data-types.h:
+	* src/core/na-data-types.c
+	(na_data_types_copy, na_data_types_free): Removed functions.
+
 	* README-GCONF:
 	* src/utils/na-gconf2key.sh.in: Fix two key label conversions.
 
diff --git a/src/api/na-data-types.h b/src/api/na-data-types.h
index 80e651d..16b40b0 100644
--- a/src/api/na-data-types.h
+++ b/src/api/na-data-types.h
@@ -76,14 +76,10 @@ typedef enum {
 	NAFD_TYPE_BOOLEAN,
 	NAFD_TYPE_STRING_LIST,
 	NAFD_TYPE_POINTER,
-	NAFD_TYPE_UINT,
-	NAFD_TYPE_MAP
+	NAFD_TYPE_UINT
 }
 	NAFactoryDataType;
 
-gpointer     na_data_types_copy     ( gpointer value, guint type );
-void         na_data_types_free     ( gpointer value, guint type );
-
 const gchar *na_data_types_get_gconf_dump_key( guint type );
 
 const gchar *na_data_types_get_label( guint type );
diff --git a/src/core/na-data-types.c b/src/core/na-data-types.c
index c7c9588..68e79b9 100644
--- a/src/core/na-data-types.c
+++ b/src/core/na-data-types.c
@@ -49,96 +49,10 @@ static FactoryType st_factory_type[] = {
 		{ NAFD_TYPE_STRING_LIST,   "string list",   "list" },
 		{ NAFD_TYPE_POINTER,       "pointer",        NULL },
 		{ NAFD_TYPE_UINT,          "uint",          "int" },
-		{ NAFD_TYPE_MAP,           "map",           "string" },
 		{ 0 }
 };
 
 /**
- * na_data_types_copy:
- * @value: the value to be duplicated.
- * @type: the FactoryData type.
- *
- * Returns: a new occurrence of the value which should be na_data_types_free()
- * by the caller.
- *
- * Since: 3.1.0
- */
-gpointer
-na_data_types_copy( gpointer value, guint type )
-{
-	static const gchar *thisfn = "na_data_types_copy";
-	gpointer new_value;
-
-	switch( type ){
-
-		case NAFD_TYPE_STRING:
-		case NAFD_TYPE_LOCALE_STRING:
-		case NAFD_TYPE_MAP:
-			new_value = g_strdup(( const gchar * ) value );
-			break;
-
-		case NAFD_TYPE_BOOLEAN:
-		case NAFD_TYPE_UINT:
-			new_value = GUINT_TO_POINTER( GPOINTER_TO_UINT( value ));
-			break;
-
-		case NAFD_TYPE_POINTER:
-			g_warning( "%s: unmanaged data type: %s", thisfn, na_data_types_get_label( type ));
-			new_value = NULL;
-			break;
-
-		case NAFD_TYPE_STRING_LIST:
-			new_value = na_core_utils_slist_duplicate(( GSList * ) value );
-			break;
-
-		default:
-			g_warning( "%s: unknown data type: %d", thisfn, type );
-			new_value = NULL;
-	}
-
-	return( new_value );
-}
-
-/**
- * na_data_types_free:
- * @value: the value to be released.
- * @type: the FactoryData type.
- *
- * Release the value.
- *
- * Since: 3.1.0
- */
-void
-na_data_types_free( gpointer value, guint type )
-{
-	static const gchar *thisfn = "na_data_types_free";
-
-	switch( type ){
-
-		case NAFD_TYPE_STRING:
-		case NAFD_TYPE_LOCALE_STRING:
-		case NAFD_TYPE_MAP:
-			g_free( value );
-			break;
-
-		case NAFD_TYPE_BOOLEAN:
-		case NAFD_TYPE_UINT:
-			break;
-
-		case NAFD_TYPE_POINTER:
-			g_warning( "%s: unmanaged data type: %s", thisfn, na_data_types_get_label( type ));
-			break;
-
-		case NAFD_TYPE_STRING_LIST:
-			na_core_utils_slist_free(( GSList * ) value );
-			break;
-
-		default:
-			g_warning( "%s: unknown data type: %d", thisfn, type );
-	}
-}
-
-/**
  * na_data_types_get_gconf_dump_key:
  * @type: the FactoryData type.
  *



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]