Use overlay method for ShareActivity

Signed-off-by: Alper Ozturk <alperozturk@lions-macbook.local>
Signed-off-by: alperozturk <alper_ozturk@proton.me>
This commit is contained in:
Alper Ozturk 2023-10-03 14:37:08 +02:00 committed by alperozturk
parent 929b704425
commit 16db8c01b6
No known key found for this signature in database
GPG key ID: 4E577DC593B59BDF

View file

@ -23,6 +23,8 @@ package com.owncloud.android.ui.activity;
import android.app.Activity;
import android.graphics.Bitmap;
import android.graphics.drawable.Drawable;
import android.graphics.drawable.LayerDrawable;
import android.os.Bundle;
import com.nextcloud.client.account.User;
@ -77,15 +79,9 @@ public class ShareActivity extends FileActivity {
// Icon
if (file.isFolder()) {
binding.shareFileIcon.setImageDrawable(MimeTypeUtil.getFolderTypeIcon(file.isSharedWithMe() ||
file.isSharedWithSharee(),
file.isSharedViaLink(),
file.isEncrypted(),
syncedFolderProvider.findByRemotePathAndAccount(file.getRemotePath(), optionalUser.get()),
file.isGroupFolder(),
file.getMountType(),
this,
viewThemeUtils));
boolean isAutoUploadFolder = SyncedFolderProvider.isAutoUploadFolder(syncedFolderProvider, file, optionalUser.get());
LayerDrawable drawable = file.getFileLayerDrawable(isAutoUploadFolder, this, viewThemeUtils);
binding.shareFileIcon.setImageDrawable(drawable);
} else {
binding.shareFileIcon.setImageDrawable(MimeTypeUtil.getFileTypeIcon(file.getMimeType(),
file.getFileName(),