More merge fixes and added debug UI
Went back to the basics and implemented the events
Started using the events to populate debug ui
Guarded calls to the listener
Fixed threading issue
More useful comments