We have a custom renderer (ios) that works on an iphone but not on the simulator. DidReceiveServerRedirectForProvisionalNavigation never gets called. I have tried all the Linker behavior settings (Don't Link, Link Framework SDKs only, Link All) - non worked. Any ideas?
[assembly: ExportRenderer(typeof(HybridWebView), typeof(LoginHybridWebViewRenderer))]
namespace OurProject.Mobile.iOS
{
using System.IO;
using Foundation;
using UIKit;
using Xamarin.Forms.Platform.iOS;
public class LoginHybridWebViewRenderer: XLabs.Forms.Controls.HybridWebViewRenderer
{
[Export("webView:didReceiveServerRedirectForProvisionalNavigation:")]
public void DidReceiveServerRedirectForProvisionalNavigation(WKWebView webView, WKNavigation navigation)
{
this.DidStartProvisionalNavigation (webView, navigation);
}
}
}
I have added this to the AppDelegate:
public override bool FinishedLaunching (UIApplication app, NSDictionary options)
{
new LoginHybridWebViewRenderer ();
...