[Xfce4-commits] <glib-objc:no-foundation-dep> move GOCNumber from glib to gobject wrapper and remove GOCHashTable dep

Brian J. Tarricone noreply at xfce.org
Sun Nov 22 04:02:08 CET 2009


Updating branch refs/heads/no-foundation-dep
         to 8fd6b78b38c3de1c26f31e4d46d4ad7b179e7b12 (commit)
       from 241eb7a8ddeb35a25cebc5db3533c2845bab6e83 (commit)

commit 8fd6b78b38c3de1c26f31e4d46d4ad7b179e7b12
Author: Brian J. Tarricone <brian at tarricone.org>
Date:   Mon Jul 6 15:31:12 2009 -0700

    move GOCNumber from glib to gobject wrapper and remove GOCHashTable dep

 glib-objc/GOCHashTable.m                |   12 +++---------
 glib-objc/Makefile.am                   |    2 --
 glib-objc/glib-objc.h                   |    1 -
 {glib-objc => gobject-objc}/GOCNumber.h |    0
 {glib-objc => gobject-objc}/GOCNumber.m |    0
 gobject-objc/Makefile.am                |    2 ++
 6 files changed, 5 insertions(+), 12 deletions(-)

diff --git a/glib-objc/GOCHashTable.m b/glib-objc/GOCHashTable.m
index c188eb2..bbab67c 100644
--- a/glib-objc/GOCHashTable.m
+++ b/glib-objc/GOCHashTable.m
@@ -24,7 +24,6 @@
 #include <glib.h>
 
 #import "GOCHashTable.h"
-#import "GOCNumber.h"
 
 @implementation GOCHashTableIter
 
@@ -198,14 +197,9 @@ ght_foreach_remove(gpointer key,
                    gpointer user_data)
 {
     GHTForeachData *fedata = user_data;
-    id (*cb)(id,SEL,id,id,id) = (id (*)(id,SEL,id,id,id))fedata->callback;
-    id ret;
-
-    ret = cb(fedata->object, fedata->selector, (id)key, (id)value, fedata->userData);
-    if(!ret || [ret class] != [GOCNumber class])
-        return FALSE;
-    else
-        return [(GOCNumber *)ret boolValue];
+    BOOL (*cb)(id,SEL,id,id,id) = (BOOL (*)(id,SEL,id,id,id))fedata->callback;
+
+    return cb(fedata->object, fedata->selector, (id)key, (id)value, fedata->userData);
 }
 
 - (unsigned int)removeBySelector:(SEL)selector
diff --git a/glib-objc/Makefile.am b/glib-objc/Makefile.am
index 50a58a1..2aa3fc6 100644
--- a/glib-objc/Makefile.am
+++ b/glib-objc/Makefile.am
@@ -10,7 +10,6 @@ glibobjcinclude_HEADERS = \
 	GOCHashTable.h \
 	GOCIterable.h \
 	GOCList.h \
-	GOCNumber.h \
 	GOCObjectBase.h
 
 libglib_objc_2_0_la_SOURCES = \
@@ -18,7 +17,6 @@ libglib_objc_2_0_la_SOURCES = \
 	$(glibobjcinclude_HEADERS) \
 	GOCHashTable.m \
 	GOCList.m \
-	GOCNumber.m \
 	GOCObjectBase.m
 
 libglib_objc_2_0_la_CFLAGS = \
diff --git a/glib-objc/glib-objc.h b/glib-objc/glib-objc.h
index 6b75ad2..86a5ddd 100644
--- a/glib-objc/glib-objc.h
+++ b/glib-objc/glib-objc.h
@@ -27,7 +27,6 @@
 #import <glib-objc/GOCHashTable.h>
 #import <glib-objc/GOCIterable.h>
 #import <glib-objc/GOCList.h>
-#import <glib-objc/GOCNumber.h>
 #import <glib-objc/GOCObjectBase.h>
 
 #undef __IN_GLIB_OBJC_H
diff --git a/glib-objc/GOCNumber.h b/gobject-objc/GOCNumber.h
similarity index 100%
rename from glib-objc/GOCNumber.h
rename to gobject-objc/GOCNumber.h
diff --git a/glib-objc/GOCNumber.m b/gobject-objc/GOCNumber.m
similarity index 100%
rename from glib-objc/GOCNumber.m
rename to gobject-objc/GOCNumber.m
diff --git a/gobject-objc/Makefile.am b/gobject-objc/Makefile.am
index d61b930..de9dc8a 100644
--- a/gobject-objc/Makefile.am
+++ b/gobject-objc/Makefile.am
@@ -7,6 +7,7 @@ gobjectobjcincludedir = $(glibobjcmainincludedir)/gobject-objc
 gobjectobjcinclude_HEADERS = \
 	GOCBoxedValue.h \
 	GOCObject.h \
+	GOCNumber.h \
 	GOCValue.h
 
 libgobject_objc_2_0_la_SOURCES = \
@@ -14,6 +15,7 @@ libgobject_objc_2_0_la_SOURCES = \
 	$(gobjectobjcinclude_HEADERS) \
 	GOCBoxedValue.m \
 	GOCObject.m \
+	GOCNumber.m \
 	GOCValue.m \
 	glib-objc-private.m \
 	glib-objc-private.h



More information about the Xfce4-commits mailing list