mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2025-01-17 22:08:00 +01:00
use Subsampling at a couple more image formats
This commit is contained in:
parent
f7deafb2dc
commit
576f2a431a
2 changed files with 1 additions and 3 deletions
|
@ -186,7 +186,7 @@ class PhotoFragment : ViewPagerFragment() {
|
|||
}
|
||||
|
||||
private fun addZoomableView() {
|
||||
if ((medium.isJpg() || medium.isPng()) && isMenuVisible && view.subsampling_view.visibility == View.GONE) {
|
||||
if ((medium.isImage()) && isMenuVisible && view.subsampling_view.visibility == View.GONE) {
|
||||
view.subsampling_view.apply {
|
||||
beVisible()
|
||||
setDoubleTapZoomScale(1.4f)
|
||||
|
|
|
@ -20,8 +20,6 @@ data class Medium(val name: String, var path: String, val isVideo: Boolean, val
|
|||
|
||||
fun isGif() = path.isGif()
|
||||
|
||||
fun isJpg() = !isPng() && !isGif()
|
||||
|
||||
fun isImage() = !isGif() && !isVideo
|
||||
|
||||
fun getMimeType() = File(path).getMimeType()
|
||||
|
|
Loading…
Reference in a new issue