[pitivi] previewers: Pythonic timestamps queue generation
- From: Mathieu Duponchelle <mathieudu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] previewers: Pythonic timestamps queue generation
- Date: Wed, 25 Dec 2013 20:32:17 +0000 (UTC)
commit 3d7aaff7f55c2766b42056ce4587526baf52f8cb
Author: Alexandru Băluț <alexandru balut gmail com>
Date: Tue Dec 10 22:37:31 2013 +0100
previewers: Pythonic timestamps queue generation
pitivi/timeline/previewers.py | 6 +-----
1 files changed, 1 insertions(+), 5 deletions(-)
---
diff --git a/pitivi/timeline/previewers.py b/pitivi/timeline/previewers.py
index 5a5dc20..6160809 100644
--- a/pitivi/timeline/previewers.py
+++ b/pitivi/timeline/previewers.py
@@ -271,7 +271,6 @@ class VideoPreviewer(Clutter.ScrollActor, PreviewGenerator, Zoomable, Loggable):
def _startThumbnailing(self):
self.debug('Now generating thumbnails for "%s"' % filename_from_uri(self.uri))
- self.queue = []
query_success, duration = self.pipeline.query_duration(Gst.Format.TIME)
if not query_success or duration == -1:
self.debug("Could not determine duration of %s" % self.uri)
@@ -279,10 +278,7 @@ class VideoPreviewer(Clutter.ScrollActor, PreviewGenerator, Zoomable, Loggable):
else:
self.duration = duration
- current_time = 0
- while current_time < duration:
- self.queue.append(current_time)
- current_time += self.thumb_period
+ self.queue = range(0, duration, self.thumb_period)
self._checkCPU()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]