(hildon_scroll_area_destroy): one-instruction function:
removed. Call g_free directly.
+ minor cleanup
+ (hildon_scroll_area_size_allocate):When a scrollbar appears to the
+ right edge of window, size of the child is also shrinked. 'fixed'
+ does not automatically update this data -> Doing it manually.
* hildon-widgets/hildon-date-editor.h: added
HildonDateEditorErrorType error enumeration type, removed signal
typedef struct
{
GtkWidget *fixed;
+ GtkWidget *swouter;
GtkWidget *swinner;
GtkWidget *child;
gtk_fixed_put (GTK_FIXED (fixed), swi, 0, 0);
sc->fixed = fixed;
+ sc->swouter = sw;
sc->swinner = swi;
sc->child = child;
sc->outadj = gtk_scrolled_window_get_vadjustment (GTK_SCROLLED_WINDOW (sw));
sc->fixed->allocation.y + adjustment->value);
}
+__inline__ static gint calculate_width (HildonScrollArea *sc)
+{
+ GtkScrolledWindow *scwin = GTK_SCROLLED_WINDOW (sc->swouter);
+ return (scwin->hscrollbar_visible * scwin->hscrollbar->allocation.width);
+}
+
static void hildon_scroll_area_size_allocate (GtkWidget *widget,
GtkAllocation *allocation,
HildonScrollArea *sc)
{
- g_signal_handlers_disconnect_by_func (widget,
- (void*)hildon_scroll_area_size_allocate,
- sc);
+ gtk_widget_set_size_request (sc->fixed, calculate_width (sc), sc->fixed->allocation.height);
gtk_widget_set_size_request (sc->child, sc->fixed->allocation.width, -1);
}