Post resize shouldn't hang EDT.
Fixed closing bug.
Synchronise to prevent exception.