Reputation: 1
I have a persistent bottom navigation bar with five tabs. On the index 2 screen, there are three tabs, with the last one being "Cart". all my screens, there's a floating cart details widget visible across all tabs. When the user clicks on the floating cart details, I want to navigate to tab 3 of index 2, now I can push to tab 3 but index is not chaning.
onpresed is comming all screen since I have flaoting cart details in all screen when I click I want to always change index to 2 and then 2 tab sicne cart screen is tab
Navigator.push(
context,
PageRouteBuilder(
pageBuilder: (parentContext, animation, secondaryAnimation) {
return HomeMenues(2);
},
),
);
this olny push this creen for tab 3 but is not changing index
Upvotes: 0
Views: 54