Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

offlineCallback does not appear to be firing #17

Open
brookesia opened this issue May 29, 2020 · 1 comment
Open

offlineCallback does not appear to be firing #17

brookesia opened this issue May 29, 2020 · 1 comment

Comments

@brookesia
Copy link

Hi,

This looks like a great widget, I'm just trying it out at the moment to see if it will work for my app.

It seems to be working well when going from offline to online, however, going from online to offline doesn't appear to work, in the code snippet below offlineCallback is never called, additionally the offlineBanner doesn't show when going from online to offline.

The offlineBanner does show if the app starts up when offline, it's just the change from online to offline that doesn't appear to be working

...
body: ConnectivityWidget(
        onlineCallback: () {
          print('online');
        },
        offlineCallback: () {
          print('offline');
        },
        builder: (context, isOnline) {
          return CustomPaint(
...

Any suggestions grealty received.

@MaheshPeri19
Copy link

MaheshPeri19 commented Jul 14, 2020

Good one. But the issue. It is working for same device wifi / mobile connection on and off. Below is not working case.

Tested scenario :

connected internet via mobile hotspot with other mobile. when connected, online is showing. When i off the internet in other device, wifi is not connected, but showing online.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants