From 3bb404f40c97f757988551f23fa1434d01000f54 Mon Sep 17 00:00:00 2001 From: Matthias Clasen Date: Tue, 27 May 2014 14:30:47 -0400 Subject: Don't assert in gtk_event_controller_constructed This prevents some of our generic object implementation tests from working with gesture objects. Instead, add g_return_if_fail checks in all the gesture constructors. --- gtk/gtkgestureswipe.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'gtk/gtkgestureswipe.c') diff --git a/gtk/gtkgestureswipe.c b/gtk/gtkgestureswipe.c index 211789d2c6..0ca5bb35dc 100644 --- a/gtk/gtkgestureswipe.c +++ b/gtk/gtkgestureswipe.c @@ -237,6 +237,8 @@ gtk_gesture_swipe_init (GtkGestureSwipe *gesture) GtkGesture * gtk_gesture_swipe_new (GtkWidget *widget) { + g_return_val_if_fail (GTK_IS_WIDGET (widget), NULL); + return g_object_new (GTK_TYPE_GESTURE_SWIPE, "widget", widget, NULL); -- cgit v1.2.1