Add some more spinner.update() calls in possibly time consuming loops.
authorZac Medico <zmedico@gentoo.org>
Fri, 25 Apr 2008 03:16:58 +0000 (03:16 -0000)
committerZac Medico <zmedico@gentoo.org>
Fri, 25 Apr 2008 03:16:58 +0000 (03:16 -0000)
svn path=/main/trunk/; revision=9968

pym/_emerge/__init__.py

index 484f7c258fd6a5b46acab4d149239b5496f700dd..826e8509657d6bb48bebda40d41c51cb7284ccf5 100644 (file)
@@ -1842,6 +1842,7 @@ class depgraph(object):
        def _create_graph(self, allow_unsatisfied=False):
                dep_stack = self._dep_stack
                while dep_stack:
+                       self.spinner.update()
                        dep = dep_stack.pop()
                        if isinstance(dep, Package):
                                if not self._add_pkg_deps(dep,
@@ -3121,6 +3122,7 @@ class depgraph(object):
                                del blocker_cache
 
                for blocker in self.blocker_parents.keys():
+                       self.spinner.update()
                        mytype, myroot, mydep = blocker
                        initial_db = self.trees[myroot]["vartree"].dbapi
                        final_db = self.mydbapi[myroot]
@@ -3294,6 +3296,7 @@ class depgraph(object):
                        for node in mygraph.root_nodes():
                                if not isinstance(node, Package) or \
                                        node.installed or node.onlydeps:
+                                       self.spinner.update()
                                        mygraph.remove(node)
                                        removed_something = True
                        if not removed_something:
@@ -3372,6 +3375,7 @@ class depgraph(object):
                # unresolved blockers or circular dependencies.
 
                while not mygraph.empty():
+                       self.spinner.update()
                        selected_nodes = None
                        ignore_priority = None
                        if prefer_asap and asap_nodes: