Skip to content
This repository has been archived by the owner on Oct 18, 2024. It is now read-only.

[Bug]: IOOB when removing item selected in 'Additional Gradle Commands' setting #1444

Closed
2 tasks done
Rafael2616 opened this issue Nov 10, 2023 · 1 comment
Closed
2 tasks done
Labels
bug Something isn't working

Comments

@Rafael2616
Copy link
Contributor

What happened?

When removing the a fifth item in the in the Gradle command dialog the app crashes

Video from user in the group. Error was also reproduced on my side

VID_20231109_221343_279.mp4

What's the expected behavior?

Not crash

What version of AndroidIDE you're using?

v2.6.0 (debug builds)

Relevant log output

Stacktrace:
java.lang.IndexOutOfBoundsException: Index: 5, Size: 3
	at java.util.ArrayList.remove(ArrayList.java:503)
	at com.itsaky.androidide.preferences.ChoiceBasedDialogPreference.onSelectionChanged(Unknown Source:20)
	at com.itsaky.androidide.preferences.MultiChoicePreference$$ExternalSyntheticLambda0.onClick(Unknown Source:7)
	at androidx.appcompat.app.AlertController$AlertParams$4.onItemClick(Unknown Source:24)
	at android.widget.AdapterView.performItemClick(AdapterView.java:318)
	at android.widget.AbsListView.performItemClick(AbsListView.java:1235)
	at android.widget.AbsListView$PerformClick.run(AbsListView.java:3219)
	at android.widget.AbsListView$3.run(AbsListView.java:4312)
	at android.os.Handler.handleCallback(Handler.java:873)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loop(Looper.java:205)
	at android.app.ActivityThread.main(ActivityThread.java:6993)
	at java.lang.reflect.Method.invoke(Native Method)
	at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:493)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:884)

Duplicate issues

  • This issue has not been reported yet.

Code of Conduct

  • I agree to follow this project's Code of Conduct
@Rafael2616 Rafael2616 added the bug Something isn't working label Nov 10, 2023
@Rafael2616
Copy link
Contributor Author

Rafael2616 commented Nov 10, 2023

Update: I can't remove items already selected:

Screenshot_20231109_225243.mp4

@itsaky itsaky closed this as completed in e5448a4 Nov 10, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant