[pitivi] timeline: Raise an exception when the Timeline widget has no GES Timeline
- From: Mathieu Duponchelle <mathieudu src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] timeline: Raise an exception when the Timeline widget has no GES Timeline
- Date: Tue, 4 Feb 2014 21:49:31 +0000 (UTC)
commit aa8c856212d841f139b8748cda2764a96f4eca71
Author: Alexandru Băluț <alexandru balut gmail com>
Date: Sun Dec 22 01:55:30 2013 +0100
timeline: Raise an exception when the Timeline widget has no GES Timeline
pitivi/timeline/timeline.py | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
---
diff --git a/pitivi/timeline/timeline.py b/pitivi/timeline/timeline.py
index 2e61d38..a86ee78 100644
--- a/pitivi/timeline/timeline.py
+++ b/pitivi/timeline/timeline.py
@@ -504,7 +504,7 @@ class TimelineStage(Clutter.ScrollActor, Zoomable):
track_type = bElement.get_track_type()
y = 0
- if (track_type == GES.TrackType.AUDIO):
+ if track_type == GES.TrackType.AUDIO:
y = len(self.bTimeline.get_layers()) * (EXPANDED_SIZE + SPACING)
y += bElement.get_parent().get_layer().get_priority() * (EXPANDED_SIZE + SPACING) + SPACING
@@ -744,8 +744,7 @@ class Timeline(Gtk.VBox, Zoomable, Loggable):
"""
self.app.action_log.begin("add clip")
if self.bTimeline is None:
- self.error("No bTimeline set, this is a bug")
- return
+ raise TimelineError("No bTimeline set, this is a bug")
# FIXME we should find the longest layer instead of adding it to the
# first one
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]