craiglabenz / flutter_rolling_nav_bar

Playful and customizable bottom navigation bar for Flutter
MIT License
122 stars 18 forks source link

I cannot get the tap index when the index is equal to the active index #4

Closed soleysok closed 3 years ago

soleysok commented 3 years ago

I think this is the cause. Could you help me out on this by creating another option to solve this problem

Screen Shot 2020-12-17 at 3 19 59 PM
craiglabenz commented 3 years ago

Thanks for filing this issue! Can you describe a bit more about what you'd like to accomplish? I think my assumption writing that guard statement was that tapping on the active index should short-circuit, since the roller should already be in its target destination.

But I certainly could be remembering this incorrectly.

soleysok commented 3 years ago

When the index is active, it doesn't give the onTap the index so I can't refresh the ui. What I want to do is to be able to get the index even if the index is already active. Thank you!

soleysok commented 3 years ago

@craiglabenz For Example, on the newsfeed screen of the Facebook app, when you tap on the newsfeed tab(when it is already active) it will refresh the screen to its original state. But since the onTap function doesn't return the tap index when the index is already active, I can't refresh the state.