public class WidgetItem
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
WidgetItem.Builder |
static class |
WidgetItem.State |
Constructor and Description |
---|
WidgetItem(MapDataRef iconRef,
int iconWidth,
int iconHeight,
android.graphics.Point iconAnchor,
java.lang.String labelText,
int backingColor)
Create a widget item given default criteria.
|
Modifier and Type | Method and Description |
---|---|
int |
getBackingColor(int state) |
android.graphics.Point |
getIconAnchor() |
int |
getIconHeight() |
MapDataRef |
getIconRef(int state) |
int |
getIconWidth() |
java.lang.String |
getLabelText() |
WidgetItem.State[] |
getStates() |
public WidgetItem(MapDataRef iconRef, int iconWidth, int iconHeight, android.graphics.Point iconAnchor, java.lang.String labelText, int backingColor)
iconRef
- the default icon image referenceiconWidth
- the on-screen icon width in pixels (-1) if unknowniconHeight
- the on-screen icon height in pixels (-1) if unknowniconAnchor
- the pixel location of the icon anchor point (in on-screen space)labelText
- the label text for the menu itembackingColor
- the background color for the menu item (alpha supported)public MapDataRef getIconRef(int state)
state
- public int getBackingColor(int state)
state
- public java.lang.String getLabelText()
public android.graphics.Point getIconAnchor()
public int getIconWidth()
public int getIconHeight()
public WidgetItem.State[] getStates()