From 266f3fbd5f0a40382bac06828922317d1eabf67f Mon Sep 17 00:00:00 2001
From: Alexander Schwinn <alexxcons@xfce.org>
Date: Wed, 26 Sep 2018 23:17:48 +0200
Subject: [PATCH] Fixed compiler warning, removed unused code and added comment
 to probably unused motion_notify_event

---
 thunar/thunar-standard-view.c | 17 ++---------------
 1 file changed, 2 insertions(+), 15 deletions(-)

diff --git a/thunar/thunar-standard-view.c b/thunar/thunar-standard-view.c
index 66de2127e..958982316 100644
--- a/thunar/thunar-standard-view.c
+++ b/thunar/thunar-standard-view.c
@@ -3103,9 +3103,6 @@ thunar_standard_view_motion_notify_event (GtkWidget          *view,
                                           GdkEventMotion     *event,
                                           ThunarStandardView *standard_view)
 {
-  GdkDragContext *context;
-  GtkTargetList  *target_list;
-
   _thunar_return_val_if_fail (THUNAR_IS_STANDARD_VIEW (standard_view), FALSE);
   _thunar_return_val_if_fail (standard_view->priv->drag_timer_id != 0, FALSE);
 
@@ -3115,20 +3112,10 @@ thunar_standard_view_motion_notify_event (GtkWidget          *view,
       /* cancel the drag timer, as we won't popup the menu anymore */
       g_source_remove (standard_view->priv->drag_timer_id);
 
-      /* allocate the drag context (preferred action is to ask the user) */
-      target_list = gtk_target_list_new (drag_targets, G_N_ELEMENTS (drag_targets));
-      context = gtk_drag_begin_with_coordinates (view, target_list,
-                                                 GDK_ACTION_COPY |
-                                                 GDK_ACTION_MOVE |
-                                                 GDK_ACTION_LINK |
-                                                 GDK_ACTION_ASK,
-                                                 3, (GdkEvent *) event, -1, -1);
-
       /* FIXME
-      gdk_drag_context_set_suggested_action (context, GDK_ACTION_ASK);
+       * - according to doc, the GdkWindow associated to the widget needs to enable the GDK_POINTER_MOTION_MASK mask to use this event.
+       * We dont do that. So possibly this is dead code, which can be removed ?
       */
-      gtk_target_list_unref (target_list);
-
       return TRUE;
     }
 
-- 
GitLab