From c1c306150fd0d0b89b2c23195efadad02d4e4ad4 Mon Sep 17 00:00:00 2001 From: AndyScherzinger Date: Tue, 22 Nov 2016 21:57:26 +0100 Subject: [PATCH] fix compile error after lib merges # Conflicts: # src/com/owncloud/android/ui/activity/ShareActivity.java --- .../com/owncloud/android/ui/activity/ShareActivity.java | 8 +++++--- .../owncloud/android/ui/helpers/FileOperationsHelper.java | 3 ++- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/owncloud/android/ui/activity/ShareActivity.java b/src/main/java/com/owncloud/android/ui/activity/ShareActivity.java index a5e52fd40c..2507cb33a0 100644 --- a/src/main/java/com/owncloud/android/ui/activity/ShareActivity.java +++ b/src/main/java/com/owncloud/android/ui/activity/ShareActivity.java @@ -42,7 +42,6 @@ import com.owncloud.android.operations.CreateShareViaLinkOperation; import com.owncloud.android.operations.GetSharesForFileOperation; import com.owncloud.android.operations.UnshareOperation; import com.owncloud.android.operations.UpdateSharePermissionsOperation; -import com.owncloud.android.providers.UsersAndGroupsSearchProvider; import com.owncloud.android.ui.dialog.ShareLinkToDialog; import com.owncloud.android.ui.fragment.EditShareFragment; import com.owncloud.android.ui.fragment.SearchShareesFragment; @@ -51,6 +50,7 @@ import com.owncloud.android.ui.fragment.ShareFragmentListener; import com.owncloud.android.utils.ErrorMessageAdapter; import com.owncloud.android.utils.GetShareWithUsersAsyncTask; +import org.nextcloud.providers.UsersAndGroupsSearchProvider; import java.util.ArrayList; @@ -154,10 +154,12 @@ public class ShareActivity extends FileActivity return OCShare.READ_PERMISSION_FLAG; // minimum permissions } else if (getFile().isFolder()) { - return (isFederated) ? OCShare.FEDERATED_PERMISSIONS_FOR_FOLDER : OCShare.MAXIMUM_PERMISSIONS_FOR_FOLDER; + return (isFederated) ? OCShare.FEDERATED_PERMISSIONS_FOR_FOLDER_UP_TO_OC9 : + OCShare.MAXIMUM_PERMISSIONS_FOR_FOLDER; } else { // isFile - return (isFederated) ? OCShare.FEDERATED_PERMISSIONS_FOR_FILE : OCShare.MAXIMUM_PERMISSIONS_FOR_FILE; + return (isFederated) ? OCShare.FEDERATED_PERMISSIONS_FOR_FILE_UP_TO_OC9 : + OCShare.MAXIMUM_PERMISSIONS_FOR_FILE; } } diff --git a/src/main/java/com/owncloud/android/ui/helpers/FileOperationsHelper.java b/src/main/java/com/owncloud/android/ui/helpers/FileOperationsHelper.java index f49fc4e5e0..edeabdf22e 100755 --- a/src/main/java/com/owncloud/android/ui/helpers/FileOperationsHelper.java +++ b/src/main/java/com/owncloud/android/ui/helpers/FileOperationsHelper.java @@ -479,7 +479,8 @@ public class FileOperationsHelper { updateShareIntent.putExtra(OperationsService.EXTRA_SHARE_PERMISSIONS, OCShare.CREATE_PERMISSION_FLAG); } else { updateShareIntent. - putExtra(OperationsService.EXTRA_SHARE_PERMISSIONS, OCShare.FEDERATED_PERMISSIONS_FOR_FOLDER); + putExtra(OperationsService.EXTRA_SHARE_PERMISSIONS, + OCShare.FEDERATED_PERMISSIONS_FOR_FOLDER_UP_TO_OC9); } queueShareIntent(updateShareIntent);