Fixed dialog not close.