Nearly there

Need to figure out how to raise events on the same thread as the UI so
that we don't have to check the InvokeRequired property. Also to figure
out a way to allow a task to be canceled.