diff options
author | Matthias Clasen <matthiasc@src.gnome.org> | 2002-01-30 22:29:03 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2002-01-30 22:29:03 +0000 |
commit | 4dddfb2dc62a68196f0f3e52712a25c427275b37 (patch) | |
tree | 63c2d56da9bbafaf5d90b9a87d22ef483a7ad40f /gtk/gtkviewport.c | |
parent | 95ab2a72b4ba0a84b9c430d941f778367e02584b (diff) | |
download | gtk+-4dddfb2dc62a68196f0f3e52712a25c427275b37.tar.gz |
Remove excess calls to g_return_if_fail from static and virtual functions.
Diffstat (limited to 'gtk/gtkviewport.c')
-rw-r--r-- | gtk/gtkviewport.c | 21 |
1 files changed, 4 insertions, 17 deletions
diff --git a/gtk/gtkviewport.c b/gtk/gtkviewport.c index e875c5cc9a..43aaebea3a 100644 --- a/gtk/gtkviewport.c +++ b/gtk/gtkviewport.c @@ -466,8 +466,6 @@ gtk_viewport_realize (GtkWidget *widget) gint event_mask; gint border_width; - g_return_if_fail (GTK_IS_VIEWPORT (widget)); - border_width = GTK_CONTAINER (widget)->border_width; bin = GTK_BIN (widget); @@ -545,11 +543,7 @@ gtk_viewport_realize (GtkWidget *widget) static void gtk_viewport_unrealize (GtkWidget *widget) { - GtkViewport *viewport; - - g_return_if_fail (GTK_IS_VIEWPORT (widget)); - - viewport = GTK_VIEWPORT (widget); + GtkViewport *viewport = GTK_VIEWPORT (widget); gdk_window_set_user_data (viewport->view_window, NULL); gdk_window_destroy (viewport->view_window); @@ -590,9 +584,6 @@ gtk_viewport_expose (GtkWidget *widget, GtkBin *bin; GdkEventExpose child_event; - g_return_val_if_fail (GTK_IS_VIEWPORT (widget), FALSE); - g_return_val_if_fail (event != NULL, FALSE); - if (GTK_WIDGET_DRAWABLE (widget)) { viewport = GTK_VIEWPORT (widget); @@ -624,8 +615,7 @@ gtk_viewport_add (GtkContainer *container, { GtkBin *bin; - g_return_if_fail (GTK_IS_VIEWPORT (container)); - g_return_if_fail (child != NULL); + g_return_if_fail (GTK_IS_WIDGET (child)); bin = GTK_BIN (container); g_return_if_fail (bin->child == NULL); @@ -643,9 +633,6 @@ gtk_viewport_size_request (GtkWidget *widget, GtkBin *bin; GtkRequisition child_requisition; - g_return_if_fail (GTK_IS_VIEWPORT (widget)); - g_return_if_fail (requisition != NULL); - viewport = GTK_VIEWPORT (widget); bin = GTK_BIN (widget); @@ -788,7 +775,7 @@ gtk_viewport_adjustment_changed (GtkAdjustment *adjustment, { GtkViewport *viewport; - g_return_if_fail (adjustment != NULL); + g_return_if_fail (GTK_IS_ADJUSTMENT (adjustment)); g_return_if_fail (GTK_IS_VIEWPORT (data)); viewport = GTK_VIEWPORT (data); @@ -802,7 +789,7 @@ gtk_viewport_adjustment_value_changed (GtkAdjustment *adjustment, GtkBin *bin; GtkAllocation child_allocation; - g_return_if_fail (adjustment != NULL); + g_return_if_fail (GTK_IS_ADJUSTMENT (adjustment)); g_return_if_fail (GTK_IS_VIEWPORT (data)); viewport = GTK_VIEWPORT (data); |