ticket.58601:Avoid dismissCurrentDialog() invoked twice.