Each native platform has several controls for handling list display and MvvmCross tries to treat them all in the same way - for each and every platform, MvvmCross provides or uses an ItemsSource and an ItemTemplate property for data-binding.
In this sample, we quickly run through the 4 modern platforms:
- we create a shared PCL core with a single ViewModel which contains a List
- we add a UI for each platform
- within each UI we use one or more templates to show the List and the ListItems
- within the Android and iOS platforms, we also add 2 plugins - File and DownloadCache - in order to provide some Internet image download functionality
With iOS, we do leave some ListItem/cell customisation work 'TODO' - we will return to this in the near future.
Warning: this tutorial does move quite quickly - it's designed for people who have already watched one or more of the previous N+1 videos, and for people who have some knowledge of Mvvm already.
The finished source is available on: https://github.com/slodge/NPlus1DaysOfMvvmCross/tree/master/N-02-KittenView
The video:
Previously in N+1:
- N=0 - a first application - http://slodge.blogspot.co.uk/2013/04/n0-first-mvvmcross-application-n1-days.html
- N=1 - tip calc - including the Android Designer and using IoC - http://slodge.blogspot.com/2013/04/n1-tipcalc-second-example-adding-ioc.html
Many many thanks for those tutorials and all the great work you're doing...i've finally managed to find a decent amount of time to spend on studying MvvmCross and i find it incredible! The NuGet package is a great feature, and following those videos makes all clear and easy. I think that, probably, it would be usefull to make tutorials on more "advanced" topics ( like plugin usage, file access/read, tombstoning... ). Anyway, the example code projects are truly clear and usefull.
ReplyDeleteThank You for Tools and Tutorials!!
ReplyDeleteThese videos are great, thank you! Would it be possible for you to post higher quality versions?
ReplyDelete