2009-03-05 Alberto Garcia <agarcia@igalia.com>
authorAlberto Garcia <agarcia@igalia.com>
Thu, 5 Mar 2009 18:22:34 +0000 (18:22 +0000)
committerAlberto Garcia <agarcia@igalia.com>
Thu, 5 Mar 2009 18:22:34 +0000 (18:22 +0000)
* src/hildon-time-button.c (hildon_time_button_new_step):
Use the "touch-selector" property to set the selector directly
when creating the object.

ChangeLog
src/hildon-time-button.c

index 3eaaabb..9403ff0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2009-03-05  Alberto Garcia  <agarcia@igalia.com>
+
+       * src/hildon-time-button.c (hildon_time_button_new_step):
+       Use the "touch-selector" property to set the selector directly
+       when creating the object.
+
 2009-03-05  Alejandro G. Castro  <alex@igalia.com>
 
        Added a new example application that allows tuning the pannable
index f180f8a..86f13f2 100644 (file)
@@ -127,18 +127,12 @@ hildon_time_button_new_step (HildonSizeType          size,
                              HildonButtonArrangement arrangement,
                              guint                   minutes_step)
 {
-  GtkWidget *button;
-  GtkWidget *time_selector;
-
-  button = g_object_new (HILDON_TYPE_TIME_BUTTON,
-                         "title", _("wdgt_ti_time"), "arrangement", arrangement, "size", size, NULL);
-
-  time_selector = hildon_time_selector_new_step (minutes_step);
-
-  hildon_picker_button_set_selector (HILDON_PICKER_BUTTON (button),
-                                     HILDON_TOUCH_SELECTOR (time_selector));
-
-  return button;
+  return g_object_new (HILDON_TYPE_TIME_BUTTON,
+                       "title", _("wdgt_ti_time"),
+                       "arrangement", arrangement,
+                       "size", size,
+                       "touch-selector", hildon_time_selector_new_step (minutes_step),
+                       NULL);
 }
 
 /**