Closed veloso14 closed 2 years ago
I did manage to find a fix, on the build doing this....
My thoughts are since this is static if I change from a custom icon pack to an IconPack like font awesome and back again the initState() won't be called. Which will lead to this behavior.
My thoughts are since this is static if I change from a custom icon pack to an IconPack like font awesome and back again the initState() won't be called. Which will lead to this behavior.
Thanks for your issue.
Actually it's very old the static stuff.
You can open a merge request by using provider and ChangeNotifier for this to solve, or you can wait until I've implemented it :)
But very good finding 🤝
@Ahmadre ok I will try to open a PR during this week
@veloso14 Thank you for your work on the PR. I refactored a lot and put the Provider at the right place to be only initialized once.
Please check the newest changes in master branch here with:
dependecies:
flutter_iconpicker:
git: git://github.com/Ahmadre/FlutterIconPicker.git
After you approved it, I will release a new version 👍🏼
As this was merged and works I will close this issue.
If you have any questions or concerns, please reopen this :) thx
Hello,
I am facing an issue where on one screen I pass my own customIconPack and after pushing a new screen with iconPackModes: [IconPack.fontAwesomeIcons] and going back to the previous I get shown all the icons and not just my custom one. I believe this is due to the fact that the showIconPicker is static.
Congrats on the lib btw.