-
-
Save VincentDondain/b2e4803d1402451300fdcd2fb8768478 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public partial class ViewController : UIViewController, IUIPickerViewDataSource | |
{ | |
protected ViewController (IntPtr handle) : base (handle) | |
{ | |
// Note: this .ctor should not contain any initialization logic. | |
} | |
public override void ViewDidLoad () | |
{ | |
base.ViewDidLoad (); | |
// Perform any additional setup after loading the view, typically from a nib. | |
var view = new UIPickerView (); | |
view.Model = new UIPickerViewModel (); | |
view.DataSource = this; | |
Add (view); | |
} | |
public override void DidReceiveMemoryWarning () | |
{ | |
base.DidReceiveMemoryWarning (); | |
// Release any cached data, images, etc that aren't in use. | |
} | |
public nint GetComponentCount (UIPickerView pickerView) | |
{ | |
return 1; | |
} | |
public nint GetRowsInComponent (UIPickerView pickerView, nint component) | |
{ | |
return 5; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment