It seems that the only things left to document are FoobarDetails
authorCosimo Cecchi <cosimoc@gnome.org>
Mon, 4 Aug 2008 15:43:11 +0000 (4 17:43 +0200)
committerCosimo Cecchi <cosimoc@gnome.org>
Mon, 4 Aug 2008 15:43:11 +0000 (4 17:43 +0200)
structs, but I should find a workaround for that.

libmmanager-gtk/mm-gtk-application-store.h
libmmanager-gtk/mm-gtk-application-view.c
libmmanager-gtk/mm-gtk-application-view.h
libmmanager-gtk/mm-gtk-attribute-store.h
libmmanager-gtk/mm-gtk-filter-builder.h
libmmanager-gtk/mm-gtk-hit-store.h
libmmanager-gtk/mm-gtk-hit-view.h
libmmanager/mm-base-attributes.h
libmmanager/mm-error.h
libmmanager/mm-types.h
libmmanager/mm-utils.h

index 18b7bf9..b2fbb41 100644 (file)
 #define MM_GTK_APPLICATION_STORE_GET_CLASS(obj) \
   (G_TYPE_INSTANCE_GET_CLASS ((obj), MM_GTK_TYPE_APPLICATION_STORE, MMGtkApplicationStoreClass))
 
-typedef struct {
+/**
+ * SECTION:mm-gtk-application-store
+ * @short_description: a #GtkListStore to hold applications.
+ *
+ * #MMGtkApplicationStore is a #GtkTreeStore subclass, which holds
+ * #MMApplicationType, #MMApplication and #MMCategory objects respectively
+ * at depth 0, 1 and 2.
+ */
+/**
+ * MMGtkApplicationStore:
+ *
+ * A #GtkTreeStore which holds libmmanager basic objects.
+ */
+
+typedef struct _MMGtkApplicationStore MMGtkApplicationStore;
+typedef struct _MMGtkApplicationStoreClass MMGtkApplicationStoreClass;
+
+struct _MMGtkApplicationStore {
   GtkTreeStore parent;
-} MMGtkApplicationStore;
+};
 
-typedef struct {
+struct _MMGtkApplicationStoreClass {
   GtkTreeStoreClass parent_class;
-} MMGtkApplicationStoreClass;
+};
 
 enum {
   MM_GTK_APP_STORE_TYPE_COLUMN,
index f17c5ec..e4a8443 100644 (file)
@@ -141,26 +141,54 @@ mm_gtk_application_view_class_init (MMGtkApplicationViewClass *klass)
   GObjectClass *oclass = G_OBJECT_CLASS (klass);
   oclass->constructor = impl_constructor;
 
+  /**
+   * MMGtkApplicationView::application-selected:
+   * @view: the view.
+   * @application: the application that was selected.
+   *
+   * Gets emitted when the user selects a #MMApplication inside the
+   * treeview.
+   */
+
   view_signals[APPLICATION_SELECTED] =
     g_signal_new ("application_selected",
                   G_OBJECT_CLASS_TYPE (oclass),
                   G_SIGNAL_RUN_LAST,
                   G_STRUCT_OFFSET (MMGtkApplicationViewClass, application_selected),
                   NULL, NULL,
-                  g_cclosure_marshal_VOID__POINTER,
+                  g_cclosure_marshal_VOID__OBJECT,
                   G_TYPE_NONE,
                   1,
-                  G_TYPE_POINTER);
+                  MM_TYPE_APPLICATION);
+
+  /**
+   * MMGtkApplicationView::category-selected:
+   * @view: the view.
+   * @category: the category that was selected.
+   *
+   * Gets emitted when the user selects a #MMCategory inside the treeview.
+   */
+
   view_signals[CATEGORY_SELECTED] =
     g_signal_new ("category_selected",
                   G_OBJECT_CLASS_TYPE (oclass),
                   G_SIGNAL_RUN_LAST,
                   G_STRUCT_OFFSET (MMGtkApplicationViewClass, category_selected),
                   NULL, NULL,
-                  g_cclosure_marshal_VOID__POINTER,
+                  g_cclosure_marshal_VOID__OBJECT,
                   G_TYPE_NONE,
                   1,
-                  G_TYPE_POINTER);
+                  MM_TYPE_CATEGORY);
+
+  /**
+   * MMGtkApplicationView::mmtype-selected:
+   * @view: the view.
+   * @mm_type: the #MMApplicationType that was selected.
+   *
+   * Gets emitted when the user selects a #MMApplicationType inside the
+   * treeview.
+   */
+
   view_signals[MMTYPE_SELECTED] =
     g_signal_new ("mmtype_selected",
                   G_OBJECT_CLASS_TYPE (oclass),
index 26d278d..5c15d0a 100644 (file)
 #define MM_GTK_APPLICATION_VIEW_GET_CLASS(obj) \
   (G_TYPE_INSTANCE_GET_CLASS ((obj), MM_GTK_TYPE_APPLICATION_VIEW, MMGtkApplicationViewClass))
 
+/**
+ * SECTION:mm-gtk-application-view
+ * @short_description: view #GtkWidget for #MMGtkApplicationStore
+ *
+ * #MMGtkApplicationView is a #GtkTreeView which shows the contents of
+ * a #MMGtkApplicationStore in a nice tree similar to the Nautilus tree
+ * sidebar.
+ */
+/**
+ * MMGtkApplicationView:
+ *
+ * A #GtkTreeView made for showing a #MMGtkApplicationStore.
+ */
+
 typedef struct _MMGtkApplicationView        MMGtkApplicationView;
 typedef struct _MMGtkApplicationViewClass   MMGtkApplicationViewClass;
 typedef struct _MMGtkApplicationViewDetails MMGtkApplicationViewDetails;
index 208575a..9f5174d 100644 (file)
 #define MM_GTK_ATTRIBUTE_STORE_GET_CLASS(obj) \
   (G_TYPE_INSTANCE_GET_CLASS ((obj), MM_GTK_TYPE_ATTRIBUTE_STORE, MMGtkAttributeStoreClass))
 
-typedef struct {
+/**
+ * SECTION:mm-gtk-attribute-store
+ * @short_description: #GtkListStore that holds attributes.
+ *
+ * #MMGtkAttributeStore is a #GtkListStore that holds attributes, with one
+ * column for each attribute property.
+ */
+
+/**
+ * MMGtkAttributeStore:
+ *
+ * #GtkListStore implementation to store #MMAttribute structs.
+ */
+
+typedef struct _MMGtkAttributeStore MMGtkAttributeStore;
+typedef struct _MMGtkAttributeStoreClass MMGtkAttributeStoreClass;
+
+struct _MMGtkAttributeStore {
   GtkListStore parent;
-} MMGtkAttributeStore;
+};
 
-typedef struct {
+struct _MMGtkAttributeStoreClass {
   GtkListStoreClass parent_class;
-} MMGtkAttributeStoreClass;
+};
 
 enum {
   MM_GTK_ATTR_STORE_ATTR_COL,
index 7d47e69..df3765e 100644 (file)
 #define MM_GTK_FILTER_BUILDER_GET_CLASS(obj) \
   (G_TYPE_INSTANCE_GET_CLASS ((obj), MM_GTK_TYPE_FILTER_BUILDER, MMGtkFilterBuilderClass))
 
+/**
+ * SECTION:mm-gtk-filter-builder
+ * @short_description: widget to build #MMFilter<!-- -->s.
+ *
+ * #MMGtkFilterBuilder is a #GtkWidget that allow you to build #MMFilter objects
+ * graphically. You need a #MMCategory to build it.
+ */
+/**
+ * MMGtkFilterBuilder:
+ *
+ * A #GtkWidget that allows the user to build custom #MMFilter<!-- -->s.
+ */
+
+typedef struct _MMGtkFilterBuilder MMGtkFilterBuilder;
+typedef struct _MMGtkFilterBuilderClass MMGtkFilterBuilderClass;
 typedef struct _MMGtkFilterBuilderDetails MMGtkFilterBuilderDetails;
 
-typedef struct {
+struct _MMGtkFilterBuilder {
   GtkVBox parent;
   MMGtkFilterBuilderDetails *details;
-} MMGtkFilterBuilder;
+};
 
-typedef struct {
+struct _MMGtkFilterBuilderClass {
   GtkVBoxClass parent_class;
-} MMGtkFilterBuilderClass;
+};
 
 GType               mm_gtk_filter_builder_get_type   (void);
 MMGtkFilterBuilder* mm_gtk_filter_builder_new        (MMCategory *category);
index f2ea7d0..8a295dd 100644 (file)
 #define MM_GTK_HIT_STORE_GET_CLASS(obj) \
   (G_TYPE_INSTANCE_GET_CLASS ((obj), MM_GTK_TYPE_HIT_STORE, MMGtkHitStoreClass))
 
-typedef struct {
+/**
+ * SECTION:mm-gtk-hit-store
+ * @short_description: stores #MMHit objects.
+ *
+ * #MMGtkHitStore is a #GtkListStore which holds #MMHit objects.
+ */
+
+/**
+ * MMGtkHitStore:
+ *
+ * A #GtkListStore holding #MMHit<!-- -->s.
+ */
+
+typedef struct _MMGtkHitStore MMGtkHitStore;
+typedef struct _MMGtkHitStoreClass MMGtkHitStoreClass;
+
+struct _MMGtkHitStore {
   GtkListStore parent;
-} MMGtkHitStore;
+};
 
-typedef struct {
+struct _MMGtkHitStoreClass {
   GtkListStoreClass parent_class;
-} MMGtkHitStoreClass;
+};
 
 enum {
   MM_GTK_HIT_STORE_HIT_COL,
index 23e3d9f..c177744 100644 (file)
 #define MM_GTK_HIT_VIEW_GET_CLASS(obj) \
   (G_TYPE_INSTANCE_GET_CLASS ((obj), MM_GTK_TYPE_HIT_VIEW, MMGtkHitViewClass))
 
+/**
+ * SECTION:mm-gtk-hit-view
+ * @short_description: displays a #MMGtkHitStore.
+ *
+ * #MMGtkHitView is a #GtkTreeView that can display in a widget a
+ * #MMGtkHitStore.
+ */
+/**
+ * MMGtkHitView:
+ *
+ * Displays a #MMGtkHitStore in a #GtkTreeView.
+ */
+
+typedef struct _MMGtkHitView MMGtkHitView;
+typedef struct _MMGtkHitViewClass MMGtkHitViewClass;
 typedef struct _MMGtkHitViewDetails MMGtkHitViewDetails;
 
-typedef struct {
+struct _MMGtkHitView {
   GtkTreeView parent;
   MMGtkHitViewDetails *details;
-} MMGtkHitView;
+};
 
-typedef struct {
+struct _MMGtkHitViewClass {
   GtkTreeViewClass parent_class;
-} MMGtkHitViewClass;
+};
 
 GType         mm_gtk_hit_view_get_type (void);
 MMGtkHitView* mm_gtk_hit_view_new      (MMHitCollection *collection);
index f478e6f..c92028a 100644 (file)
 #ifndef __MM_BASE_ATTRIBUTES_H__
 #define __MM_BASE_ATTRIBUTES_H__
 
-/* base attributes */
+/**
+ * SECTION:mm-base-attributes
+ * @short_description: base attributes.
+ *
+ * Definitions for base attributes, to be used by #MMAttributeBaseManager.
+ */
 
 /**
  * MM_ATTRIBUTE_BASE_URI:
index 2cd6bd2..293efaf 100644 (file)
 
 #include <glib.h>
 
-/* error handling */
+/**
+ * SECTION:mm-error
+ * @short_description: error codes.
+ *
+ * Enumerations for error codes to be used in libmmanager #GError<!-- -->s.
+ */
 
 /**
  * MM_XML_ERROR_QUARK:
index 5f5e3f9..d04d35b 100644 (file)
 #define __MM_TYPES_H__
 
 /**
+ * SECTION:mm-types
+ * @short_description: enum types.
+ *
+ * Enumeration types used across the library when needed.
+ */
+
+/**
  * MMApplicationType:
  * @MM_APPLICATION_NONE: initializer.
  * @MM_APPLICATION_PHOTO: application supports photo management.
index 9c530c8..072b7d0 100644 (file)
 #include <glib-object.h>
 #include "mm-attribute.h"
 
+/**
+ * SECTION:mm-utils
+ * @short_description: misc utils.
+ *
+ * Helper functions to make boring jobs more quickly.
+ */
+
 /* public functions */
 
 GValue *