diff --git a/.github/workflows/qa.yml b/.github/workflows/qa.yml index e1d5e67b23..a031b5ded6 100644 --- a/.github/workflows/qa.yml +++ b/.github/workflows/qa.yml @@ -21,7 +21,7 @@ jobs: runs-on: ubuntu-latest steps: - name: Check if secrets are available - run: echo "::set-output name=ok::${{ secrets.KS_PASS != '' }}" + run: echo "ok=${{ secrets.KS_PASS != '' }}" >> "$GITHUB_OUTPUT" id: check-secrets - uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7 if: ${{ steps.check-secrets.outputs.ok == 'true' }} diff --git a/app/src/main/java/com/nextcloud/ui/ImageDetailFragment.kt b/app/src/main/java/com/nextcloud/ui/ImageDetailFragment.kt index 8fc7af18de..5a21ab3523 100644 --- a/app/src/main/java/com/nextcloud/ui/ImageDetailFragment.kt +++ b/app/src/main/java/com/nextcloud/ui/ImageDetailFragment.kt @@ -25,6 +25,7 @@ import com.nextcloud.client.NominatimClient import com.nextcloud.client.account.User import com.nextcloud.client.di.Injectable import com.nextcloud.utils.extensions.getParcelableArgument +import com.nextcloud.utils.extensions.logFileSize import com.owncloud.android.MainApp import com.owncloud.android.R import com.owncloud.android.databinding.PreviewImageDetailsFragmentBinding @@ -63,6 +64,8 @@ class ImageDetailFragment : Fragment(), Injectable { @Inject lateinit var viewThemeUtils: ViewThemeUtils + private val tag = "ImageDetailFragment" + override fun onCreateView(inflater: LayoutInflater, container: ViewGroup?, savedInstanceState: Bundle?): View { binding = PreviewImageDetailsFragmentBinding.inflate(layoutInflater, container, false) @@ -102,6 +105,7 @@ class ImageDetailFragment : Fragment(), Injectable { override fun onSaveInstanceState(outState: Bundle) { super.onSaveInstanceState(outState) + file.logFileSize(tag) outState.putParcelable(ARG_FILE, file) outState.putParcelable(ARG_USER, user) outState.putParcelable(ARG_METADATA, metadata) diff --git a/app/src/main/java/com/nextcloud/utils/extensions/FileExtensions.kt b/app/src/main/java/com/nextcloud/utils/extensions/FileExtensions.kt new file mode 100644 index 0000000000..94ae83be09 --- /dev/null +++ b/app/src/main/java/com/nextcloud/utils/extensions/FileExtensions.kt @@ -0,0 +1,25 @@ +/* + * Nextcloud - Android Client + * + * SPDX-FileCopyrightText: 2024 Alper Ozturk + * SPDX-License-Identifier: AGPL-3.0-or-later + */ + +package com.nextcloud.utils.extensions + +import com.owncloud.android.datamodel.OCFile +import com.owncloud.android.lib.common.utils.Log_OC +import com.owncloud.android.utils.DisplayUtils +import java.io.File + +fun OCFile?.logFileSize(tag: String) { + val size = DisplayUtils.bytesToHumanReadable(this?.fileLength ?: -1) + val rawByte = this?.fileLength ?: -1 + Log_OC.d(tag, "onSaveInstanceState: $size, raw byte $rawByte") +} + +fun File?.logFileSize(tag: String) { + val size = DisplayUtils.bytesToHumanReadable(this?.length() ?: -1) + val rawByte = this?.length() ?: -1 + Log_OC.d(tag, "onSaveInstanceState: $size, raw byte $rawByte") +} diff --git a/app/src/main/java/com/owncloud/android/ui/activity/ConflictsResolveActivity.kt b/app/src/main/java/com/owncloud/android/ui/activity/ConflictsResolveActivity.kt index 7b8710d4f1..18f3686c9d 100644 --- a/app/src/main/java/com/owncloud/android/ui/activity/ConflictsResolveActivity.kt +++ b/app/src/main/java/com/owncloud/android/ui/activity/ConflictsResolveActivity.kt @@ -20,6 +20,7 @@ import com.nextcloud.client.jobs.upload.FileUploadWorker import com.nextcloud.client.jobs.upload.UploadNotificationManager import com.nextcloud.model.HTTPStatusCodes import com.nextcloud.utils.extensions.getParcelableArgument +import com.nextcloud.utils.extensions.logFileSize import com.owncloud.android.R import com.owncloud.android.datamodel.FileDataStorageManager import com.owncloud.android.datamodel.OCFile @@ -143,6 +144,7 @@ class ConflictsResolveActivity : FileActivity(), OnConflictDecisionMadeListener override fun onSaveInstanceState(outState: Bundle) { super.onSaveInstanceState(outState) + existingFile.logFileSize(TAG) outState.putLong(EXTRA_CONFLICT_UPLOAD_ID, conflictUploadId) outState.putParcelable(EXTRA_EXISTING_FILE, existingFile) outState.putInt(EXTRA_LOCAL_BEHAVIOUR, localBehaviour) diff --git a/app/src/main/java/com/owncloud/android/ui/activity/FileActivity.java b/app/src/main/java/com/owncloud/android/ui/activity/FileActivity.java index 5366d73e7f..58bf035eec 100644 --- a/app/src/main/java/com/owncloud/android/ui/activity/FileActivity.java +++ b/app/src/main/java/com/owncloud/android/ui/activity/FileActivity.java @@ -39,6 +39,7 @@ import com.nextcloud.client.network.ConnectivityService; import com.nextcloud.utils.EditorUtils; import com.nextcloud.utils.extensions.ActivityExtensionsKt; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.nextcloud.utils.extensions.IntentExtensionsKt; import com.owncloud.android.MainApp; import com.owncloud.android.R; @@ -271,6 +272,7 @@ public abstract class FileActivity extends DrawerActivity @Override protected void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); + FileExtensionsKt.logFileSize(mFile, TAG); outState.putParcelable(FileActivity.EXTRA_FILE, mFile); outState.putBoolean(FileActivity.EXTRA_FROM_NOTIFICATION, mFromNotification); outState.putLong(KEY_WAITING_FOR_OP_ID, mFileOperationsHelper.getOpIdWaitingFor()); diff --git a/app/src/main/java/com/owncloud/android/ui/activity/FileDisplayActivity.java b/app/src/main/java/com/owncloud/android/ui/activity/FileDisplayActivity.java index 5a36009fb8..1b8c280c26 100644 --- a/app/src/main/java/com/owncloud/android/ui/activity/FileDisplayActivity.java +++ b/app/src/main/java/com/owncloud/android/ui/activity/FileDisplayActivity.java @@ -66,6 +66,7 @@ import com.nextcloud.model.WorkerState; import com.nextcloud.model.WorkerStateLiveData; import com.nextcloud.utils.extensions.ActivityExtensionsKt; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.nextcloud.utils.extensions.IntentExtensionsKt; import com.nextcloud.utils.view.FastScrollUtils; import com.owncloud.android.MainApp; @@ -1067,8 +1068,8 @@ public class FileDisplayActivity extends FileActivity protected void onSaveInstanceState(@NonNull Bundle outState) { // responsibility of restore is preferred in onCreate() before than in // onRestoreInstanceState when there are Fragments involved - Log_OC.v(TAG, "onSaveInstanceState() start"); super.onSaveInstanceState(outState); + FileExtensionsKt.logFileSize(mWaitingToPreview, TAG); outState.putParcelable(FileDisplayActivity.KEY_WAITING_TO_PREVIEW, mWaitingToPreview); outState.putBoolean(FileDisplayActivity.KEY_SYNC_IN_PROGRESS, mSyncInProgress); // outState.putBoolean(FileDisplayActivity.KEY_REFRESH_SHARES_IN_PROGRESS, diff --git a/app/src/main/java/com/owncloud/android/ui/activity/ReceiveExternalFilesActivity.java b/app/src/main/java/com/owncloud/android/ui/activity/ReceiveExternalFilesActivity.java index 0370aadb3b..4d69dcf4ae 100755 --- a/app/src/main/java/com/owncloud/android/ui/activity/ReceiveExternalFilesActivity.java +++ b/app/src/main/java/com/owncloud/android/ui/activity/ReceiveExternalFilesActivity.java @@ -52,6 +52,7 @@ import com.nextcloud.client.jobs.upload.FileUploadHelper; import com.nextcloud.client.jobs.upload.FileUploadWorker; import com.nextcloud.client.preferences.AppPreferences; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.nextcloud.utils.extensions.IntentExtensionsKt; import com.owncloud.android.MainApp; import com.owncloud.android.R; @@ -264,7 +265,7 @@ public class ReceiveExternalFilesActivity extends FileActivity @Override protected void onSaveInstanceState(@NonNull Bundle outState) { - Log_OC.d(TAG, "onSaveInstanceState() start"); + FileExtensionsKt.logFileSize(mFile, TAG); super.onSaveInstanceState(outState); outState.putString(KEY_PARENTS, generatePath(mParents)); outState.putParcelable(KEY_FILE, mFile); diff --git a/app/src/main/java/com/owncloud/android/ui/activity/UploadFilesActivity.java b/app/src/main/java/com/owncloud/android/ui/activity/UploadFilesActivity.java index 4de179ad5e..da59551317 100644 --- a/app/src/main/java/com/owncloud/android/ui/activity/UploadFilesActivity.java +++ b/app/src/main/java/com/owncloud/android/ui/activity/UploadFilesActivity.java @@ -33,6 +33,7 @@ import com.nextcloud.client.di.Injectable; import com.nextcloud.client.jobs.upload.FileUploadWorker; import com.nextcloud.client.preferences.AppPreferences; import com.nextcloud.utils.extensions.ActivityExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.R; import com.owncloud.android.databinding.UploadFilesLayoutBinding; import com.owncloud.android.lib.common.utils.Log_OC; @@ -410,7 +411,7 @@ public class UploadFilesActivity extends DrawerActivity implements LocalFileList protected void onSaveInstanceState(@NonNull Bundle outState) { // responsibility of restore is preferred in onCreate() before than in // onRestoreInstanceState when there are Fragments involved - Log_OC.d(TAG, "onSaveInstanceState() start"); + FileExtensionsKt.logFileSize(mCurrentDir, TAG); super.onSaveInstanceState(outState); outState.putString(UploadFilesActivity.KEY_DIRECTORY_PATH, mCurrentDir.getAbsolutePath()); if (mOptionsMenu != null && mOptionsMenu.findItem(R.id.action_select_all) != null) { diff --git a/app/src/main/java/com/owncloud/android/ui/dialog/ConflictsResolveDialog.java b/app/src/main/java/com/owncloud/android/ui/dialog/ConflictsResolveDialog.java index 9807350e81..d07281b86e 100644 --- a/app/src/main/java/com/owncloud/android/ui/dialog/ConflictsResolveDialog.java +++ b/app/src/main/java/com/owncloud/android/ui/dialog/ConflictsResolveDialog.java @@ -21,6 +21,7 @@ import com.google.android.material.dialog.MaterialAlertDialogBuilder; import com.nextcloud.client.account.User; import com.nextcloud.client.di.Injectable; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.R; import com.owncloud.android.databinding.ConflictResolveDialogBinding; import com.owncloud.android.datamodel.FileDataStorageManager; @@ -62,6 +63,7 @@ public class ConflictsResolveDialog extends DialogFragment implements Injectable @Inject ViewThemeUtils viewThemeUtils; @Inject SyncedFolderProvider syncedFolderProvider; + private static final String TAG = "ConflictsResolveDialog"; private static final String KEY_NEW_FILE = "file"; private static final String KEY_EXISTING_FILE = "ocfile"; private static final String KEY_USER = "user"; @@ -78,7 +80,10 @@ public class ConflictsResolveDialog extends DialogFragment implements Injectable Bundle args = new Bundle(); args.putParcelable(KEY_EXISTING_FILE, existingFile); - args.putSerializable(KEY_NEW_FILE, new File(newFile.getStoragePath())); + + File file = new File(newFile.getStoragePath()); + FileExtensionsKt.logFileSize(file, TAG); + args.putSerializable(KEY_NEW_FILE, file); args.putParcelable(KEY_USER, user); dialog.setArguments(args); @@ -136,6 +141,8 @@ public class ConflictsResolveDialog extends DialogFragment implements Injectable public void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); + FileExtensionsKt.logFileSize(existingFile, TAG); + FileExtensionsKt.logFileSize(newFile, TAG); outState.putParcelable(KEY_EXISTING_FILE, existingFile); outState.putSerializable(KEY_NEW_FILE, newFile); outState.putParcelable(KEY_USER, user); diff --git a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailActivitiesFragment.java b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailActivitiesFragment.java index 6069e4e6c0..68618877fa 100644 --- a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailActivitiesFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailActivitiesFragment.java @@ -23,6 +23,7 @@ import com.nextcloud.client.di.Injectable; import com.nextcloud.client.network.ClientFactory; import com.nextcloud.common.NextcloudClient; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.R; import com.owncloud.android.databinding.FileDetailsActivitiesFragmentBinding; import com.owncloud.android.datamodel.FileDataStorageManager; @@ -431,7 +432,7 @@ public class FileDetailActivitiesFragment extends Fragment implements @Override public void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); - + FileExtensionsKt.logFileSize(file, TAG); outState.putParcelable(ARG_FILE, file); outState.putParcelable(ARG_USER, user); } diff --git a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailFragment.java b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailFragment.java index 048b26b6cf..8a1708240b 100644 --- a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailFragment.java @@ -35,6 +35,7 @@ import com.nextcloud.client.preferences.AppPreferences; import com.nextcloud.ui.fileactions.FileActionsBottomSheet; import com.nextcloud.utils.MenuUtils; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.MainApp; import com.owncloud.android.R; import com.owncloud.android.databinding.FileDetailsFragmentBinding; @@ -355,6 +356,7 @@ public class FileDetailFragment extends FileFragment implements OnClickListener, @Override public void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); + FileExtensionsKt.logFileSize(getFile(), TAG); outState.putParcelable(ARG_FILE, getFile()); outState.putParcelable(ARG_USER, user); } diff --git a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailSharingFragment.java b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailSharingFragment.java index ed4fc93657..071faeee46 100644 --- a/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailSharingFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/fragment/FileDetailSharingFragment.java @@ -36,6 +36,7 @@ import com.nextcloud.client.account.UserAccountManager; import com.nextcloud.client.di.Injectable; import com.nextcloud.client.network.ClientFactory; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.R; import com.owncloud.android.databinding.FileDetailsSharingFragmentBinding; import com.owncloud.android.datamodel.FileDataStorageManager; @@ -80,6 +81,7 @@ public class FileDetailSharingFragment extends Fragment implements ShareeListAda DisplayUtils.AvatarGenerationListener, Injectable, FileDetailsSharingMenuBottomSheetActions, QuickSharingPermissionsBottomSheetDialog.QuickPermissionSharingBottomSheetActions { + private static final String TAG = "FileDetailSharingFragment"; private static final String ARG_FILE = "FILE"; private static final String ARG_USER = "USER"; @@ -541,7 +543,7 @@ public class FileDetailSharingFragment extends Fragment implements ShareeListAda @Override public void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); - + FileExtensionsKt.logFileSize(file, TAG); outState.putParcelable(ARG_FILE, file); outState.putParcelable(ARG_USER, user); } diff --git a/app/src/main/java/com/owncloud/android/ui/fragment/GalleryFragment.java b/app/src/main/java/com/owncloud/android/ui/fragment/GalleryFragment.java index 14675325b7..d1d2fa8b5e 100644 --- a/app/src/main/java/com/owncloud/android/ui/fragment/GalleryFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/fragment/GalleryFragment.java @@ -67,8 +67,8 @@ public class GalleryFragment extends OCFileListFragment implements GalleryFragme private GalleryFragmentBottomSheetDialog galleryFragmentBottomSheetDialog; @Inject FileDataStorageManager fileDataStorageManager; - private final int maxColumnSizeLandscape = 5; - private final int maxColumnSizePortrait = 2; + private final static int maxColumnSizeLandscape = 5; + private final static int maxColumnSizePortrait = 2; private int columnSize; protected void setPhotoSearchQueryRunning(boolean value) { diff --git a/app/src/main/java/com/owncloud/android/ui/fragment/OCFileListFragment.java b/app/src/main/java/com/owncloud/android/ui/fragment/OCFileListFragment.java index c761d789af..6746c15235 100644 --- a/app/src/main/java/com/owncloud/android/ui/fragment/OCFileListFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/fragment/OCFileListFragment.java @@ -57,6 +57,7 @@ import com.nextcloud.ui.fileactions.FileActionsBottomSheet; import com.nextcloud.utils.EditorUtils; import com.nextcloud.utils.ShortcutUtil; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.nextcloud.utils.extensions.IntentExtensionsKt; import com.nextcloud.utils.view.FastScrollUtils; import com.owncloud.android.MainApp; @@ -850,7 +851,7 @@ public class OCFileListFragment extends ExtendedListFragment implements @Override public void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); - + FileExtensionsKt.logFileSize(mFile, TAG); outState.putParcelable(KEY_FILE, mFile); if (searchFragment) { outState.putParcelable(KEY_CURRENT_SEARCH_TYPE, currentSearchType); diff --git a/app/src/main/java/com/owncloud/android/ui/preview/FileDownloadFragment.java b/app/src/main/java/com/owncloud/android/ui/preview/FileDownloadFragment.java index 83ea8b5bea..3004dce0fd 100644 --- a/app/src/main/java/com/owncloud/android/ui/preview/FileDownloadFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/preview/FileDownloadFragment.java @@ -24,6 +24,7 @@ import com.nextcloud.client.account.User; import com.nextcloud.client.di.Injectable; import com.nextcloud.client.jobs.download.FileDownloadHelper; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.R; import com.owncloud.android.datamodel.OCFile; import com.owncloud.android.lib.common.network.OnDatatransferProgressListener; @@ -163,6 +164,7 @@ public class FileDownloadFragment extends FileFragment implements OnClickListene @Override public void onSaveInstanceState(@NonNull Bundle outState) { super.onSaveInstanceState(outState); + FileExtensionsKt.logFileSize(getFile(), TAG); outState.putParcelable(FileDownloadFragment.EXTRA_FILE, getFile()); outState.putParcelable(FileDownloadFragment.EXTRA_USER, user); outState.putBoolean(FileDownloadFragment.EXTRA_ERROR, mError); diff --git a/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaActivity.kt b/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaActivity.kt index 8df0dbe55d..19dead13fa 100644 --- a/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaActivity.kt +++ b/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaActivity.kt @@ -65,6 +65,7 @@ import com.nextcloud.common.NextcloudClient import com.nextcloud.ui.fileactions.FileActionsBottomSheet.Companion.newInstance import com.nextcloud.ui.fileactions.FileActionsBottomSheet.ResultListener import com.nextcloud.utils.extensions.getParcelableArgument +import com.nextcloud.utils.extensions.logFileSize import com.owncloud.android.R import com.owncloud.android.databinding.ActivityPreviewMediaBinding import com.owncloud.android.datamodel.OCFile @@ -327,7 +328,7 @@ class PreviewMediaActivity : override fun onSaveInstanceState(outState: Bundle) { super.onSaveInstanceState(outState) - Log_OC.v(TAG, "onSaveInstanceState") + file.logFileSize(TAG) outState.let { bundle -> bundle.putParcelable(EXTRA_FILE, file) bundle.putParcelable(EXTRA_USER, user) diff --git a/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaFragment.kt b/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaFragment.kt index b06c0fea4a..f146374e0a 100644 --- a/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaFragment.kt +++ b/app/src/main/java/com/owncloud/android/ui/preview/PreviewMediaFragment.kt @@ -55,6 +55,7 @@ import com.nextcloud.client.network.ClientFactory.CreationException import com.nextcloud.common.NextcloudClient import com.nextcloud.ui.fileactions.FileActionsBottomSheet.Companion.newInstance import com.nextcloud.utils.extensions.getParcelableArgument +import com.nextcloud.utils.extensions.logFileSize import com.owncloud.android.MainApp import com.owncloud.android.R import com.owncloud.android.databinding.FragmentPreviewMediaBinding @@ -125,6 +126,7 @@ class PreviewMediaFragment : FileFragment(), OnTouchListener, Injectable { super.onCreate(savedInstanceState) arguments?.let { bundle -> + file.logFileSize(TAG) file = bundle.getParcelableArgument(FILE, OCFile::class.java) user = bundle.getParcelableArgument(USER, User::class.java) @@ -254,7 +256,7 @@ class PreviewMediaFragment : FileFragment(), OnTouchListener, Injectable { override fun onSaveInstanceState(outState: Bundle) { super.onSaveInstanceState(outState) - Log_OC.v(TAG, "onSaveInstanceState") + file.logFileSize(TAG) toggleDrawerLockMode(containerActivity, DrawerLayout.LOCK_MODE_LOCKED_CLOSED) outState.run { diff --git a/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextFileFragment.java b/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextFileFragment.java index 5543de42b9..6d0a25e643 100644 --- a/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextFileFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextFileFragment.java @@ -21,6 +21,7 @@ import com.nextcloud.client.account.User; import com.nextcloud.client.account.UserAccountManager; import com.nextcloud.ui.fileactions.FileActionsBottomSheet; import com.nextcloud.utils.extensions.BundleExtensionsKt; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.R; import com.owncloud.android.datamodel.OCFile; import com.owncloud.android.lib.common.utils.Log_OC; @@ -136,6 +137,7 @@ public class PreviewTextFileFragment extends PreviewTextFragment { */ @Override public void onSaveInstanceState(@NonNull Bundle outState) { + FileExtensionsKt.logFileSize(getFile(), TAG); outState.putParcelable(PreviewTextFileFragment.EXTRA_FILE, getFile()); outState.putParcelable(PreviewTextFileFragment.EXTRA_USER, user); super.onSaveInstanceState(outState); diff --git a/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextStringFragment.java b/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextStringFragment.java index 547c9d6d73..28b63b979a 100644 --- a/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextStringFragment.java +++ b/app/src/main/java/com/owncloud/android/ui/preview/PreviewTextStringFragment.java @@ -19,6 +19,7 @@ import android.view.ViewGroup; import com.google.android.material.floatingactionbutton.FloatingActionButton; import com.nextcloud.android.lib.richWorkspace.RichWorkspaceDirectEditingRemoteOperation; import com.nextcloud.client.account.UserAccountManager; +import com.nextcloud.utils.extensions.FileExtensionsKt; import com.owncloud.android.R; import com.owncloud.android.lib.common.operations.RemoteOperationResult; import com.owncloud.android.ui.activity.FileDisplayActivity; @@ -37,6 +38,7 @@ public class PreviewTextStringFragment extends PreviewTextFragment { @Inject UserAccountManager accountManager; @Inject ViewThemeUtils viewThemeUtils; + private final static String TAG = "PreviewTextStringFragment"; private boolean isEditorWebviewLaunched = false; /** @@ -70,6 +72,7 @@ public class PreviewTextStringFragment extends PreviewTextFragment { */ @Override public void onSaveInstanceState(@NonNull Bundle outState) { + FileExtensionsKt.logFileSize(getFile(), TAG); outState.putParcelable(PreviewTextStringFragment.EXTRA_FILE, getFile()); super.onSaveInstanceState(outState); diff --git a/app/src/main/res/values-ar/strings.xml b/app/src/main/res/values-ar/strings.xml index 7e99a58164..c954b149c6 100644 --- a/app/src/main/res/values-ar/strings.xml +++ b/app/src/main/res/values-ar/strings.xml @@ -354,6 +354,7 @@ فشل تحديث UI إضافة إلى المفضلة المفضلة + ملف مشترك لا يمكن تحديثه اسم الملف موجود مسبقاً حذف خطأ في استرداد النشاطات للملف diff --git a/app/src/main/res/values-b+en+001/strings.xml b/app/src/main/res/values-b+en+001/strings.xml index 17b5d499c6..f454e1d1bd 100644 --- a/app/src/main/res/values-b+en+001/strings.xml +++ b/app/src/main/res/values-b+en+001/strings.xml @@ -92,6 +92,7 @@ %1$s does not support multiple accounts Could not establish connection Cancel Login + There was an issue processing your login request. Please try again later. Please complete login process in your browser kept in original folder, as it is readonly Only upload on unmetered Wi-Fi @@ -353,6 +354,7 @@ Failed to update UI Add to favourites Favourite + Shared file cannot be updated Filename already exists Delete Error retrieving activities for file diff --git a/app/src/main/res/values-de/strings.xml b/app/src/main/res/values-de/strings.xml index 09a90f4983..7665b4da9f 100644 --- a/app/src/main/res/values-de/strings.xml +++ b/app/src/main/res/values-de/strings.xml @@ -354,6 +354,7 @@ Oberfläche konnte nicht aktualisiert werden Zu den Favoriten hinzufügen Favoriten + Geteilte Datei kann nicht aktualisiert werden Dateiname bereits vorhanden Löschen Fehler beim Abrufen der Aktivitäten für die Datei diff --git a/app/src/main/res/values-ga/strings.xml b/app/src/main/res/values-ga/strings.xml index bd8b61aa47..b9abfcd443 100644 --- a/app/src/main/res/values-ga/strings.xml +++ b/app/src/main/res/values-ga/strings.xml @@ -354,6 +354,7 @@ Theip ar an Chomhéadain a nuashonrú Cuir le ceanáin is fearr leat + Ní féidir an comhad roinnte a nuashonrú Tá ainm an chomhaid ann cheana Scrios Earráid agus gníomhaíochtaí á aisghabháil don chomhad diff --git a/app/src/main/res/values-gl/strings.xml b/app/src/main/res/values-gl/strings.xml index 1e1690bba3..6646eb01fc 100644 --- a/app/src/main/res/values-gl/strings.xml +++ b/app/src/main/res/values-gl/strings.xml @@ -354,6 +354,7 @@ Produciuse un fallo ao actualizar a IU Engadir a favoritos Favorito + Non foi posíbel actualizar o ficheiro compartido O nome de ficheiro xa existe Eliminar Produciuse un erro ao recuperar actividades para o ficheiro diff --git a/app/src/main/res/values-ja-rJP/strings.xml b/app/src/main/res/values-ja-rJP/strings.xml index 41c57c1a1b..46629fad80 100644 --- a/app/src/main/res/values-ja-rJP/strings.xml +++ b/app/src/main/res/values-ja-rJP/strings.xml @@ -197,6 +197,7 @@ 新しいフォルダー 新規プレゼンテーション 新規スプレッドシート + フォルダの説明を追加 資格情報が無効です 毎日のバックアップ バックアップするデータ diff --git a/app/src/main/res/values-nb-rNO/strings.xml b/app/src/main/res/values-nb-rNO/strings.xml index 47d5527926..6f4bfd7803 100644 --- a/app/src/main/res/values-nb-rNO/strings.xml +++ b/app/src/main/res/values-nb-rNO/strings.xml @@ -354,6 +354,7 @@ Kunne ikke oppdatere brukergrensesnittet Legg til i favoritter Favoritt + Delt fil kan ikke oppdateres Filnavnet finnes allerede Slett Henting av aktiviteter for fil feilet diff --git a/app/src/main/res/values-sr/strings.xml b/app/src/main/res/values-sr/strings.xml index b8c55e558a..44a1024a9d 100644 --- a/app/src/main/res/values-sr/strings.xml +++ b/app/src/main/res/values-sr/strings.xml @@ -92,6 +92,7 @@ %1$s не подржава вишеструке налоге Не могу да успоставим везу Откажи пријављивање + Дошло је до проблема при обради вашег захтева за пријаву. Молимо вас да касније покушате поново. Молимо вас да довршите процес пријаве у интернет прегледачу остављен у оригиналној фасцикли јер је само за читање Отпремај само на бежичним мрежама без ограничења @@ -321,6 +322,7 @@ Грешка приликом приказа дијалога за подешавање шифрирања! Грешка при покретању камере Грешка приликом почетка скенирања документа + Није успело креиране медије Налози Покренуто пута 48 сати Направљен @@ -352,6 +354,7 @@ Неуспело освежавање сучеља Додај у омиљене Омиљени + Не може да се ажурира дељени фајл Име фајла већ постоји Обриши Грешка при добављању активности за фајл @@ -904,7 +907,9 @@ Отпреми из… Отпрема садржај из других апликација Фотографија + Желите ли да направите фотографију или видео клип? Отпреми са камере + Видео снимак Назив фајла Тип фајла Пречица Гугл мапа (%s) diff --git a/app/src/main/res/values-zh-rHK/strings.xml b/app/src/main/res/values-zh-rHK/strings.xml index 596015e804..2341e12188 100644 --- a/app/src/main/res/values-zh-rHK/strings.xml +++ b/app/src/main/res/values-zh-rHK/strings.xml @@ -354,6 +354,7 @@ 更新 UI 失敗 加到我的最愛 我的最愛 + 無法更新分享了的檔案 檔案名已存在 刪除 取得檔案活動時發生錯誤 @@ -927,6 +928,7 @@ 無法複製檔案到近端資料夾 鎖定資料夾失敗 用戶已取消上傳 + %1$d / %2$d - %3$s 加密功能只適用於 Android 5.0 及以上版本 空間不足導致無法將所選檔案複製到 %1$s 資料夾中。您想改為將檔案移到那裡嗎? 超過儲存空間配額 diff --git a/app/src/main/res/values-zh-rTW/strings.xml b/app/src/main/res/values-zh-rTW/strings.xml index a30df721de..21b292ad99 100644 --- a/app/src/main/res/values-zh-rTW/strings.xml +++ b/app/src/main/res/values-zh-rTW/strings.xml @@ -354,6 +354,7 @@ 更新使用者介面失敗 加到我的最愛 我的最愛 + 無法更新已分享的檔案 檔案名稱已存在 刪除 取得檔案活動時發生錯誤 diff --git a/gradle/verification-metadata.xml b/gradle/verification-metadata.xml index 3143793fe4..69ba5f4d72 100644 --- a/gradle/verification-metadata.xml +++ b/gradle/verification-metadata.xml @@ -5962,14 +5962,17 @@ - - - - - - - - + + + + + + + +