diff options
author | Benjamin Otte <otte@redhat.com> | 2018-03-09 06:14:59 +0100 |
---|---|---|
committer | Carlos Garnacho <carlosg@gnome.org> | 2018-04-26 17:59:42 +0200 |
commit | 4ddc94b293504b56c0106b0177c36c8efd2d3a57 (patch) | |
tree | b620c608c025e287685a04afa8429d5541e12274 /examples | |
parent | 71991270b047c66e7c14a65aaa70703527c978cf (diff) | |
download | gtk+-4ddc94b293504b56c0106b0177c36c8efd2d3a57.tar.gz |
multipressgesture: Port to new API model
Diffstat (limited to 'examples')
-rw-r--r-- | examples/drawing.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/drawing.c b/examples/drawing.c index 7bf1bb688e..0713b81611 100644 --- a/examples/drawing.c +++ b/examples/drawing.c @@ -165,9 +165,9 @@ activate (GtkApplication *app, g_signal_connect (drag, "drag-update", G_CALLBACK (drag_update), drawing_area); g_signal_connect (drag, "drag-end", G_CALLBACK (drag_end), drawing_area); - press = gtk_gesture_multi_press_new (drawing_area); + press = gtk_gesture_multi_press_new (); gtk_gesture_single_set_button (GTK_GESTURE_SINGLE (press), GDK_BUTTON_SECONDARY); - g_object_set_data_full (G_OBJECT (drawing_area), "press", press, g_object_unref); + gtk_widget_add_controller (drawing_area, GTK_EVENT_CONTROLLER (press)); g_signal_connect (press, "pressed", G_CALLBACK (pressed), drawing_area); |