Random cleanup

This commit is contained in:
Jay 2020-04-24 13:24:41 -04:00
parent edbea486c8
commit 6237a61b4b
3 changed files with 4 additions and 4 deletions

View File

@ -38,7 +38,7 @@ class SetTrackChaptersDialog<T> : DialogController
val dialog = MaterialDialog(activity!!)
.title(R.string.chapters)
.customView(viewRes = R.layout.track_chapters_dialog, scrollable = false)
.customView(viewRes = R.layout.track_chapters_dialog)
.negativeButton(android.R.string.cancel)
.positiveButton(android.R.string.ok) { dialog ->
val view = dialog.getCustomView()

View File

@ -36,7 +36,7 @@ class SetTrackScoreDialog<T> : DialogController where T : SetTrackScoreDialog.Li
val item = item
val dialog = MaterialDialog(activity!!).title(R.string.score)
.customView(R.layout.track_score_dialog, scrollable = false)
.customView(R.layout.track_score_dialog)
.negativeButton(android.R.string.cancel).positiveButton(android.R.string.ok) { dialog ->
val view = dialog.getCustomView()
// Remove focus to update selected number

View File

@ -116,7 +116,7 @@ fun Controller.scrollViewWith(
) {
if (!recycler.canScrollVertically(-1)) {
val shortAnimationDuration = resources?.getInteger(
android.R.integer.config_shortAnimTime
R.integer.config_shortAnimTime
) ?: 0
activity!!.appbar.animate().y(0f).setDuration(shortAnimationDuration.toLong())
.start()
@ -141,7 +141,7 @@ fun Controller.scrollViewWith(
) {
val halfWay = abs((-activity!!.appbar.height.toFloat()) / 2)
val shortAnimationDuration = resources?.getInteger(
android.R.integer.config_shortAnimTime
R.integer.config_shortAnimTime
) ?: 0
val closerToTop = abs(activity!!.appbar.y) - halfWay > 0
val atTop = (!customPadding &&