[pitivi] timeline: Enable gapless mode only for development
- From: Alexandru Băluț <alexbalut src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] timeline: Enable gapless mode only for development
- Date: Thu, 26 Jan 2017 14:56:54 +0000 (UTC)
commit d60829603e32b2323c0077ff2959b505fc6547ee
Author: Alexandru Băluț <alexandru balut gmail com>
Date: Thu Jan 19 00:46:21 2017 +0100
timeline: Enable gapless mode only for development
Fixes https://phabricator.freedesktop.org/T7663
Reviewed-by: Thibault Saunier <tsaunier gnome org>
Differential Revision: https://phabricator.freedesktop.org/D1615
pitivi/timeline/timeline.py | 13 +++++++++----
1 files changed, 9 insertions(+), 4 deletions(-)
---
diff --git a/pitivi/timeline/timeline.py b/pitivi/timeline/timeline.py
index fcb1f1f..e70bf8b 100644
--- a/pitivi/timeline/timeline.py
+++ b/pitivi/timeline/timeline.py
@@ -29,6 +29,7 @@ from gi.repository import Gtk
from pitivi.autoaligner import AlignmentProgressDialog
from pitivi.autoaligner import AutoAligner
from pitivi.configure import get_ui_dir
+from pitivi.configure import in_devel
from pitivi.dialogs.prefs import PreferencesDialog
from pitivi.settings import GlobalSettings
from pitivi.timeline.elements import Clip
@@ -1070,7 +1071,8 @@ class Timeline(Gtk.EventBox, Zoomable, Loggable):
is_handle = self.editing_context.edge != GES.Edge.EDGE_NONE
parent = self.get_parent()
- if parent._shiftMask or self.app.settings.timelineAutoRipple:
+ autoripple_active = self.app.settings.timelineAutoRipple and in_devel()
+ if parent._shiftMask or autoripple_active:
return GES.EditMode.EDIT_RIPPLE
if is_handle and parent._controlMask:
return GES.EditMode.EDIT_ROLL
@@ -1444,6 +1446,8 @@ class TimelineContainer(Gtk.Grid, Zoomable, Loggable):
self.set_margin_top(SPACING)
self.show_all()
+ if not in_devel():
+ self.gapless_button.hide()
def _getLongestLayer(self):
"""Returns the longest layer."""
@@ -1502,9 +1506,10 @@ class TimelineContainer(Gtk.Grid, Zoomable, Loggable):
self.app.shortcuts.add("timeline.paste-clips", ["<Primary>v"],
_("Paste selected clips"))
- self.gapless_action = Gio.SimpleAction.new("toggle-gapless-mode", None)
- self.gapless_action.connect("activate", self._gaplessmode_toggled_cb)
- group.add_action(self.gapless_action)
+ if in_devel():
+ self.gapless_action = Gio.SimpleAction.new("toggle-gapless-mode", None)
+ self.gapless_action.connect("activate", self._gaplessmode_toggled_cb)
+ group.add_action(self.gapless_action)
# Playhead actions.
self.split_action = Gio.SimpleAction.new("split-clips", None)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]