Kotlin code refactor

This commit is contained in:
Hemanth S 2020-05-24 04:26:11 +05:30
parent ffa3125438
commit 10503c183a
2 changed files with 4 additions and 4 deletions

View file

@ -92,9 +92,6 @@ class AlbumCoverStylePreferenceDialog : DialogFragment(),
PreferenceUtilKT.albumCoverStyle = coverStyle
}
}
.setNegativeButton(android.R.string.cancel) { _, _ ->
dismiss()
}
.setView(view)
.create()
}

View file

@ -86,7 +86,10 @@ class NowPlayingScreenPreferenceDialog : DialogFragment(), ViewPager.OnPageChang
viewPager.pageMargin = ViewUtil.convertDpToPixel(32f, resources).toInt()
viewPager.currentItem = PreferenceUtilKT.nowPlayingScreen.ordinal
return MaterialAlertDialogBuilder(requireContext())
return MaterialAlertDialogBuilder(
requireContext(),
R.style.ThemeOverlay_MaterialComponents_Dialog_Alert
)
.setTitle(R.string.pref_title_now_playing_screen_appearance)
.setCancelable(false)
.setPositiveButton(R.string.set) { _, _ ->