[pitivi/gtktimeline] layer: Do not forward clicks to the timeline
- From: Thibault Saunier <tsaunier src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pitivi/gtktimeline] layer: Do not forward clicks to the timeline
- Date: Tue, 19 May 2015 19:31:09 +0000 (UTC)
commit 93f76534d20e8ceecce87a637c830174778aa1ad
Author: Thibault Saunier <tsaunier gnome org>
Date: Tue May 19 16:25:09 2015 +0200
layer: Do not forward clicks to the timeline
Summary:
Avoiding us to seek when the layer action menu button is clicked
Avoiding the creation of a context when clicking on the layer control
area
Depends on D190
Reviewers: Mathieu_Du
Differential Revision: http://phabricator.freedesktop.org/D191
pitivi/timeline/layer.py | 6 ++++++
1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/pitivi/timeline/layer.py b/pitivi/timeline/layer.py
index c8df409..702b611 100644
--- a/pitivi/timeline/layer.py
+++ b/pitivi/timeline/layer.py
@@ -257,6 +257,8 @@ class LayerControls(Gtk.Bin, Loggable):
popover.add(popup)
menubutton.set_popover(popover)
menubutton.props.direction = Gtk.ArrowType.RIGHT
+ self.connect("button-release-event", self._ignoreClicksCb)
+ self.connect("button-press-event", self._ignoreClicksCb)
self._hbox.add(menubutton)
self._hbox.add(self._vbox)
popover.props.position = Gtk.PositionType.LEFT
@@ -286,6 +288,10 @@ class LayerControls(Gtk.Bin, Loggable):
bTimeline.get_asset().pipeline.commit_timeline()
self.app.action_log.commit()
+ def _ignoreClicksCb(self, unused_widget, event):
+ self.debug("Do not pass event %s to the timeline" % event)
+ return True
+
def _moveLayerCb(self, unused_widget, step):
index = self.bLayer.get_priority()
if abs(step) == 1:
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]