[pitivi: 3/11] set canvas bounds to be only as large as the window allocation



commit cd7025eac3a1ea217c22b541d7f83e901d501cae
Author: Brandon Lewis <brandon_lewis alum berkeley edu>
Date:   Fri Oct 1 14:43:52 2010 +0100

    set canvas bounds to be only as large as the window allocation

 pitivi/ui/timelinecanvas.py |    6 ++----
 1 files changed, 2 insertions(+), 4 deletions(-)
---
diff --git a/pitivi/ui/timelinecanvas.py b/pitivi/ui/timelinecanvas.py
index b4ebede..30d67b8 100644
--- a/pitivi/ui/timelinecanvas.py
+++ b/pitivi/ui/timelinecanvas.py
@@ -306,10 +306,8 @@ class TimelineCanvas(goocanvas.Canvas, Zoomable, Loggable):
 
     def _request_size(self):
         alloc = self.get_allocation()
-        w = Zoomable.nsToPixel(self.max_duration)
-        h = max(self._height, alloc.height)
-        self.set_bounds(0, 0, w, h)
-        self._playhead.props.height = h + 10
+        self.set_bounds(0, 0, alloc.width, alloc.height)
+        self._playhead.props.height = alloc.height + 10
 
     def zoomChanged(self):
         if self.timeline:



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]