jamesmontemagno / Xamarin.Plugins

Cross-platform Native API Access from Shared Code!
MIT License
1.3k stars 380 forks source link

'ConnectivityChanged' is not fired when wifi connects with active data - android only #248

Closed rayhan990 closed 8 years ago

rayhan990 commented 8 years ago

Please take a moment to fill out the following (change to preview to check or place x in []):

This is a

Which plugin does this impact:

Version Number of Plugin: 2.1.2 Device Tested On: Samsung S5 Simulator Tested On:

Expected Behavior

Fire ConnectivityChanged event

Actual Behavior

No event is fired

Steps to reproduce the Behavior

1) Disable wifi connection 2) Enable if not already enabled the data connection 3) enable wifi

For the first 2 points the 'ConnectivityChanged' event is being fired but not for the last point. The issue was detected only on Android and not on IOS.

jamesmontemagno commented 8 years ago

This is as expected

Have you tried airplane mode. According to android it has not actually lost connectivity.

rayhan990 commented 8 years ago

Hi James,

No, I only had my data activated and switching on/off the wifi connection. It detects when the wifi is off but not when it connects back.

Is it an android issue? I can understand that the connection is not lost but the type is changed.

jamesmontemagno commented 8 years ago

I mostly just listen to what Android tells me so perhaps to android it isn't a connection loss at all.