[pygtk] Updating a progressbar inside a recursive function

Felix Rabe (public) public at felixrabe.textdriven.com
Tue Sep 26 04:47:25 WST 2006


Felix Rabe (public) wrote:
> Hi Adolfo,
> 
> You might not need to use recursive code, and generators aren't too 
> bad.  Have you looked at os.walk() already?

Uno más: func_id = gobject.idle_add(func) // gobject.source_remove(func_id) (to interrupt)
Junto con:

def func([self]):
	...
	return True (called again) or False (last call)

I hope that gives you the connection points to use os.walk with PyGTK and the progress bar.  (At least that is how I would approach it.)

Best wishes,
Felix


More information about the pygtk mailing list