ZoomableActivity.kt: removed Unnecessary non-null assertion (!!) on a non-null receiver of type ZoomableDraweeView

This commit is contained in:
Junwei Bai 2024-10-18 00:50:01 +11:00
parent b7c9520ed8
commit 0dc379acdf

View file

@ -646,7 +646,7 @@ class ZoomableActivity : BaseActivity() {
.setProgressBarImage(ProgressBarDrawable()) .setProgressBarImage(ProgressBarDrawable())
.setProgressBarImageScaleType(ScalingUtils.ScaleType.FIT_CENTER) .setProgressBarImageScaleType(ScalingUtils.ScaleType.FIT_CENTER)
.build() .build()
with(binding.zoomable!!) { with(binding.zoomable) {
setHierarchy(hierarchy) setHierarchy(hierarchy)
setAllowTouchInterceptionWhileZoomed(true) setAllowTouchInterceptionWhileZoomed(true)
setIsLongpressEnabled(false) setIsLongpressEnabled(false)
@ -658,10 +658,10 @@ class ZoomableActivity : BaseActivity() {
.setUri(imageUri) .setUri(imageUri)
.setControllerListener(loadingListener) .setControllerListener(loadingListener)
.build() .build()
binding.zoomable!!.controller = controller binding.zoomable.controller = controller
if (photoBackgroundColor != null) { if (photoBackgroundColor != null) {
binding.zoomable!!.setBackgroundColor(photoBackgroundColor!!) binding.zoomable.setBackgroundColor(photoBackgroundColor!!)
} }
if (!images.isNullOrEmpty()) { if (!images.isNullOrEmpty()) {