[pitivi] mainwindow: Remove the obsolete viewer drag destination code
- From: Jean-FranÃois Fortin Tam <jfft src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] mainwindow: Remove the obsolete viewer drag destination code
- Date: Thu, 15 Nov 2012 13:44:20 +0000 (UTC)
commit 3decce57e768d7ad5b91931b823442369f80260b
Author: Jean-FranÃois Fortin Tam <nekohayo gmail com>
Date: Thu Nov 15 08:43:22 2012 -0500
mainwindow: Remove the obsolete viewer drag destination code
This drag and drop code doesn't work anymore, and is not even needed because
previewing clips from the media library now occurs in a separate window.
pitivi/mainwindow.py | 27 ---------------------------
1 files changed, 0 insertions(+), 27 deletions(-)
---
diff --git a/pitivi/mainwindow.py b/pitivi/mainwindow.py
index e0ddbfa..727f9b2 100644
--- a/pitivi/mainwindow.py
+++ b/pitivi/mainwindow.py
@@ -424,10 +424,6 @@ class PitiviMainWindow(Gtk.Window, Loggable):
# Viewer
self.viewer = PitiviViewer(instance, undock_action=self.undock_action)
- self.viewer.drag_dest_set(Gtk.DestDefaults.DROP | Gtk.DestDefaults.MOTION,
- [FILESOURCE_TARGET_ENTRY, URI_TARGET_ENTRY],
- Gdk.DragAction.COPY)
- self.viewer.connect("drag_data_received", self._viewerDndDataReceivedCb)
self.mainhpaned.pack2(self.viewer, resize=False, shrink=False)
# Now, the lower part: the timeline
@@ -1244,29 +1240,6 @@ class PitiviMainWindow(Gtk.Window, Loggable):
chooser.destroy()
return ret
- def _viewerDndDataReceivedCb(self, unused_widget, context, unused_x, unused_y,
- selection, targetType, ctime):
- # FIXME : This should be handled by the main application who knows how
- # to switch between pipelines.
- self.info("context:%s, targetType:%s", context, targetType)
- if targetType == TYPE_URI_LIST:
- uri = selection.data.strip().split("\n")[0].strip()
- elif targetType == TYPE_PITIVI_FILESOURCE:
- uri = selection.data
- else:
- context.finish(False, False, ctime)
- return
-
- try:
- info = self.app.current.medialibrary.getInfoFromUri(uri)
- except MediaLibraryError:
- self.app.current.medialibrary.addUris([uri])
- # FIXME Add a delay/catch signal when we start doing the discovering
- # async
- info = self.app.current.medialibrary.getInfoFromUri(uri)
- self._viewUri(info.get_uri())
- context.finish(True, False, ctime)
-
def _leavePreviewCb(self, window, unused):
window.destroy()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]