[pitivi] transitions: Work around possible deadlocks
- From: Jean-FranÃois Fortin Tam <jfft src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] transitions: Work around possible deadlocks
- Date: Sun, 27 May 2012 19:46:49 +0000 (UTC)
commit 4e5e0031fb4ebf6f4c96aba6c0ac0514f558b457
Author: Thibault Saunier <thibault saunier collabora com>
Date: Mon May 21 13:09:40 2012 -0400
transitions: Work around possible deadlocks
pitivi/transitions.py | 13 +++++++++++--
1 files changed, 11 insertions(+), 2 deletions(-)
---
diff --git a/pitivi/transitions.py b/pitivi/transitions.py
index 3cdf3e5..07a4d36 100644
--- a/pitivi/transitions.py
+++ b/pitivi/transitions.py
@@ -162,15 +162,24 @@ class TransitionsListWidget(Signallable, gtk.VBox, Loggable):
self.props_widgets.set_sensitive(False)
else:
self.props_widgets.set_sensitive(True)
+
+ # Avoid deadlocks by seeking to 0 before changing type
+ position = self.app.current.pipeline.getPosition()
+ self.app.current.pipeline.simple_seek(0)
+
self.element.set_transition_type(transition)
- self.app.current.seeker.flush()
+
+ # Seek back into the previous position, refreshing the preview
+ self.app.current.pipeline.simple_seek(position)
return True
def _borderScaleCb(self, range_changed):
value = range_changed.get_value()
self.debug("User changed the border property to %s" % value)
self.element.set_border(int(value))
- self.app.current.seeker.flush()
+ # FIXME: Currently creates deadlocks, reactivate it when
+ # fixed
+ #self.app.current.seeker.flush(True)
def _invertCheckboxCb(self, widget):
value = widget.get_active()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]