Fixed leaked window while showing ProgressDialog

Fixed issue #4
Added null check for progressDialog in onDestroy
Fixed line indent
Merge pull request #6 from AfzalivE/master

Fixed leaked window while showing ProgressDialog
changes to make it actually compile under android studio