moved rendering out of timer in to mouse/touch event callbacks. Added dirty rect rendering