# Titanium.UI.DashboardItem
A dashboard item is a view that is displayed as an icon in a Titanium.UI.DashboardView.
# Overview
A DashboardItem is created using the Titanium.UI.createDashboardItem method or <DashboardItem>
Alloy element.
# Properties
# badge
Integer value displayed in a badge.
Set to 0
to reset and remove the badge.
Default: 0
# canDelete
Determines whether this item can be deleted when it edit mode.
Default: true
# selectedImage
Image or path to image to display in the item as it is selected.
# Events
# click
Fired when a click is detected against the view.
Properties
Name | Type | Description |
---|---|---|
location | Point | Coordinates |
item | Titanium.UI.DashboardItem | Item that was clicked. |
source | Object | Source object that fired the event. |
type | String | Name of the event fired. |
bubbles | Boolean | True if the event will try to bubble up if possible. |
cancelBubble | Boolean | Set to true to stop the event from bubbling. |
# delete
Fired when an item is deleted during editing mode.
Properties
Name | Type | Description |
---|---|---|
item | Titanium.UI.DashboardItem | Item that was deleted. |
source | Object | Source object that fired the event. |
type | String | Name of the event fired. |
bubbles | Boolean | True if the event will try to bubble up if possible. |
cancelBubble | Boolean | Set to true to stop the event from bubbling. |
# move
Fired when an item is moved during editing mode.
Properties
Name | Type | Description |
---|---|---|
items | Array<Titanium.UI.DashboardItem> | List of items to be committed, possibly in new order, when edit mode ends. |
item | Titanium.UI.DashboardItem | Item that was moved. |
source | Object | Source object that fired the event. |
type | String | Name of the event fired. |
bubbles | Boolean | True if the event will try to bubble up if possible. |
cancelBubble | Boolean | Set to true to stop the event from bubbling. |