[pitivi] pipeline: Remove duplicate check of position value
- From: Thibault Saunier <tsaunier src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] pipeline: Remove duplicate check of position value
- Date: Wed, 24 Sep 2014 17:05:26 +0000 (UTC)
commit deb3d5e7d0554f53a11dff1ae51e412cad631779
Author: Alexandru Băluț <alexandru balut gmail com>
Date: Mon Apr 28 00:37:00 2014 +0200
pipeline: Remove duplicate check of position value
pitivi/utils/pipeline.py | 9 ++++-----
1 files changed, 4 insertions(+), 5 deletions(-)
---
diff --git a/pitivi/utils/pipeline.py b/pitivi/utils/pipeline.py
index 28f62de..dbe4cb6 100644
--- a/pitivi/utils/pipeline.py
+++ b/pitivi/utils/pipeline.py
@@ -406,9 +406,8 @@ class SimplePipeline(GObject.Object, Loggable):
self.debug("seeking successful")
self.emit('position', position)
- def seekRelative(self, time):
- seekvalue = max(0, min(self.getPosition() + time, self.getDuration()))
- self.simple_seek(seekvalue)
+ def seekRelative(self, time_delta):
+ self.simple_seek(self.getPosition() + time_delta)
# Private methods
@@ -561,8 +560,8 @@ class Pipeline(GES.Pipeline, SimplePipeline):
self._seeker.disconnect_by_func(self._seekCb)
SimplePipeline.release(self)
- def _seekRelativeCb(self, unused_seeker, time):
- self.seekRelative(time)
+ def _seekRelativeCb(self, unused_seeker, time_delta):
+ self.seekRelative(time_delta)
def stepFrame(self, framerate, frames_offset):
"""
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]