[pitivi] medialibrary: Do not sanitize URIs it is not needed aymore
- From: Thibault Saunier <tsaunier src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] medialibrary: Do not sanitize URIs it is not needed aymore
- Date: Wed, 2 Apr 2014 15:28:42 +0000 (UTC)
commit 5c2a5b9151b21691fd960c5026c01b5264332818
Author: Thibault Saunier <tsaunier gnome org>
Date: Tue Apr 1 11:08:53 2014 +0200
medialibrary: Do not sanitize URIs it is not needed aymore
This broke after the pass to the py2to3 script and we actually do not
need it as we are now using DragContext.get_uris() to get the URI
and this provide us with a clean list of ready to be used URIs
pitivi/medialibrary.py | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/medialibrary.py b/pitivi/medialibrary.py
index d0611f2..e48b856 100644
--- a/pitivi/medialibrary.py
+++ b/pitivi/medialibrary.py
@@ -324,15 +324,16 @@ class MediaLibraryWidget(Gtk.VBox, Loggable):
return 1
def getAssetForUri(self, uri):
- # Sanitization
- uri = [c for c in uri if c != '\n' and c != '\r']
for path in self.modelFilter:
asset = path[COL_ASSET]
info = asset.get_info()
asset_uri = info.get_uri()
if asset_uri == uri:
+ self.debug("Found asset: %s for uri: %s" % (asset, uri))
return asset
+ self.warning("Did not find any asser for uri: %s" % (uri))
+
def _setup_view_for_drag_and_drop(self, view, target_entries):
view.drag_source_set(0, [], Gdk.DragAction.COPY)
view.enable_model_drag_source(Gdk.ModifierType.BUTTON1_MASK, target_entries, Gdk.DragAction.COPY)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]