Minor extension filter cleanup

This commit is contained in:
arkon 2020-01-11 15:13:51 -05:00
parent 62d3fc65e0
commit e414b9edf1
4 changed files with 12 additions and 13 deletions

View File

@ -81,7 +81,7 @@ open class ExtensionController : NucleusController<ExtensionPresenter>(),
override fun onOptionsItemSelected(item: MenuItem): Boolean { override fun onOptionsItemSelected(item: MenuItem): Boolean {
when (item.itemId) { when (item.itemId) {
R.id.action_settings -> { R.id.action_settings -> {
router.pushController((RouterTransaction.with(SettingsExtensionsController())) router.pushController((RouterTransaction.with(ExtensionFilterController()))
.popChangeHandler(SettingsExtensionsFadeChangeHandler()) .popChangeHandler(SettingsExtensionsFadeChangeHandler())
.pushChangeHandler(FadeChangeHandler())) .pushChangeHandler(FadeChangeHandler()))
} }

View File

@ -1,7 +1,7 @@
package eu.kanade.tachiyomi.ui.extension package eu.kanade.tachiyomi.ui.extension
import android.support.v7.preference.PreferenceScreen import androidx.preference.PreferenceScreen
import android.support.v7.preference.SwitchPreference import androidx.preference.SwitchPreference
import eu.kanade.tachiyomi.R import eu.kanade.tachiyomi.R
import eu.kanade.tachiyomi.data.preference.getOrDefault import eu.kanade.tachiyomi.data.preference.getOrDefault
import eu.kanade.tachiyomi.extension.ExtensionManager import eu.kanade.tachiyomi.extension.ExtensionManager
@ -12,10 +12,10 @@ import eu.kanade.tachiyomi.util.LocaleHelper
import uy.kohesive.injekt.Injekt import uy.kohesive.injekt.Injekt
import uy.kohesive.injekt.api.get import uy.kohesive.injekt.api.get
class SettingsExtensionsController: SettingsController() { class ExtensionFilterController: SettingsController() {
override fun setupPreferenceScreen(screen: PreferenceScreen) = with(screen) { override fun setupPreferenceScreen(screen: PreferenceScreen) = with(screen) {
titleRes = R.string.ext_settings titleRes = R.string.action_filter
val activeLangs = preferences.enabledLanguages().getOrDefault() val activeLangs = preferences.enabledLanguages().getOrDefault()

View File

@ -3,15 +3,15 @@
<item <item
android:id="@+id/action_search" android:id="@+id/action_search"
android:title="@string/action_search"
android:icon="@drawable/ic_search_white_24dp" android:icon="@drawable/ic_search_white_24dp"
app:showAsAction="collapseActionView|ifRoom" android:title="@string/action_search"
app:actionViewClass="androidx.appcompat.widget.SearchView"/> app:actionViewClass="androidx.appcompat.widget.SearchView"
app:showAsAction="collapseActionView|ifRoom" />
<item <item
android:id="@+id/action_settings" android:id="@+id/action_settings"
android:title="@string/ext_settings" android:icon="@drawable/ic_filter_list_white_24dp"
android:icon="@drawable/ic_settings_white_24dp" android:title="@string/action_filter"
app:showAsAction="always"/> app:showAsAction="ifRoom" />
</menu> </menu>

View File

@ -176,7 +176,6 @@
<string name="ext_version_info">Version: %1$s</string> <string name="ext_version_info">Version: %1$s</string>
<string name="ext_language_info">Language: %1$s</string> <string name="ext_language_info">Language: %1$s</string>
<string name="ext_empty_preferences">No preferences to edit for this extension</string> <string name="ext_empty_preferences">No preferences to edit for this extension</string>
<string name="ext_settings">Settings</string>
<!-- Reader section --> <!-- Reader section -->
<string name="pref_fullscreen">Fullscreen</string> <string name="pref_fullscreen">Fullscreen</string>