AppWidgetManager.GetWidgetPreview Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Get the RemoteViews previews for this widget.
[Android.Runtime.Register("getWidgetPreview", "(Landroid/content/ComponentName;Landroid/os/UserHandle;I)Landroid/widget/RemoteViews;", "GetGetWidgetPreview_Landroid_content_ComponentName_Landroid_os_UserHandle_IHandler", ApiSince=35)]
public virtual Android.Widget.RemoteViews? GetWidgetPreview (Android.Content.ComponentName provider, Android.OS.UserHandle? profile, Android.Appwidget.AppWidgetCategory widgetCategory);
[<Android.Runtime.Register("getWidgetPreview", "(Landroid/content/ComponentName;Landroid/os/UserHandle;I)Landroid/widget/RemoteViews;", "GetGetWidgetPreview_Landroid_content_ComponentName_Landroid_os_UserHandle_IHandler", ApiSince=35)>]
abstract member GetWidgetPreview : Android.Content.ComponentName * Android.OS.UserHandle * Android.Appwidget.AppWidgetCategory -> Android.Widget.RemoteViews
override this.GetWidgetPreview : Android.Content.ComponentName * Android.OS.UserHandle * Android.Appwidget.AppWidgetCategory -> Android.Widget.RemoteViews
Parameters
- provider
- ComponentName
The ComponentName
for the android.content.BroadcastReceiver
BroadcastReceiver
provider for the AppWidget you intend to get a preview for.
- profile
- UserHandle
The profile in which the provider resides. Passing null is equivalent to querying for only the calling user.
- widgetCategory
- AppWidgetCategory
The widget category for which you want to display previews. This should be a single category. If a combination of categories is provided, this function will return a preview that matches at least one of the categories.
Returns
The widget preview for the selected category, if available.
- Attributes
Remarks
Get the RemoteViews previews for this widget.
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.