summaryrefslogtreecommitdiff
path: root/portato/gui/gtk
diff options
context:
space:
mode:
authorRené 'Necoro' Neumann <necoro@necoro.net>2008-02-25 18:31:19 +0100
committerRené 'Necoro' Neumann <necoro@necoro.net>2008-02-25 18:31:19 +0100
commit08836abffe86f59eddfa771f32a80a60afdd18b5 (patch)
tree5e7bf7c55cdcdd02fba75b9657252e70a71cdf09 /portato/gui/gtk
parent4b8784746c479c188f95b8fdd2124c581136112d (diff)
downloadportato-08836abffe86f59eddfa771f32a80a60afdd18b5.tar.gz
portato-08836abffe86f59eddfa771f32a80a60afdd18b5.tar.bz2
portato-08836abffe86f59eddfa771f32a80a60afdd18b5.zip
Added use flag list in the generals tab
Diffstat (limited to '')
-rw-r--r--portato/gui/gtk/windows.py16
1 files changed, 15 insertions, 1 deletions
diff --git a/portato/gui/gtk/windows.py b/portato/gui/gtk/windows.py
index 417c626..0959e61 100644
--- a/portato/gui/gtk/windows.py
+++ b/portato/gui/gtk/windows.py
@@ -19,6 +19,7 @@ import gobject
# other
import os.path
from subprocess import Popen
+import itertools
from gettext import lgettext as _
# our backend stuff
@@ -459,11 +460,13 @@ class PackageTable:
self.nameLabel = self.tree.get_widget("nameLabel")
self.descLabel = self.tree.get_widget("descLabel")
self.overlayLabel = self.tree.get_widget("overlayLabel")
- self.licenseLabel = self.tree.get_widget("licenseLabel")
self.overlayLL = self.tree.get_widget("overlayLabelLabel")
+ self.licenseLabel = self.tree.get_widget("licenseLabel")
self.linkBox = self.tree.get_widget("linkBox")
self.notInSysLabel = self.tree.get_widget("notInSysLabel")
self.missingLabel = self.tree.get_widget("missingLabel")
+ self.useFlagsLabel = self.tree.get_widget("useFlagsLabel")
+ self.useFlagsLL = self.tree.get_widget("useFlagsLabelLabel")
# buttons
self.emergeBtn = self.tree.get_widget("pkgEmergeBtn")
@@ -574,6 +577,17 @@ class PackageTable:
link.set_border_width(0)
self.linkBox.add(link)
+ # useflags
+ flags = ", ".join(itertools.ifilterfalse(pkg.use_expanded, pkg.get_iuse_flags()))
+
+ if flags:
+ self.useFlagsLL.show()
+ self.useFlagsLabel.show()
+ self.useFlagsLabel.set_label(flags)
+ else:
+ self.useFlagsLL.hide()
+ self.useFlagsLabel.hide()
+
def fill_use_list(self):
pkg = self.actual_package()