added thread safety, and update of the UI on the EventDsipatcher thread