[pitivi] Rehook right click menu items for the layers.
- From: Jean-François Fortin Tam <jfft src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi] Rehook right click menu items for the layers.
- Date: Wed, 24 Apr 2013 18:03:31 +0000 (UTC)
commit 3fa18cbcbf7f3504e0eff16e4048ec058ab9c0d4
Author: Mathieu Duponchelle <mathieu duponchelle epitech eu>
Date: Thu Apr 18 04:05:05 2013 +0200
Rehook right click menu items for the layers.
Also make the code a little less stupid.
pitivi/timeline/layer.py | 9 ++++-----
1 files changed, 4 insertions(+), 5 deletions(-)
---
diff --git a/pitivi/timeline/layer.py b/pitivi/timeline/layer.py
index b518998..5b06ba2 100644
--- a/pitivi/timeline/layer.py
+++ b/pitivi/timeline/layer.py
@@ -220,18 +220,17 @@ class BaseLayerControl(Gtk.VBox, Loggable):
timeline.remove_layer(self.layer)
def _moveLayerCb(self, widget, step):
- index = self._app.gui.timeline_ui.controls.getControlIndex(self)
+ index = self.layer.get_priority()
if abs(step) == 1:
index += step
elif step == -2:
index = 0
else:
- index = len(self.layer.get_timeline().get_layers())
+ index = len(self.layer.get_timeline().get_layers()) - 1
# if audio, set last position
- if type(self) == AudioLayerControl:
- index *= 2
- self._app.gui.timeline_ui.controls.moveControlWidget(self, index)
+ self._app.moveLayer(self, index)
+# self._app.timeline._container.app.gui.timeline_ui.controls.moveControlWidget(self, index)
def getHeight(self):
return self.get_allocation().height
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]