[Refactor] Remove now redundant SAM constructor.

This commit is contained in:
Hai Zhang 2023-08-05 21:00:04 -07:00
parent db5e9f4427
commit 9fca17bffe

View File

@ -43,7 +43,6 @@ import androidx.lifecycle.LifecycleOwner
import androidx.recyclerview.widget.GridLayoutManager
import androidx.recyclerview.widget.RecyclerView
import androidx.swiperefreshlayout.widget.SwipeRefreshLayout
import com.google.android.material.appbar.AppBarLayout.OnOffsetChangedListener
import com.leinardi.android.speeddial.SpeedDialView
import java8.nio.file.Path
import java8.nio.file.Paths
@ -197,14 +196,12 @@ class FileListFragment : Fragment(), BreadcrumbLayout.Listener, FileListAdapter.
binding.persistentBarLayout, binding.bottomBarLayout, binding.bottomToolbar
)
val contentLayoutInitialPaddingBottom = binding.contentLayout.paddingBottom
binding.appBarLayout.addOnOffsetChangedListener(
OnOffsetChangedListener { _, verticalOffset ->
binding.contentLayout.updatePaddingRelative(
bottom = contentLayoutInitialPaddingBottom +
binding.appBarLayout.totalScrollRange + verticalOffset
)
}
)
binding.appBarLayout.addOnOffsetChangedListener { _, verticalOffset ->
binding.contentLayout.updatePaddingRelative(
bottom = contentLayoutInitialPaddingBottom +
binding.appBarLayout.totalScrollRange + verticalOffset
)
}
binding.appBarLayout.syncBackgroundElevationTo(binding.overlayToolbar)
binding.breadcrumbLayout.setListener(this)
if (!(activity.hasSw600Dp && activity.isOrientationLandscape)) {