[pitivi] Force a minimum size on the viewer only when running at resolution >= Xx800



commit 73484d7ef7ac431957a2def7f9e03748c139e643
Author: Alessandro Decina <alessandro d gmail com>
Date:   Wed Sep 2 15:29:50 2009 +0200

    Force a minimum size on the viewer only when running at resolution >= Xx800

 pitivi/ui/viewer.py |   18 +++++++++++-------
 1 files changed, 11 insertions(+), 7 deletions(-)
---
diff --git a/pitivi/ui/viewer.py b/pitivi/ui/viewer.py
index ac1ad6a..80526e4 100644
--- a/pitivi/ui/viewer.py
+++ b/pitivi/ui/viewer.py
@@ -22,6 +22,7 @@
 
 import gobject
 import gtk
+from gtk import gdk
 import gst
 
 from pitivi.action import ViewAction
@@ -263,13 +264,16 @@ class PitiviViewer(gtk.VBox, Loggable):
         bbox.pack_start(self.timelabel, expand=False, padding=10)
         self._haveUI = True
 
-        # show the controls and force the aspect frame to have at least the same
-        # width (+110, which is a magic number to minimize dead padding).
-        bbox.show_all()
-        width, height = bbox.size_request()
-        width += 110
-        height = width / self.aframe.props.ratio
-        self.aframe.set_size_request(width , height)
+        screen = gdk.screen_get_default()
+        height = screen.get_height()
+        if height >= 800:
+            # show the controls and force the aspect frame to have at least the same
+            # width (+110, which is a magic number to minimize dead padding).
+            bbox.show_all()
+            width, height = bbox.size_request()
+            width += 110
+            height = width / self.aframe.props.ratio
+            self.aframe.set_size_request(width , height)
 
     def showControls(self):
         if not self.action:



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