예제 #1
0
def update(w):
	setbusy(w)
	icol, irow = w.selection
	if 0 <= icol < len(w.data) and 2 <= irow < len(w.data[icol]):
		selname = w.data[icol][irow][0]
	else:
		selname = ''
	statcache.forget_dir(w.a)
	statcache.forget_dir(w.b)
	tablewin.select(w, (-1, -1))
	tablewin.update(w, diffdata(w.a, w.b, w.flags))
	if selname:
		for icol in range(len(w.data)):
			for irow in range(2, len(w.data[icol])):
				if w.data[icol][irow][0] == selname:
					tablewin.select(w, (icol, irow))
					break
예제 #2
0
def update(w):
    setbusy(w)
    icol, irow = w.selection
    if 0 <= icol < len(w.data) and 2 <= irow < len(w.data[icol]):
        selname = w.data[icol][irow][0]
    else:
        selname = ""
    statcache.forget_dir(w.a)
    statcache.forget_dir(w.b)
    tablewin.select(w, (-1, -1))
    tablewin.update(w, diffdata(w.a, w.b, w.flags))
    if selname:
        for icol in range(len(w.data)):
            for irow in range(2, len(w.data[icol])):
                if w.data[icol][irow][0] == selname:
                    tablewin.select(w, (icol, irow))
                    break