GtkCallback callback,
gpointer callback_data);
-static void gtk_sheet_set_scroll_adjustments (GtkSheet *sheet,
+static gboolean gtk_sheet_set_scroll_adjustments (GtkSheet *sheet,
GtkAdjustment *hadjustment,
GtkAdjustment *vadjustment);
}
-static void
+static gboolean
gtk_sheet_set_scroll_adjustments (GtkSheet *sheet,
GtkAdjustment *hadjustment,
GtkAdjustment *vadjustment)
if (sheet->vadjustment)
g_object_unref (sheet->vadjustment);
sheet->vadjustment = vadjustment;
- g_object_ref (vadjustment);
- g_signal_connect (sheet->vadjustment, "value_changed",
- G_CALLBACK (vadjustment_value_changed),
- sheet);
+ if ( vadjustment)
+ {
+ g_object_ref (vadjustment);
+
+ g_signal_connect (sheet->vadjustment, "value_changed",
+ G_CALLBACK (vadjustment_value_changed),
+ sheet);
+ }
}
if ( sheet->hadjustment != hadjustment )
{
if (sheet->hadjustment)
g_object_unref (sheet->hadjustment);
+
sheet->hadjustment = hadjustment;
- g_object_ref (hadjustment);
- g_signal_connect (sheet->hadjustment, "value_changed",
- G_CALLBACK (hadjustment_value_changed),
- sheet);
+ if ( hadjustment)
+ {
+ g_object_ref (hadjustment);
+
+ g_signal_connect (sheet->hadjustment, "value_changed",
+ G_CALLBACK (hadjustment_value_changed),
+ sheet);
+ }
}
+ return TRUE;
}
static void
sheet = GTK_SHEET (widget);
- GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED);
-
colormap = gtk_widget_get_colormap (widget);
display = gtk_widget_get_display (widget);
draw_column_title_buttons (sheet);
gtk_sheet_update_primary_selection (sheet);
+
+
+ GTK_WIDGET_SET_FLAGS (widget, GTK_REALIZED);
}
static void