xxx: don't claim dnd selection
authorBenjamin Otte <otte@redhat.com>
Wed, 13 Dec 2017 18:37:11 +0000 (19:37 +0100)
committerBenjamin Otte <otte@redhat.com>
Wed, 13 Dec 2017 18:37:11 +0000 (19:37 +0100)
gtk/gtkdnd.c

index 9fbcd7529f8c7ec0f1eaec6194fc0ae1b0c90be1..3a1fcad9cb473ea028283f5fe06a01355d0c82c7 100644 (file)
@@ -131,8 +131,6 @@ static GtkDragSourceInfo *gtk_drag_get_source_info   (GdkDragContext *context,
                                                       gboolean        create);
 static void               gtk_drag_clear_source_info (GdkDragContext *context);
 
-static void gtk_drag_source_release_selection  (GtkDragSourceInfo *info,
-                                                guint32            time);
 static void gtk_drag_drop                      (GtkDragSourceInfo *info,
                                                 guint32            time);
 static void gtk_drag_drop_finished             (GtkDragSourceInfo *info,
@@ -1550,7 +1548,6 @@ gtk_drag_drop_finished (GtkDragSourceInfo *info,
   gboolean success;
 
   success = (result == GTK_DRAG_RESULT_SUCCESS);
-  gtk_drag_source_release_selection  (info, time); 
 
   if (!success)
     g_signal_emit_by_name (info->widget, "drag-failed",
@@ -1560,19 +1557,6 @@ gtk_drag_drop_finished (GtkDragSourceInfo *info,
   gtk_drag_source_info_destroy (info);
 }
 
-static void
-gtk_drag_source_release_selection (GtkDragSourceInfo *info,
-                                   guint32            time)
-{
-  GdkDisplay *display = gtk_widget_get_display (info->widget);
-  GdkAtom selection;
-  
-  selection = gdk_drag_get_selection (info->context);
-  if (selection &&
-      gdk_selection_owner_get_for_display (display, selection) == gtk_widget_get_window (info->ipc_widget))
-    gtk_selection_owner_set_for_display (display, NULL, selection, time);
-}
-
 static void
 gtk_drag_drop (GtkDragSourceInfo *info, 
                guint32            time)
@@ -1734,8 +1718,6 @@ static void
 gtk_drag_context_dnd_finished_cb (GdkDragContext    *context,
                                   GtkDragSourceInfo *info)
 {
-  gtk_drag_source_release_selection (info, GDK_CURRENT_TIME);
-
   if (gdk_drag_context_get_selected_action (context) == GDK_ACTION_MOVE)
     {
       g_signal_emit_by_name (info->widget,