if(parent != null){
parent.mkdirs();
}
if(parent == null || !parent.exists()){
Toast.makeText(DownloadIndexActivity.this, getString(R.string.download_sd_dir_not_accessible), Toast.LENGTH_LONG);
<BUG>return;
</BUG>
}
<BUG>final File file = new File(parent, regionName);
final ProgressDialog dlg = ProgressDialog.show(this, getString(R.string.downloading), getString(R.string.downloading_file), true, true);</BUG>
dlg.show();

if(parent != null){
parent.mkdirs();
}
if(parent == null || !parent.exists()){
Toast.makeText(DownloadIndexActivity.this, getString(R.string.download_sd_dir_not_accessible), Toast.LENGTH_LONG);
return null;
}
File file = new File(parent, regionName);
return file;
}
protected void downloadFile(final String key, final File file) {
final ProgressDialog dlg = ProgressDialog.show(this, getString(R.string.downloading), getString(R.string.downloading_file), true, true);
dlg.show();
