Re: [SailfishDevel] Detect network state & react on it

2016-10-09 Thread Dylan Van Assche
Original Message Subject: Re: [SailfishDevel] Detect network state & react on it Local Time: October 8, 2016 12:02 PM UTC Time: October 8, 2016 10:02 AM From: slava.mon...@jolla.com To: Dylan Van Assche , Sailfish OS Developers Hi Dylan, From QML, the easiest way is probabl

Re: [SailfishDevel] Detect network state & react on it

2016-10-08 Thread Slava Monich
Hi Dylan, From QML, the easiest way is probably to monitor /run/state/providers/connman/Internet/NetworkState and /run/state/providers/connman/Internet/NetworkType with ContextProperty object. Google for "qml contextkit contextproperty" to find some examples. That way, statefs monitors connma

[SailfishDevel] Detect network state & react on it

2016-10-08 Thread Dylan Van Assche
Hi Sailors, For my app Sailfinder I have received a bug report about the network connection. When switching between mobile data & WiFi the app misbehaves. I want to detect the current network state to avoid thsi problem. I thought of several possibilities: - Ping everytime to my website before