2009-03-19 Alejandro G. Castro <alex@igalia.com>
[hildon] / src / hildon-touch-selector.h
index e4f8131..14b4d9f 100644 (file)
@@ -52,11 +52,12 @@ typedef struct                                  _HildonTouchSelector HildonTouch
 typedef struct                                  _HildonTouchSelectorClass HildonTouchSelectorClass;
 typedef struct                                  _HildonTouchSelectorPrivate HildonTouchSelectorPrivate;
 
-typedef gchar *(*HildonTouchSelectorPrintFunc)  (HildonTouchSelector * selector);
+typedef gchar *(*HildonTouchSelectorPrintFunc)  (HildonTouchSelector * selector,
+                                                 gpointer user_data);
 
 struct                                          _HildonTouchSelector
 {
-  GtkHBox parent_instance;
+  GtkVBox parent_instance;
 
   /*< private > */
   HildonTouchSelectorPrivate *priv;
@@ -64,7 +65,7 @@ struct                                          _HildonTouchSelector
 
 struct                                          _HildonTouchSelectorClass
 {
-  GtkHBoxClass parent_class;
+  GtkVBoxClass parent_class;
 
   /* signals */
   void (*changed)                               (HildonTouchSelector *selector,
@@ -78,6 +79,13 @@ struct                                          _HildonTouchSelectorClass
   gboolean (*has_multiple_selection)            (HildonTouchSelector *selector);
 };
 
+/**
+ * HildonTouchSelectorSelectionMode:
+ * @HILDON_TOUCH_SELECTOR_SELECTION_MODE_SINGLE: Users can select one item
+ * @HILDON_TOUCH_SELECTOR_SELECTION_MODE_MULTIPLE: Users can select one to many items
+ *
+ * Describes the selection mode of a #HildonTouchSelector.
+ **/
 typedef enum
 {
   HILDON_TOUCH_SELECTOR_SELECTION_MODE_SINGLE,
@@ -117,12 +125,13 @@ hildon_touch_selector_append_column             (HildonTouchSelector *selector,
                                                  GtkTreeModel        *model,
                                                  GtkCellRenderer     *cell_renderer,
                                                  ...);
-
+#ifndef HILDON_DISABLE_DEPRECATED
 void
 hildon_touch_selector_set_column_attributes     (HildonTouchSelector *selector,
                                                  gint                 num_column,
                                                  GtkCellRenderer     *cell_renderer,
                                                  ...);
+#endif
 
 gboolean
 hildon_touch_selector_remove_column             (HildonTouchSelector *selector,
@@ -167,6 +176,10 @@ hildon_touch_selector_unselect_iter             (HildonTouchSelector *selector,
                                                  gint                 column,
                                                  GtkTreeIter         *iter);
 
+void
+hildon_touch_selector_unselect_all              (HildonTouchSelector * selector,
+                                                 gint                  column);
+
 GList *
 hildon_touch_selector_get_selected_rows         (HildonTouchSelector *selector,
                                                  gint                 column);
@@ -187,12 +200,21 @@ void
 hildon_touch_selector_set_print_func            (HildonTouchSelector          *selector,
                                                  HildonTouchSelectorPrintFunc  func);
 
+void
+hildon_touch_selector_set_print_func_full       (HildonTouchSelector          *selector,
+                                                 HildonTouchSelectorPrintFunc  func,
+                                                 gpointer                      user_data,
+                                                 GDestroyNotify                destroy_func);
+
 HildonTouchSelectorPrintFunc
 hildon_touch_selector_get_print_func            (HildonTouchSelector *selector);
 
 gboolean
 hildon_touch_selector_has_multiple_selection    (HildonTouchSelector *selector);
 
+void
+hildon_touch_selector_center_on_selected        (HildonTouchSelector *selector);
+
 G_END_DECLS
 
 #endif /* __HILDON_TOUCH_SELECTOR_H__ */