Skip to content

Commit

Permalink
Prevented image files from being previewed when a security method is …
Browse files Browse the repository at this point in the history
…configured.
  • Loading branch information
fesave committed Apr 26, 2022
1 parent 72a734d commit dfffdce
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 5 deletions.
8 changes: 5 additions & 3 deletions owncloudApp/src/main/java/com/owncloud/android/MainApp.kt
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
/*
/**
* ownCloud Android client application
*
* @author masensio
* @author David A. Velasco
* @author David González Verdugo
* @author Christian Schabesberger
* @author David Crespo Ríos
* Copyright (C) 2020 ownCloud GmbH.
* @author Fernando Sanz Velasco
* Copyright (C) 2022 ownCloud GmbH.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2,
Expand Down Expand Up @@ -47,6 +48,7 @@ import com.owncloud.android.lib.common.OwnCloudClient
import com.owncloud.android.lib.common.SingleSessionManager
import com.owncloud.android.presentation.ui.authentication.LoginActivity
import com.owncloud.android.presentation.ui.migration.StorageMigrationActivity
import com.owncloud.android.presentation.ui.releasenotes.ReleaseNotesActivity
import com.owncloud.android.presentation.ui.security.BiometricActivity
import com.owncloud.android.presentation.ui.security.BiometricManager
import com.owncloud.android.presentation.ui.security.LockTimeout
Expand All @@ -59,8 +61,8 @@ import com.owncloud.android.presentation.ui.settings.fragments.SettingsLogsFragm
import com.owncloud.android.providers.LogsProvider
import com.owncloud.android.ui.activity.FileDisplayActivity
import com.owncloud.android.ui.activity.SplashActivity
import com.owncloud.android.presentation.ui.releasenotes.ReleaseNotesActivity
import com.owncloud.android.ui.activity.WhatsNewActivity
import com.owncloud.android.ui.preview.PreviewImageActivity
import com.owncloud.android.utils.DOWNLOAD_NOTIFICATION_CHANNEL_ID
import com.owncloud.android.utils.DebugInjector
import com.owncloud.android.utils.FILE_SYNC_CONFLICT_CHANNEL_ID
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@
* @author Christian Schabesberger
* @author Shashvat Kedia
* @author Abel García de Prada
* @author Fernando Sanz Velasco
* Copyright (C) 2011 Bartek Przybylski
* Copyright (C) 2020 ownCloud GmbH.
* Copyright (C) 2022 ownCloud GmbH.
*
*
* This program is free software: you can redistribute it and/or modify
Expand Down Expand Up @@ -1685,7 +1686,7 @@ class FileDisplayActivity : FileActivity(), FileFragment.ContainerActivity, OnEn
}

if (PreviewImageFragment.canBePreviewed(file)) {
startImagePreview(file)
showDetails(file)
} else {
initFragmentsWithFile()
}
Expand Down

0 comments on commit dfffdce

Please sign in to comment.