[gnome-music/wip/mschraal/gtk4: 69/69] songwidget: Disable DnD



commit 18a09493b59b091270d653191778da719e74d4ac
Author: Marinus Schraal <mschraal gnome org>
Date:   Fri May 1 14:07:04 2020 +0200

    songwidget: Disable DnD
    
    It got reworked.

 gnomemusic/widgets/songwidget.py | 26 +++++++++++++-------------
 1 file changed, 13 insertions(+), 13 deletions(-)
---
diff --git a/gnomemusic/widgets/songwidget.py b/gnomemusic/widgets/songwidget.py
index 41f80dfa..c53687ca 100644
--- a/gnomemusic/widgets/songwidget.py
+++ b/gnomemusic/widgets/songwidget.py
@@ -24,7 +24,7 @@
 
 from enum import IntEnum
 
-from gi.repository import Gdk, GObject, Gtk
+from gi.repository import GObject, Gtk
 
 from gnomemusic import utils
 from gnomemusic.coresong import CoreSong
@@ -147,18 +147,18 @@ class SongWidget(Gtk.Box):
         if not self.props.coresong.props.is_tracker:
             self._star_stack.props.visible_child_name = "empty"
 
-        if can_dnd is True:
-            self._dnd_eventbox.props.visible = True
-            self._drag_widget = None
-            entries = [
-                Gtk.TargetEntry.new(
-                    "GTK_EVENT_BOX", Gtk.TargetFlags.SAME_APP, 0)
-            ]
-            self._dnd_eventbox.drag_source_set(
-                Gdk.ModifierType.BUTTON1_MASK, entries,
-                Gdk.DragAction.MOVE)
-            self.drag_dest_set(
-                Gtk.DestDefaults.ALL, entries, Gdk.DragAction.MOVE)
+        # if can_dnd is True:
+        #     self._dnd_eventbox.props.visible = True
+        #     self._drag_widget = None
+        #     entries = [
+        #         Gtk.TargetEntry.new(
+        #             "GTK_EVENT_BOX", Gtk.TargetFlags.SAME_APP, 0)
+        #     ]
+        #     self._dnd_eventbox.drag_source_set(
+        #         Gdk.ModifierType.BUTTON1_MASK, entries,
+        #         Gdk.DragAction.MOVE)
+        #     self.drag_dest_set(
+        #         Gtk.DestDefaults.ALL, entries, Gdk.DragAction.MOVE)
 
     # @Gtk.Template.Callback()
     # def _on_selection_changed(self, klass, value):


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