From 9ed155c456dc719689d285841d8944c9e36355f0 Mon Sep 17 00:00:00 2001 From: Calum Lind Date: Sun, 27 Nov 2011 01:44:30 +0000 Subject: [PATCH] Update to the DnD windows fix Found that the original fix worked fine with GTK v2.24 but with v2.16 on Windows get_uris is empty --- deluge/ui/gtkui/mainwindow.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/deluge/ui/gtkui/mainwindow.py b/deluge/ui/gtkui/mainwindow.py index ad979c3ee..ea5191fc8 100644 --- a/deluge/ui/gtkui/mainwindow.py +++ b/deluge/ui/gtkui/mainwindow.py @@ -213,8 +213,11 @@ class MainWindow(component.Component): self.config["window_pane_position"] = self.vpaned.get_position() def on_drag_data_received_event(self, widget, drag_context, x, y, selection_data, info, timestamp): - log.debug("Selection(s) dropped on main window %s", selection_data.get_uris()) - process_args(selection_data.get_uris()) + log.debug("Selection(s) dropped on main window %s", selection_data.data) + if selection_data.get_uris(): + process_args(selection_data.get_uris()) + else: + process_args(selection_data.data.split()) drag_context.finish(True, True) def on_expose_event(self, widget, event):