Commit 11680887 authored by narinder Rana's avatar narinder Rana
Browse files

initialization and identity place

parent 0cb8b626
Pipeline #134259 failed with stage
in 37 seconds
......@@ -36,15 +36,23 @@ public class ConnectivityReceiver
public void onReceive(Context context, Intent arg1) {
ConnectivityManager cm = (ConnectivityManager) context
.getSystemService(Context.CONNECTIVITY_SERVICE);
NetworkInfo activeNetwork = cm.getActiveNetworkInfo();
// NetworkInfo activeNetwork = cm.getActiveNetworkInfo();
// boolean isConnected = activeNetwork != null
// && activeNetwork.isConnectedOrConnecting();
boolean isConnected = activeNetwork != null
&& activeNetwork.isConnectedOrConnecting();
boolean isConnected =isConnected(context);
//if (connectivityReceiverListener != null) {
Log.e("TAG", "ConnectivityReceiver onNetworkConnectionChanged...." + isConnected);
//connectivityReceiverListener.onNetworkConnectionChanged(isConnected);
//}
if(isConnected){
//if Scheduler flag
//else fileObserver Flag
}
}
public interface ConnectivityReceiverListener {
......
Supports Markdown
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