Telerik blogs

RadDataBoundListBox has been continuously developed and extended with new features like Item Animations, CheckBoxes support, Data Virtualization support etc. We have also fine-tuned its performance so that it perfectly fits in an environment of limited memory and CPU resources what a mobile phone is. You can see here a real-world scenario based comparison between RadDataBoundListBox and a standard ListBox control putting both UI Virtualization approaches head to head.

With Q1 2012 Beta we are introducing an entirely new feature which also paves the way for a more complex and performance-optimized Wrap Virtualization Layout: Horizontal Scrolling. A nice example is available in our Demos app (source code in) that showcases this feature:

 

You may now ask what’s the common thing between Horizontal Scrolling and support for Wrap Layout? Well, with this Beta release we are introducing some major architectural changes in RadDataBoundListBox’ engine which give us more freedom to implement different UI virtualization approaches and layouts. These changes include an extraction of the whole UI virtualization mechanism into a so called Strategy class which is simply plugged into the control. In this way we can easily develop a Wrap Layout Virtualization strategy and also make it available as an option in the feature set of the control.

Following is a quick code-snippet enriched demonstration of how activating horizontal scrolling in RadDataBoundListBox is done. There is a new property called VirtualizationStrategyDefinition which basically represents a definition for a given UI strategy and also a set of properties for this strategy. Currently only instances of the StackVirtualizationStrategyDefinition class can be used in this context:

 

<telerikPrimitives:RadDataBoundListBox x:Name="radDataBoundListBox">
    <telerikPrimitives:RadDataBoundListBox.VirtualizationStrategyDefinition>
        <telerikPrimitives:StackVirtualizationStrategyDefinition Orientation="Horizontal"/>
    </telerikPrimitives:RadDataBoundListBox.VirtualizationStrategyDefinition>
</telerikPrimitives:RadDataBoundListBox>

As you can see, the StackVirtualizationStrategyDefinition exposes an Orientation property which is used to define whether RadDataBoundListBox will scroll vertically or horizontally.

In near future, you will also be able to define a WrapVirtualizationStrategyDefinition by using the same approach and have your DataBoundListBox position its visual items in a wrap mode.

You can find this new functionality in the RadControls for Windows Phone 7 Q1 2012 Beta package available for download from the Downloads section of your accounts.


Deyan Ginev
About the Author

Deyan Ginev

Deyan has been with Telerik for more than ​six years working on several different products with main focus on mobile technologies. Deyan is currently working on NativeScript– a platform for developing native mobile apps with JavaScript. Find him on Twitter via
@deyan_ginev.

Comments

Comments are disabled in preview mode.