RafaelBarbosatec / hidden_drawer_menu

Hidden Drawer Menu is a library for adding a beautiful drawer mode menu feature with perspective animation.
MIT License
352 stars 55 forks source link

SimpleHiddenDrawerController.of(context).setSelectedMenuPosition(SharedPref.getPreviousPosition(),openMenu: false); not working #52

Open Umar-Khan-Yousafzai opened 3 years ago

Umar-Khan-Yousafzai commented 3 years ago

Hi there, I am using your package in my application. The issue is that there's no implementation for the Routes. The problem is that our junior programmer who was tasked with this package sure that it's fine. but now it's not working.

1st issue the 2nd approach you've mentioned in your package takes screen as a widget. It's one screen per widget. How are we supposed to make it work with a bottom navigation bar? The package doesn't work with Routes.

I tried an approach of using Shared Preference and storing the current position of the Drawer's Current screen before moving to other. So I can use the value from Shared preference and set the selected position by using SimpleHiddenDrawerController.of(Context).setPosition.

image

Here you can see the snippet of how I am storing the value

image

Here you can see the way I am setting the selected position

The issue itself

When I set Position of the Drawer instead of moving to that screen the button opens up the Drawer menu itself!!!!