summaryrefslogtreecommitdiff
path: root/src/glade-id-allocator.c
diff options
context:
space:
mode:
authorDavid Hoover <karma@deadmoose.com>2004-10-04 15:45:22 +0000
committerMorten Welinder <mortenw@src.gnome.org>2004-10-04 15:45:22 +0000
commite3218c5303190b843597b32d8a90a823459051f3 (patch)
tree3d82ceeb9352fa849bdbee8f5a9fd47b4da3b1e3 /src/glade-id-allocator.c
parentfe825b066311a02caaf298053f55ad9cb8d3be96 (diff)
downloadglade-e3218c5303190b843597b32d8a90a823459051f3.tar.gz
mass addition of new gtk-doc-style comments for functions, some cleanup of
2004-09-23 David Hoover <karma@deadmoose.com> * src/*.c: mass addition of new gtk-doc-style comments for functions, some cleanup of language & formatting in existing comments, minor whitespace fixes, etc. Slightly revised and committed by terra@gnome.org (Morten Welinder)
Diffstat (limited to 'src/glade-id-allocator.c')
-rw-r--r--src/glade-id-allocator.c30
1 files changed, 27 insertions, 3 deletions
diff --git a/src/glade-id-allocator.c b/src/glade-id-allocator.c
index 36e08eaa..3d1d947e 100644
--- a/src/glade-id-allocator.c
+++ b/src/glade-id-allocator.c
@@ -27,6 +27,11 @@
#define INITIAL_WORDS 4
+/**
+ * glade_id_allocator_new:
+ *
+ * Returns: a new #GladeIDAllocator
+ */
GladeIDAllocator *
glade_id_allocator_new (void)
{
@@ -39,6 +44,12 @@ glade_id_allocator_new (void)
return allocator;
}
+/**
+ * glade_id_allocator_free:
+ * @allocator: a #GladeIDAllocator
+ *
+ * Frees @allocator and its associated memory
+ */
void
glade_id_allocator_free (GladeIDAllocator *allocator)
{
@@ -79,7 +90,13 @@ first_set_bit (guint32 word)
return result + table[word & 0xf];
}
-
+/**
+ * glade_id_allocator_alloc:
+ * @allocator: a #GladeIDAllocator
+ *
+ * TODO: write me
+ * Returns:
+ */
guint
glade_id_allocator_alloc (GladeIDAllocator *allocator)
{
@@ -109,6 +126,13 @@ glade_id_allocator_alloc (GladeIDAllocator *allocator)
}
}
+/**
+ * glade_id_allocator_release:
+ * @allocator:
+ * @id:
+ *
+ * TODO: write me
+ */
void
glade_id_allocator_release (GladeIDAllocator *allocator,
guint id)
@@ -117,7 +141,7 @@ glade_id_allocator_release (GladeIDAllocator *allocator,
allocator->data[id >> 5] |= 1 << (id & 31);
}
-/* test of allocator
+#ifdef GLADE_ID_ALLOCATOR_TEST
int main (int argc, char **argv)
{
GladeIDAllocator *allocator = glade_id_allocator_new ();
@@ -146,4 +170,4 @@ int main (int argc, char **argv)
return 0;
}
-*/
+#endif