If you have already read the Getting Started page, you know how to add RadListView instance to your project and populate it with data. This section will demonstrate how to add different behaviors to the list view instance that we have created.
The list view behaviors can be used for efficient handling of gestures by RadListView. Each behavior handles different gestures in order to provide intuitive response. For example, when the long press gesture is detected, SelectionBehavior will select the item that was long pressed. A behavior can be added to a list view instance through the addBehavior(ListViewBehavior) method and removed through removeBehavior(ListViewBehavior). Additionally you can remove all currently added behaviors with clearBehaviors(). Here's an example of adding the LoadOnDemandBehavior to a list view instance:
LoadOnDemandBehavior loadOnDemandBehavior = new LoadOnDemandBehavior(); listView.addBehavior(loadOnDemandBehavior);
LoadOnDemandBehavior loadOnDemandBehavior = new LoadOnDemandBehavior (); listView.AddBehavior (loadOnDemandBehavior);
For now, what this will do, is to add a button at the end of the list that can be used by the end user to request loading of more items. You can have a look at the dedicated page for the LoadOnDemandBehavior to see how to actually load more items when the button is clicked. Here's the list of the behaviors that are currently available: