[pitivi: 7/12] discoverer: try a better fix for subtitles



commit 040a4f950fa2b421a076b3d5053176b9c2407c7d
Author: Alessandro Decina <alessandro d gmail com>
Date:   Sat Mar 6 01:35:50 2010 +0100

    discoverer: try a better fix for subtitles

 pitivi/discoverer.py |    5 +++--
 1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/discoverer.py b/pitivi/discoverer.py
index fa24d18..4b0d525 100644
--- a/pitivi/discoverer.py
+++ b/pitivi/discoverer.py
@@ -41,7 +41,7 @@ from pitivi.log.loggable import Loggable
 from pitivi.factories.file import FileSourceFactory, PictureFileSourceFactory
 from pitivi.stream import get_stream_for_pad
 from pitivi.signalinterface import Signallable
-from pitivi.stream import VideoStream
+from pitivi.stream import VideoStream, TextStream
 from pitivi.settings import xdg_cache_home
 
 # FIXME: We need to store more information regarding streams
@@ -633,7 +633,8 @@ class Discoverer(Signallable, Loggable):
             element.sync_state_with_parent()
 
     def _newPadCb(self, pad):
-        if 'text' in pad.get_caps():
+        stream = get_stream_for_pad(pad)
+        if isinstance(stream, TextStream):
             self.info("skipping subtitle pad")
             return
 



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