Skip to content

Commit

Permalink
SettingsActivity: fix crash when screen orientation changes
Browse files Browse the repository at this point in the history
  • Loading branch information
mwarning committed Aug 29, 2024
1 parent a518a3d commit b7da2d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/src/main/kotlin/d/d/meshenger/SettingsActivity.kt
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,7 @@ class SettingsActivity : BaseActivity(), ServiceConnection {
spinner.setSelection(arrayValues.indexOf(currentValue))
spinner.onItemSelectedListener = object : AdapterView.OnItemSelectedListener {
var check = 0
override fun onItemSelected(parent: AdapterView<*>?, view: View, pos: Int, id: Long) {
override fun onItemSelected(parent: AdapterView<*>?, view: View?, pos: Int, id: Long) {
if (pos >= arrayValues.size) {
Toast.makeText(this@SettingsActivity,
"pos out of bounds: $arrayValues", Toast.LENGTH_SHORT).show()
Expand Down

0 comments on commit b7da2d3

Please sign in to comment.