I created a sega in my storyboard. This is a modal segment, and I gave it the LoginSegue identifier.
In my controller, I:
PerformSegue("LoginSegue", this);
Things are good. The new controller fits as expected.
To return to the calling view, I can use the unwind by dragging the decoupling button in the calling controller. It works great.
Or I can call (from code):
DismissViewController(true, null);
The fact is that I want to transfer some data.
ParentViewController is null.
I need to do some validation before I get back to the calling view, so automatically disconnecting from the button is not an option.
[Action("UnwindToCaller:")]
public void UnwindToCaller(UIStoryboardSegue seque)
{
var loginViewController = (LoginViewController)seque.SourceViewController;
var data = loginViewController.getData();
Console.WriteLine("Unwind to Caller Here.");
}
I also cannot find a way to give the segue U-Turn the storyboard identifier.
segue , , DismissViewController, .
, .