summaryrefslogtreecommitdiff
path: root/gui.py
diff options
context:
space:
mode:
authornecoro <>2006-09-06 20:49:37 +0000
committernecoro <>2006-09-06 20:49:37 +0000
commitdeba1986aabff275c1c0ee496fecf826f2af5a09 (patch)
tree18d4a583444d9e8a61563546ef1687220c18efe1 /gui.py
parentf11d7e5bf8cc3a32cbd3bb97d843efdb08fa9648 (diff)
downloadportato-deba1986aabff275c1c0ee496fecf826f2af5a09.tar.gz
portato-deba1986aabff275c1c0ee496fecf826f2af5a09.tar.bz2
portato-deba1986aabff275c1c0ee496fecf826f2af5a09.zip
Fixed bug with (un)emerging.
Diffstat (limited to '')
-rwxr-xr-xgui.py11
1 files changed, 6 insertions, 5 deletions
diff --git a/gui.py b/gui.py
index c9e9196..b3c138f 100755
--- a/gui.py
+++ b/gui.py
@@ -54,12 +54,12 @@ class EmergeQueue:
if self.unmergeIt: # update tree
self.tree.append(self.unmergeIt, [sth])
- def _emerge (self, options):
+ def _emerge (self, options, it):
"""Calls emerge and updates the terminal."""
# open pty
(master, slave) = pty.openpty()
Popen("emerge "+options, stdout = slave, stderr = STDOUT, shell = True)
- self.removeAll(self.emergeIt)
+ self.removeAll(it)
self.console.set_pty(master)
def emerge (self, force = False):
@@ -68,11 +68,12 @@ class EmergeQueue:
list = ""
for k in self.mergequeue.keys():
- list += " '='"+k+"'"
+ list += " '="+k+"'"
s = ""
+ print list
if not force: s = "-pv "
- self._emerge(s+list)
+ self._emerge(s+list, self.emergeIt)
def unmerge (self, force = False):
"""Unmerges everything in the umerge-queue. If force is 'False' (default) only "emerge -pv -C" is called."""
@@ -81,7 +82,7 @@ class EmergeQueue:
list = " ".join(self.unmergequeue)
s = ""
if not force: s = "-pv "
- self._emerge("-C "+s+list)
+ self._emerge("-C "+s+list, self.unmergeIt)
def removeAll (self, parentIt):
"""Removes all children of a given parent TreeIter."""