removed autolayout

This commit is contained in:
PVPoyer 2018-11-05 16:13:11 +01:00
parent 08698002ce
commit acc02f2981

View File

@ -268,7 +268,8 @@ public class NetworkManager extends CordovaPlugin {
// send update to javascript "navigator.network.connection"
// Jellybean sends its own info
JSONObject thisInfo = this.getConnectionInfo(info);
if (!thisInfo.equals(lastInfo)) {
if(!thisInfo.equals(lastInfo))
{
String connectionType = "";
try {
connectionType = thisInfo.get("type").toString();
@ -294,7 +295,8 @@ public class NetworkManager extends CordovaPlugin {
// If we are not connected to any network set type to none
if (!info.isConnected()) {
type = TYPE_NONE;
} else {
}
else {
type = getType(info);
}
extraInfo = info.getExtraInfo();
@ -343,16 +345,19 @@ public class NetworkManager extends CordovaPlugin {
LOG.d(LOG_TAG, "wifi : " + WIFI);
if (type.equals(WIFI)) {
return TYPE_WIFI;
} else if (type.toLowerCase().equals(TYPE_ETHERNET) || type.toLowerCase().startsWith(TYPE_ETHERNET_SHORT)) {
}
else if (type.toLowerCase().equals(TYPE_ETHERNET) || type.toLowerCase().startsWith(TYPE_ETHERNET_SHORT)) {
return TYPE_ETHERNET;
} else if (type.equals(MOBILE) || type.equals(CELLULAR)) {
}
else if (type.equals(MOBILE) || type.equals(CELLULAR)) {
type = info.getSubtypeName().toLowerCase(Locale.US);
if (type.equals(GSM) ||
type.equals(GPRS) ||
type.equals(EDGE) ||
type.equals(TWO_G)) {
return TYPE_2G;
} else if (type.startsWith(CDMA) ||
}
else if (type.startsWith(CDMA) ||
type.equals(UMTS) ||
type.equals(ONEXRTT) ||
type.equals(EHRPD) ||
@ -361,14 +366,16 @@ public class NetworkManager extends CordovaPlugin {
type.equals(HSPA) ||
type.equals(THREE_G)) {
return TYPE_3G;
} else if (type.equals(LTE) ||
}
else if (type.equals(LTE) ||
type.equals(UMB) ||
type.equals(HSPA_PLUS) ||
type.equals(FOUR_G)) {
return TYPE_4G;
}
}
} else {
}
else {
return TYPE_NONE;
}
return TYPE_UNKNOWN;