SizeMode.Responsive
class SizeMode.Responsive : SizeMode, PreviewSizeMode
The GlanceAppWidget provides a UI for a fixed set of sizes.
On Android 12 and later, the composable will be run concurrently for each size provided and the mapping from size to view will be sent to the system. The framework will then decide which view to display based on the current size of the App Widget (see android.widget.RemoteViews for details)
Before Android 12, the composable will be run concurrently for each size at which the app widget may be displayed (like for Exact). For each size, the best view will be chosen, which is the largest one that fits in the available space, or the smallest one if none fit.
See the note in SizeMode for more info about handling concurrent runs for multiple sizes.
Summary
Public constructors |
|---|
Responsive(sizes: Set<DpSize>) |