Пример #1
0
 private void OnNetworkConnectivityChanged(object ignored, NetworkConnectivityChangedEventArgs e)
 {
     if (e.ConnectionStatus != _connected)
     {
         _connected = e.ConnectionStatus;
         Context.GetJavaScriptModule <RCTDeviceEventEmitter>()
         .emit("networkStatusDidChange", CreateConnectivityEventMap());
     }
 }
Пример #2
0
 private void OnNetworkConnectivityChanged(Guid guid, NLM_CONNECTIVITY connectivity)
 {
     NetworkConnectivityChangedEventArgs e = new NetworkConnectivityChangedEventArgs()
     {
         IsAvailable = _networkListManager.IsConnectedToInternet,
         ConnectionStatus = GetInternetStatus()
     };
     NetworkConnectivityChanged?.Invoke(new object(), e);
 }