question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Array index out of bounds exception

See original GitHub issue

Hi! I’ve implemented your library in my proj and when I click somewhere outside of search box, it crashes with ArrayIndexOutOfBoundsException in MenuView. Here is the stacktrace:

java.lang.ArrayIndexOutOfBoundsException: length=0; index=0
                   at android.animation.AnimatorSet.playTogether(AnimatorSet.java:142)
                   at com.arlib.floatingsearchview.util.view.MenuView.showIfRoomItems(MenuView.java:506)
                   at com.arlib.floatingsearchview.FloatingSearchView.setSearchFocusedInternal(FloatingSearchView.java:1361)
                   at com.arlib.floatingsearchview.FloatingSearchView.access$1500(FloatingSearchView.java:87)
                   at com.arlib.floatingsearchview.FloatingSearchView$23.onTouch(FloatingSearchView.java:1657)
                   at android.view.View.dispatchTouchEvent(View.java:8382)

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:10 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
acarlsencommented, Jun 7, 2016

I have the same issue. It happens if I dont supply a icon resource to the menu item, fx. if I only want to display text. If I supply a drawable as icon the error doesn’t happen.

0reactions
arimortycommented, Jul 20, 2016

@acarlsen thanks, I am trying to resolve this bug and that’s what the problem is.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Array Index Out Of Bounds Exception in Java - GeeksforGeeks
The index of an array is an integer value that has value in the interval [0, n-1], where n is the size of...
Read more >
What is the ArrayIndexOutOfBounds exception in Java?
Java, like other languages, supports the creation and manipulation of an array. The ArrayIndexOutOfBounds exception is thrown if a program tries to access ......
Read more >
How to handle Java Array Index Out of Bounds Exception?
Whenever you used an –ve value or, the value greater than or equal to the size of the array, then the ArrayIndexOutOfBoundsException is...
Read more >
How To Handle The ArrayIndexOutOfBoundsException in Java?
Answer: An array out of bound exception occurs when a program tries to access an array element by specifying a negative index or...
Read more >
What is ArrayIndexOutOfBoundsException? - Scaler Topics
Array index out of bounds exception can only be found at the runtime (when the program gets executed). Therefore, whenever we try to...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found