clone EventDispatchThreadMonitor from https://github.com/floscher/swinghelper Change-Id: I103c250957555913bda2ebe58b8d3a56af172377