Commit 4a130a9a authored by Sylvain Berfini's avatar Sylvain Berfini 🎩

Update liblinphone network reachability

parent 4afe890b
......@@ -27,6 +27,14 @@ namespace Linphone.Model
private LinphoneManager()
{
LastKnownState = Linphone.Core.RegistrationState.RegistrationNone;
DeviceNetworkInformation.NetworkAvailabilityChanged += new EventHandler<NetworkNotificationEventArgs>(OnNetworkStatusChanged);
}
private void OnNetworkStatusChanged(object sender, NetworkNotificationEventArgs e)
{
Debug.WriteLine("[LinphoneManager] Network state changed:" + (DeviceNetworkInformation.IsNetworkAvailable ? "Available" : "Unavailable"));
LinphoneCore.SetNetworkReachable(DeviceNetworkInformation.IsNetworkAvailable);
}
private static LinphoneManager singleton;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment