feat: 优化代码

pull/133/head
kunfei 5 years ago
parent 9298638ead
commit f4627a7a1a
  1. 5
      app/src/main/java/io/legado/app/ui/main/my/MyFragment.kt

@ -76,9 +76,8 @@ class MyFragment : BaseFragment(R.layout.fragment_my_config), FileChooserDialog.
webServicePre?.isChecked = false
}
findPreference<NameListPreference>(PreferKey.themeMode)?.let {
it.setOnPreferenceChangeListener { _, newValue ->
App.INSTANCE.putPrefString(PreferKey.themeMode, newValue.toString())
App.INSTANCE.applyDayNight()
it.setOnPreferenceChangeListener { _, _ ->
view?.post { App.INSTANCE.applyDayNight() }
true
}
}

Loading…
Cancel
Save