mirror of
https://github.com/FossifyOrg/Gallery.git
synced 2025-01-19 06:48:00 +01:00
lets remove GlideDecoder for now, roll back to rgb_565 format
This commit is contained in:
parent
aa2f8722ea
commit
015fde6a97
1 changed files with 1 additions and 4 deletions
|
@ -26,7 +26,6 @@ import com.simplemobiletools.gallery.R
|
||||||
import com.simplemobiletools.gallery.activities.PhotoActivity
|
import com.simplemobiletools.gallery.activities.PhotoActivity
|
||||||
import com.simplemobiletools.gallery.activities.ViewPagerActivity
|
import com.simplemobiletools.gallery.activities.ViewPagerActivity
|
||||||
import com.simplemobiletools.gallery.extensions.*
|
import com.simplemobiletools.gallery.extensions.*
|
||||||
import com.simplemobiletools.gallery.helpers.GlideDecoder
|
|
||||||
import com.simplemobiletools.gallery.helpers.GlideRotateTransformation
|
import com.simplemobiletools.gallery.helpers.GlideRotateTransformation
|
||||||
import com.simplemobiletools.gallery.helpers.MEDIUM
|
import com.simplemobiletools.gallery.helpers.MEDIUM
|
||||||
import com.simplemobiletools.gallery.models.Medium
|
import com.simplemobiletools.gallery.models.Medium
|
||||||
|
@ -224,7 +223,6 @@ class PhotoFragment : ViewPagerFragment() {
|
||||||
if ((medium.isImage()) && isFragmentVisible && view.subsampling_view.isGone()) {
|
if ((medium.isImage()) && isFragmentVisible && view.subsampling_view.isGone()) {
|
||||||
ViewPagerActivity.wasDecodedByGlide = false
|
ViewPagerActivity.wasDecodedByGlide = false
|
||||||
view.subsampling_view.apply {
|
view.subsampling_view.apply {
|
||||||
setBitmapDecoderClass(GlideDecoder::class.java)
|
|
||||||
maxScale = 10f
|
maxScale = 10f
|
||||||
beVisible()
|
beVisible()
|
||||||
setImage(ImageSource.uri(medium.path))
|
setImage(ImageSource.uri(medium.path))
|
||||||
|
@ -286,8 +284,7 @@ class PhotoFragment : ViewPagerFragment() {
|
||||||
}
|
}
|
||||||
|
|
||||||
fun rotateImageViewBy(degrees: Float) {
|
fun rotateImageViewBy(degrees: Float) {
|
||||||
// do not make Subsampling view Gone, because it gets recycled and can crash with "Error, cannot access an invalid/free'd bitmap here!"
|
view.subsampling_view.beGone()
|
||||||
view.subsampling_view.beInvisible()
|
|
||||||
loadBitmap(degrees)
|
loadBitmap(degrees)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue