ListItem
From Pointui
Represents an item in a list – used primarily for ListScreen screens.
Contents |
Properties
Attributes (NameValueCollection)
Provides a generic bin for storing key/value pairs.
Methods
void SetType(String typeName)
Sets the type of list item to display. This can only be called once for each list item, and must be one of the following values:
| typeName | Description | Attributes Used |
|---|---|---|
| “Default” | Plain list item that just displays text. | “ID” – unique id of the list item (String)
“Text” – the text to display (String) |
| “IconText” | Displays an icon and text, and an optional button icon on the right hand side of the list item. | “ID” – unique id of the list item (String)
“Text” – the text to display (String) “Icon” – icon to display (Surface) “Icon.Right” – optional right hand side icon/button to display (Surface) “Icon.Right.Selected” – optional right hand side selected image to display for the right icon/button (Surface) |
| “Message” | A list item designed to display a message such as an email or text message. | “EntryID” – unique id of the message (String)
“Subject” – subject of the message (String) “Name” – name of the sender (String) “Body” – first two lines of the body text (String) “DateTime” – when the message was delivered (DateTime) “IsUnread” – whether the message is flagged as unread or not (bool) |
void SetBookmark(String bookmark)
void SetBookmark(String bookmark, int numberOfChars)
Sets the bookmark for the list item using the supplied bookmark String. If numberOfChars is supplied then only the first numberOfChars characters of the bookmark String are used for the bookmark.
int GetIndex()
Returns the zero based index of this list item within the list.
void Refresh()
Refreshes the display of the list item. This is required if any of the Attributes are changed after the list item has been created.
