-
Notifications
You must be signed in to change notification settings - Fork 76
MtListBox
Rico Suter edited this page Jul 8, 2015
·
4 revisions
- Package: MyToolkit.Extended
- Platforms: WP7SL, WP8SL, WinRT, UWP
A ListBox with additional features.
Features on all supported platforms:
-
ScrolledToEnd
event which indicates when the user scrolled to the end of the list. Consider using a list which implements the ISupportIncrementalLoading interface instead (WinRT). -
InnerMargin
property to set a margin around all elements inside the ScrollViewer- Check out this StackOverflow question) for more information
- Every item automatically stretches to the full width of the control.
Features on WinRT, UWP:
- Transparent background
- Scrolling events and properties:
-
ScrollingStateChanged
event -
IsScrolling
property
-
Features on WP7SL and WP8SL:
- Scroll bug fixed
- Check out this article) for more information.
If the event is triggered you have to disable it because otherwise it will be triggered multiple times. Set TriggerScrolledToEndEvents
to true
if more data has been loaded and added to the list. This way you tell the control that the list is not at the end and the event will no longer be triggered.
public MyPage()
{
list.ScrolledToEnd += OnScrolledToEnd();
}
public async void OnScrolledToEnd(object sender, ScrolledToEndEventArgs args)
{
list.TriggerScrolledToEndEvents = false;
await LoadData();
list.TriggerScrolledToEndEvents = true;
}
- Previous class name: ExtendedListBox (obsolete)