* the time that the file was created. There is a chance that this will\r
* be fixed in future versions. Use this method to check if this version of\r
* ownCloud has this fix.\r
- * @return True, if ownCloud the ownCloud version is > 3.0.4 and 4.0.1\r
+ * @return True, if ownCloud the ownCloud version is > 3.0.4 and 4.0.4\r
*/\r
private boolean ocVersionSupportsTimeCreated(){\r
if(mIntent != null){\r
AccountManager accManager = (AccountManager) getActivity().getSystemService(Context.ACCOUNT_SERVICE);\r
OwnCloudVersion ocVersion = new OwnCloudVersion(accManager\r
.getUserData(ocAccount, AccountAuthenticator.KEY_OC_VERSION));\r
- if(ocVersion.compareTo(new OwnCloudVersion(0x030004)) >= 0 || ocVersion.compareTo(new OwnCloudVersion(0x040001)) >= 0){\r
+ if(ocVersion.compareTo(new OwnCloudVersion(0x030004)) >= 0 || ocVersion.compareTo(new OwnCloudVersion(0x040004)) >= 0){\r
return true;\r
}\r
}\r
private class DownloadFinishReceiver extends BroadcastReceiver {\r
@Override\r
public void onReceive(Context context, Intent intent) {\r
- ((OCFile)mIntent.getParcelableExtra(EXTRA_FILE)).setStoragePath(intent.getStringExtra(FileDownloader.EXTRA_FILE_PATH));\r
- updateFileDetails(mIntent);\r
+ if (intent.getAction().equals(FileDownloader.BAD_DOWNLOAD_MESSAGE)) {\r
+ Toast.makeText(context, R.string.downloader_download_failed , Toast.LENGTH_SHORT).show();\r
+ \r
+ } else if (intent.getAction().equals(FileDownloader.DOWNLOAD_FINISH_MESSAGE)) {\r
+ ((OCFile)mIntent.getParcelableExtra(EXTRA_FILE)).setStoragePath(intent.getStringExtra(FileDownloader.EXTRA_FILE_PATH));\r
+ updateFileDetails(mIntent);\r
+ }\r
}\r
\r
}\r