[gnome-todo] task-row: Remove drag-end callback



commit c46aaf7779baaa76e9d7d4383571f18a3bf001eb
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Mon May 3 18:32:24 2021 -0300

    task-row: Remove drag-end callback
    
    Most of the times, the task row is destroyed after
    the drag ends. When it happens, this callback triggers
    a crash in GTK4.
    
    We don't really need to do what the callback does, so
    let's just remove it for now.

 src/gui/gtd-task-row.c | 15 ---------------
 1 file changed, 15 deletions(-)
---
diff --git a/src/gui/gtd-task-row.c b/src/gui/gtd-task-row.c
index 0c7e43bc..c9865cdb 100644
--- a/src/gui/gtd-task-row.c
+++ b/src/gui/gtd-task-row.c
@@ -273,20 +273,6 @@ on_drag_begin_cb (GtkDragSource *source,
   GTD_EXIT;
 }
 
-static void
-on_drag_end_cb (GtkDragSource *source,
-                GdkDrag       *drag,
-                gboolean       delete_data,
-                GtdTaskRow    *self)
-{
-  GTD_ENTRY;
-
-  gtk_widget_set_cursor_from_name (GTK_WIDGET (self), NULL);
-  gtk_widget_show (GTK_WIDGET (self));
-
-  GTD_EXIT;
-}
-
 static gboolean
 on_drag_cancelled_cb (GtkDragSource       *source,
                       GdkDrag             *drag,
@@ -612,7 +598,6 @@ gtd_task_row_init (GtdTaskRow *self)
   g_signal_connect (drag_source, "prepare", G_CALLBACK (on_drag_prepare_cb), self);
   g_signal_connect (drag_source, "drag-begin", G_CALLBACK (on_drag_begin_cb), self);
   g_signal_connect (drag_source, "drag-cancel", G_CALLBACK (on_drag_cancelled_cb), self);
-  g_signal_connect (drag_source, "drag-end", G_CALLBACK (on_drag_end_cb), self);
 
   gtk_widget_add_controller (GTK_WIDGET (self), GTK_EVENT_CONTROLLER (drag_source));
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]