ui thread is starting to work
add a helper class to handle thread for gui
added test code