Nested Classes | ||
---|---|---|
class | BaseWidget.WidgetBundle | Simple class that encapsulates values to instantiate BaseWidget |
Inherited Constants | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
From class WidgetExtension
|
Inherited Fields | |||||||||
---|---|---|---|---|---|---|---|---|---|
From class WidgetExtension
|
Public Constructors | |
---|---|
BaseWidget(BaseWidget.WidgetBundle bundle)
BaseWidget constructor. |
Public Methods | |
---|---|
void |
onCreate()
Called when the widget is starting. |
abstract int |
getWidth()
Get the widget width in pixels. |
abstract int |
getHeight()
Get the widget height in pixels. |
abstract int |
getPreviewUri()
Get the widget preview image resource id used to describe this widget to the user in the host application settings. |
abstract int |
getName()
Get the widget resource name used to describe this widget to the user in the host application settings. |
int |
getCategory()
Get the widget category. |
Inherited Methods | ||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
From class WidgetExtension
|
BaseWidget constructor. This constructor is used by the system and should not be overwritten or used for instantiation.
bundle |
---|
Called when the widget is starting. This is where most initialization should go.
Get the widget preview image resource id used to describe this widget to the user in the host application settings. The string resource is written to the PREVIEW_IMAGE_URI field. getUriString can be used to retrieve the string from a resource id.
The preview image URI as a string.
Get the widget resource name used to describe this widget to the user in the host application settings. The string resource written to the NAME field.
The name.