Fix bug #19: If use cloud API(s), there will be exceptions/errors once use during closing app.

In fact, this is a memory leak caused by progressdialog, we should
dismiss it, not just hide.