mirror of
https://github.com/azahar-emu/azahar.git
synced 2026-06-12 21:48:18 -04:00
Moved OnSettingChange after I add or remove selected vals to fix crashing issue.
This commit is contained in:
parent
f2980073a7
commit
5d6c9cb6bf
1 changed files with 2 additions and 3 deletions
|
|
@ -753,7 +753,6 @@ class SettingsAdapter(
|
|||
val value = it.getValueAt(which)
|
||||
if (value in it.selectedValues && !is_checked) {
|
||||
it.removeSelectedValue(value ?: "")
|
||||
fragmentView?.onSettingChanged()
|
||||
} else {
|
||||
it.addSelectedValue(value ?: "")
|
||||
}
|
||||
|
|
@ -762,7 +761,6 @@ class SettingsAdapter(
|
|||
is AbstractMultiShortSetting -> {
|
||||
if (is_checked != it.selectValueIndices[which]) {
|
||||
it.removeSelectedValue(it.getValueAt(which)?.toShort() ?: 1)
|
||||
fragmentView?.onSettingChanged()
|
||||
} else {
|
||||
it.addSelectedValue(it.getValueAt(which)?.toShort() ?: 1)
|
||||
}
|
||||
|
|
@ -771,8 +769,9 @@ class SettingsAdapter(
|
|||
else -> throw IllegalStateException("Unrecognized type used for StringMultiChoiceSetting!")
|
||||
}
|
||||
|
||||
fragmentView?.onSettingChanged()
|
||||
fragmentView?.putSetting(setting as AbstractSetting)
|
||||
//fragmentView.loadSettingsList()
|
||||
fragmentView.loadSettingsList()
|
||||
//closeDialog()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue