Skip to content

Springham/MvvmCross.StackView

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MvvmCross UIStackView for iOS

UIStackView that can have a list of ViewModels bound such that Views can be dynamically added and removed from the ViewModel layer.

Setup

Usage

Bind to the source with a collection of MvxViewModels

set.Bind(MvxStackView).For(stackView => stackView.ItemsSource).To(vm => vm.Sections);

In order for this work each ViewModel must have an associated View through MvvmCross.

To provide a custom or wrapper view override GetView and return your view.

protected virtual UIView GetView(UIViewController controller)

Hooks are available to perform custom actions before/after adding and removing of views. These can be used to perform animations for example.

protected virtual void OnBeforeAdd(UIView view){}
protected virtual void OnAfterAdd(UIView view){}
protected virtual void OnBeforeRemove(UIView view){}
protected virtual void OnAfterRemove(UIView view){}

Contributions

Contributions are welcome! If you find a bug please report it and if you want a feature please report it.

If you want to contribute code please file an issue and create a branch off of the current dev branch and file a pull request.

License

Under MIT, see LICENSE file.

About

MvvmCross implementation for an iOS UIStackView

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages