Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Multiple Snackbars

Is it possible to display, say, 2, 3 or 4 Snackbars (stacked) at the same time? I'm using the official Google Design and AppCompat support libraries right now, and would come handy (I'm using Snackbars to display status of the app - network status, power status, training mode, etc., which are all important information, have their own color, and I cannot concatenate them into one).

My snackbars right now are persistent, without action, and I do not plan to change this.

like image 678
fonix232 Avatar asked Feb 06 '23 07:02

fonix232


2 Answers

According to the doc : "Only one snackbar may be displayed at a time."

like image 137
vincenth Avatar answered Feb 13 '23 07:02

vincenth


Yes. But not a snackbar. Just made your own recyclerview with wrap content height and attach it to a decor view of an activity. Set gravity bottom. Any item before removed from recyclerview will be part of.

like image 36
Milan Jurkulak Avatar answered Feb 13 '23 06:02

Milan Jurkulak