From 32346efa622bf04c48c2143df110c2c890924d64 Mon Sep 17 00:00:00 2001 From: purigarcia Date: Wed, 8 Jul 2015 08:55:41 +0200 Subject: [PATCH] this two options are not shown if the file is downloading or uploading --- src/com/owncloud/android/files/FileMenuFilter.java | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/src/com/owncloud/android/files/FileMenuFilter.java b/src/com/owncloud/android/files/FileMenuFilter.java index d6c075d6..4ed9e649 100644 --- a/src/com/owncloud/android/files/FileMenuFilter.java +++ b/src/com/owncloud/android/files/FileMenuFilter.java @@ -215,6 +215,22 @@ public class FileMenuFilter { toShow.add(R.id.action_send_file); } + // FAVORITES + if (mFile == null || downloading || uploading) { + toHide.add(R.id.action_favorite_file); + + } else { + toShow.add(R.id.action_favorite_file); + } + + // UNFAVORITES + if (mFile == null || downloading || uploading) { + toHide.add(R.id.action_unfavorite_file); + + } else { + toShow.add(R.id.action_unfavorite_file); + } + } } -- 2.11.0