[Gnucash-changes] r13477 - gnucash/trunk - Make g_strv_length available outside of the gkeyfile compatability

David Hampton hampton at cvs.gnucash.org
Sat Mar 4 14:09:32 EST 2006


Author: hampton
Date: 2006-03-04 14:09:31 -0500 (Sat, 04 Mar 2006)
New Revision: 13477
Trac: http://svn.gnucash.org/trac/changeset/13477

Modified:
   gnucash/trunk/ChangeLog
   gnucash/trunk/lib/glib26/gkeyfile.c
   gnucash/trunk/lib/glib26/gutils26.c
   gnucash/trunk/lib/glib26/gutils26.h
   gnucash/trunk/src/gnome-utils/dialog-account.c
Log:
Make g_strv_length available outside of the gkeyfile compatability
library.


Modified: gnucash/trunk/ChangeLog
===================================================================
--- gnucash/trunk/ChangeLog	2006-03-04 18:12:34 UTC (rev 13476)
+++ gnucash/trunk/ChangeLog	2006-03-04 19:09:31 UTC (rev 13477)
@@ -1,3 +1,10 @@
+2006-03-04  David Hampton  <hampton at employees.org>
+
+	* src/gnome-utils/dialog-account.c:
+	* lib/glib26/gkeyfile.c:
+	* lib/glib26/gutils26.[ch]: Make g_strv_length available outside
+	of the gkeyfile compatability library.
+
 2006-03-04  Joshua Sled  <jsled at asynchronous.org>
 
 	* src/gnome/glade/sched-xact.glade: Fix selection mode on

Modified: gnucash/trunk/lib/glib26/gkeyfile.c
===================================================================
--- gnucash/trunk/lib/glib26/gkeyfile.c	2006-03-04 18:12:34 UTC (rev 13476)
+++ gnucash/trunk/lib/glib26/gkeyfile.c	2006-03-04 19:09:31 UTC (rev 13477)
@@ -191,32 +191,6 @@
 								GError                **error);
 
 
-/**
- * g_strv_length:
- * @str_array: a %NULL-terminated array of strings.
- * 
- * Returns the length of the given %NULL-terminated 
- * string array @str_array.
- * 
- * Return value: length of @str_array.
- *
- * From the file gstrfuncs.c
- *
- * Since: 2.6
- **/
-static guint
-g_strv_length (gchar **str_array)
-{
-  guint i = 0;
-
-  g_return_val_if_fail (str_array != NULL, 0);
-
-  while (str_array[i])
-    ++i;
-
-  return i;
-}
-
 GQuark
 g_key_file_error_quark (void)
 {

Modified: gnucash/trunk/lib/glib26/gutils26.c
===================================================================
--- gnucash/trunk/lib/glib26/gutils26.c	2006-03-04 18:12:34 UTC (rev 13476)
+++ gnucash/trunk/lib/glib26/gutils26.c	2006-03-04 19:09:31 UTC (rev 13477)
@@ -1035,6 +1035,30 @@
 
 #endif /* ENABLE_NLS */
 
+/**
+ * g_strv_length:
+ * @str_array: a %NULL-terminated array of strings.
+ * 
+ * Returns the length of the given %NULL-terminated 
+ * string array @str_array.
+ * 
+ * Return value: length of @str_array.
+ *
+ * Since: 2.6
+ **/
+guint
+g_strv_length (gchar **str_array)
+{
+  guint i = 0;
+
+  g_return_val_if_fail (str_array != NULL, 0);
+
+  while (str_array[i])
+    ++i;
+
+  return i;
+}
+
 #if 0
 #define __G_UTILS_C__
 #include "galiasdef.c"

Modified: gnucash/trunk/lib/glib26/gutils26.h
===================================================================
--- gnucash/trunk/lib/glib26/gutils26.h	2006-03-04 18:12:34 UTC (rev 13476)
+++ gnucash/trunk/lib/glib26/gutils26.h	2006-03-04 19:09:31 UTC (rev 13477)
@@ -180,4 +180,6 @@
 }
 #endif /* G_PLATFORM_WIN32 */
 
+guint                 g_strv_length    (gchar       **str_array);
+
 #endif /* __G_UTILS_26_H__ */

Modified: gnucash/trunk/src/gnome-utils/dialog-account.c
===================================================================
--- gnucash/trunk/src/gnome-utils/dialog-account.c	2006-03-04 18:12:34 UTC (rev 13476)
+++ gnucash/trunk/src/gnome-utils/dialog-account.c	2006-03-04 19:09:31 UTC (rev 13477)
@@ -25,6 +25,9 @@
 #include "config.h"
 
 #include <gnome.h>
+#ifndef HAVE_GLIB26
+#include "gutils26.h"
+#endif
 #include <glib/gi18n.h>
 #include <math.h>
 #include <string.h>



More information about the gnucash-changes mailing list