Space-Navigation-View icon indicating copy to clipboard operation
Space-Navigation-View copied to clipboard

Can't show badge?

Open dainq57 opened this issue 7 years ago • 2 comments

I got an issue, I add line "spaceNavigationView.showBadgeAtIndex(2,3,getResources().getColor(R.color.colorAccent));" to onCreate of Activity to show badge, so it ocour FC issue with log "java.lang.IndexOutOfBoundsException: Index: 2, Size: 0", through I've add 4 item before, what should i do?

dainq57 avatar Sep 08 '17 17:09 dainq57

@dainq57 for some wierd reason spaceNavigationView has some sync issues, if you call showBadgeAtIndex method with a few milliseconds of delay, it will work fine. worked for me at least, and i tried alot of other things.

flaviotps avatar Dec 31 '17 19:12 flaviotps

Yes, I am facing the same issue. As @flaviotps said, if we call after a few milliseconds of delay, it works fine.

ChiragSavsani avatar Mar 15 '23 05:03 ChiragSavsani