added processevents for a more responsive gui

Signed-off-by: tanji <nicholastanjerome@gmail.com>