X-Git-Url: http://git.linex4red.de/pub/Android/ownCloud.git/blobdiff_plain/f6ac875ce56f67ee30d8894674f26fcbf08317e6..bcc972d63d3ed1d76b51a8a03a27e809983dc756:/src/com/owncloud/android/ui/fragment/FileDetailFragment.java diff --git a/src/com/owncloud/android/ui/fragment/FileDetailFragment.java b/src/com/owncloud/android/ui/fragment/FileDetailFragment.java index ea0f814c..e024bc67 100644 --- a/src/com/owncloud/android/ui/fragment/FileDetailFragment.java +++ b/src/com/owncloud/android/ui/fragment/FileDetailFragment.java @@ -473,12 +473,10 @@ public class FileDetailFragment extends FileFragment implements @Override public void onNeutral(String callerTag) { - File f = null; OCFile file = getFile(); - if (file.isDown() && (f = new File(file.getStoragePath())).exists()) { - f.delete(); + mStorageManager.removeFile(file, false, true); // TODO perform in background task / new thread + if (file.getStoragePath() != null) { file.setStoragePath(null); - mStorageManager.saveFile(file); updateFileDetails(file, mAccount); } }