From f9a40b02321bb3593273882be2c5c69eb6ee9140 Mon Sep 17 00:00:00 2001 From: joragua Date: Thu, 3 Oct 2024 09:26:01 +0200 Subject: [PATCH] refactor: changes in image preview snackbar --- .../com/owncloud/android/ui/preview/PreviewImageFragment.kt | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/owncloudApp/src/main/java/com/owncloud/android/ui/preview/PreviewImageFragment.kt b/owncloudApp/src/main/java/com/owncloud/android/ui/preview/PreviewImageFragment.kt index 4c80889a6e1..82a2bbe72ee 100644 --- a/owncloudApp/src/main/java/com/owncloud/android/ui/preview/PreviewImageFragment.kt +++ b/owncloudApp/src/main/java/com/owncloud/android/ui/preview/PreviewImageFragment.kt @@ -349,10 +349,9 @@ class PreviewImageFragment : FileFragment() { private fun showSnackbarMessage(){ val snackbar = Snackbar.make(requireView(), R.string.sync_file_nothing_to_do_msg, Snackbar.LENGTH_LONG) - val snackbarView = snackbar.view - val params = snackbarView.layoutParams as ViewGroup.MarginLayoutParams + val params = snackbar.view.layoutParams as ViewGroup.MarginLayoutParams params.setMargins(params.leftMargin, params.topMargin, params.rightMargin, 100) - snackbarView.layoutParams = params + snackbar.view.layoutParams = params snackbar.show() }