A popular feature that is often requested is multi-touch scrolling in the RadGridView control. This is easily achievable in WPF, because of the new yummy System.Windows.Input.Manipulations namespace introduced in .NET 4.0. However, Silverlight has yet to receive such a high-level touch API. The only tool we have at our disposal is the System.Windows.Input.Touch class with its one member, the FrameReported event. Nevertheless, it gives us a lot of control when it comes to handling touch events. I used it to make a little behavior that enables touch scrolling.

Get Microsoft Silverlight

You can also scroll horizontally and by dragging the mouse (both options controlled by properties on the behavior).

You can easily extend this example to include features like velocity, inertia, etc.

The source code is located here.

About the Author

Pavel Pavlov

Pavel has been part of the Telerik team for three years. He has background in various XAML technologies, including WPF, Silverlight and WinRT. He is now part of the UI for Xamarin team at Telerik.

Related Posts


Comments are disabled in preview mode.