Is it possible to show the toast with duration infinity
kalyansriram opened this issue · comments
Kalyan commented
Hi,
This library looks cool. And i want to use this snackbar as toast in my app and i need to show a toast for retry action when no network is found and it shouldn't auto hide. It should be shown to the user till the user clicks retry button. Is it possible to do this with this library?
Thanks.
Jon Wimer commented
Yes, to show a SnackBar with an infinite duration just use SnackBar.PERMANENT_SNACK
as the duration parameter like so:
mSnackBar.show("This is a permanent snack", SnackBar.PERMANENT_SNACK);
Kalyan commented
Hey thats Great! Thank you! :)