From d8cffa93506a451b2d046e9318e34617a871e9d5 Mon Sep 17 00:00:00 2001 From: Zander Brown Date: Sun, 21 May 2023 19:02:16 +0100 Subject: [PATCH] marshallers: fix up some mistypes in drags Fix: ff330668cfee65c9b969911adb16f7d5a2bb6749 --- gtk/gtkdragsource.c | 8 ++++---- gtk/gtkdroptargetasync.c | 18 +++++++++--------- gtk/gtkmarshalers.list | 3 +-- 3 files changed, 14 insertions(+), 15 deletions(-) diff --git a/gtk/gtkdragsource.c b/gtk/gtkdragsource.c index bb7d279cb2..ce621ef9f1 100644 --- a/gtk/gtkdragsource.c +++ b/gtk/gtkdragsource.c @@ -19,7 +19,7 @@ * Modified by the GTK+ Team and others 1997-2000. See the AUTHORS * file for a list of people on the GTK+ Team. See the ChangeLog * files for a list of changes. These files are distributed with - * GTK+ at ftp://ftp.gtk.org/pub/gtk/. + * GTK+ at ftp://ftp.gtk.org/pub/gtk/. */ #include "config.h" @@ -207,7 +207,7 @@ gtk_drag_source_set_property (GObject *object, GParamSpec *pspec) { GtkDragSource *source = GTK_DRAG_SOURCE (object); - + switch (prop_id) { case PROP_CONTENT: @@ -424,13 +424,13 @@ gtk_drag_source_class_init (GtkDragSourceClass *class) G_SIGNAL_RUN_LAST, 0, NULL, NULL, - _gtk_marshal_OBJECT__BOOLEAN, + _gtk_marshal_VOID__OBJECT_BOOLEAN, G_TYPE_NONE, 2, GDK_TYPE_DRAG, G_TYPE_BOOLEAN); g_signal_set_va_marshaller (signals[DRAG_END], GTK_TYPE_DRAG_SOURCE, - _gtk_marshal_OBJECT__BOOLEANv); + _gtk_marshal_VOID__OBJECT_BOOLEANv); /** * GtkDragSource::drag-cancel: diff --git a/gtk/gtkdroptargetasync.c b/gtk/gtkdroptargetasync.c index 0fbab88d31..862fa12590 100644 --- a/gtk/gtkdroptargetasync.c +++ b/gtk/gtkdroptargetasync.c @@ -150,13 +150,13 @@ make_action_unique (GdkDragAction actions) if (actions & GDK_ACTION_MOVE) return GDK_ACTION_MOVE; - + if (actions & GDK_ACTION_LINK) return GDK_ACTION_LINK; return 0; } - + static GdkDragAction gtk_drop_target_async_drag_enter (GtkDropTargetAsync *self, GdkDrop *drop, @@ -166,7 +166,7 @@ gtk_drop_target_async_drag_enter (GtkDropTargetAsync *self, return make_action_unique (self->actions & gdk_drop_get_actions (drop)); } -static GdkDragAction +static GdkDragAction gtk_drop_target_async_drag_motion (GtkDropTargetAsync *self, GdkDrop *drop, double x, @@ -457,12 +457,12 @@ gtk_drop_target_async_class_init (GtkDropTargetAsyncClass *class) G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkDropTargetAsyncClass, drag_enter), g_signal_accumulator_first_wins, NULL, - _gtk_marshal_ENUM__OBJECT_DOUBLE_DOUBLE, + _gtk_marshal_FLAGS__OBJECT_DOUBLE_DOUBLE, GDK_TYPE_DRAG_ACTION, 3, GDK_TYPE_DROP, G_TYPE_DOUBLE, G_TYPE_DOUBLE); g_signal_set_va_marshaller (signals[DRAG_ENTER], GTK_TYPE_DROP_TARGET_ASYNC, - _gtk_marshal_ENUM__OBJECT_DOUBLE_DOUBLEv); + _gtk_marshal_FLAGS__OBJECT_DOUBLE_DOUBLEv); /** * GtkDropTargetAsync::drag-motion: @@ -481,12 +481,12 @@ gtk_drop_target_async_class_init (GtkDropTargetAsyncClass *class) G_SIGNAL_RUN_LAST, G_STRUCT_OFFSET (GtkDropTargetAsyncClass, drag_motion), g_signal_accumulator_first_wins, NULL, - _gtk_marshal_ENUM__OBJECT_DOUBLE_DOUBLE, + _gtk_marshal_FLAGS__OBJECT_DOUBLE_DOUBLE, GDK_TYPE_DRAG_ACTION, 3, GDK_TYPE_DROP, G_TYPE_DOUBLE, G_TYPE_DOUBLE); g_signal_set_va_marshaller (signals[DRAG_MOTION], GTK_TYPE_DROP_TARGET_ASYNC, - _gtk_marshal_ENUM__OBJECT_DOUBLE_DOUBLEv); + _gtk_marshal_FLAGS__OBJECT_DOUBLE_DOUBLEv); /** * GtkDropTargetAsync::drag-leave: @@ -617,7 +617,7 @@ GdkContentFormats * gtk_drop_target_async_get_formats (GtkDropTargetAsync *self) { g_return_val_if_fail (GTK_IS_DROP_TARGET_ASYNC (self), NULL); - + return self->formats; } @@ -633,7 +633,7 @@ gtk_drop_target_async_set_actions (GtkDropTargetAsync *self, GdkDragAction actions) { g_return_if_fail (GTK_IS_DROP_TARGET_ASYNC (self)); - + if (self->actions == actions) return; diff --git a/gtk/gtkmarshalers.list b/gtk/gtkmarshalers.list index 10536eff73..8cd1fdc15c 100644 --- a/gtk/gtkmarshalers.list +++ b/gtk/gtkmarshalers.list @@ -42,12 +42,11 @@ BOOLEAN:OBJECT,OBJECT,OBJECT BOOLEAN:STRING BOOLEAN:UINT,UINT,FLAGS BOOLEAN:VOID -ENUM:OBJECT,DOUBLE,DOUBLE +FLAGS:OBJECT,DOUBLE,DOUBLE FLAGS:DOUBLE,DOUBLE INT:INT INT:OBJECT,OBJECT,POINTER INT:POINTER -OBJECT:BOOLEAN OBJECT:DOUBLE,DOUBLE OBJECT:OBJECT OBJECT:VOID