summaryrefslogtreecommitdiff
path: root/geneticone
diff options
context:
space:
mode:
authornecoro <>2006-10-14 20:40:35 +0000
committernecoro <>2006-10-14 20:40:35 +0000
commita6d2a347e69f02c283a33dad6d5f6d90388a6af5 (patch)
tree67e4d2f09cd4d9a5651a1c43ea2f3f0b4742b231 /geneticone
parentc025c838753f264e8f802a4f5f47908feefebea6 (diff)
downloadportato-a6d2a347e69f02c283a33dad6d5f6d90388a6af5.tar.gz
portato-a6d2a347e69f02c283a33dad6d5f6d90388a6af5.tar.bz2
portato-a6d2a347e69f02c283a33dad6d5f6d90388a6af5.zip
Set min height to 600 if maxHeight is smaller then 800
Diffstat (limited to 'geneticone')
-rw-r--r--geneticone/gui/gui_helper.py2
-rw-r--r--geneticone/gui/windows.py9
2 files changed, 7 insertions, 4 deletions
diff --git a/geneticone/gui/gui_helper.py b/geneticone/gui/gui_helper.py
index 449fa9c..c6bcf53 100644
--- a/geneticone/gui/gui_helper.py
+++ b/geneticone/gui/gui_helper.py
@@ -260,7 +260,7 @@ class EmergeQueue:
# for the beginning: let us create a package object - but it is not guaranteed, that it actually exists in portage
pkg = backend.Package(cpv)
- masked = not (pkg.is_masked() or pkg.is_testing(allowed=True)) # <-- why am I doing this? FIXME
+ masked = not (pkg.is_masked() or pkg.is_testing(allowed=True)) # we are setting this to True in case we have unmasked it already, but portage does not know this
# and now try to find it in portage
pkg = backend.find_packages("="+cpv, masked = masked)
diff --git a/geneticone/gui/windows.py b/geneticone/gui/windows.py
index a08fe16..4861b89 100644
--- a/geneticone/gui/windows.py
+++ b/geneticone/gui/windows.py
@@ -158,7 +158,7 @@ class SearchWindow (AbstractDialog):
"""Emulates a ok-button-click."""
keyname = gtk.gdk.keyval_name(event.keyval)
if keyname == "Return": # take it as an "OK" if Enter is pressed
- self.cb_ok_btn_clicked(self,widget)
+ self.cb_ok_btn_clicked(widget)
return True
else:
return False
@@ -575,8 +575,11 @@ class MainWindow:
self.window.set_title(("Genetic/One (%s)" % VERSION))
self.window.connect("destroy", self.cb_destroy)
self.window.set_border_width(2)
- self.window.set_geometry_hints (self.window, min_width = 600, min_height = 800, max_height = gtk.gdk.screen_height(), max_width = gtk.gdk.screen_width())
self.window.set_resizable(True)
+
+ mHeight = 800
+ if gtk.gdk.screen_height() <= 800: mHeight = 600
+ self.window.set_geometry_hints (self.window, min_width = 600, min_height = mHeight, max_height = gtk.gdk.screen_height(), max_width = gtk.gdk.screen_width())
# package db
self.db = Database()
@@ -614,7 +617,7 @@ class MainWindow:
# VPaned holding the lists and the Terminal
vpaned = gtk.VPaned()
- vpaned.set_position(400)
+ vpaned.set_position(mHeight/2)
vb.pack_start(vpaned, True, True)
# a HB holding the lists