forked from jens/Automation
v1.8.2
This commit is contained in:
@ -36,7 +36,7 @@ android {
|
||||
{
|
||||
dimension "version"
|
||||
versionNameSuffix "-googlePlay"
|
||||
targetSdkVersion 33
|
||||
targetSdkVersion 34
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -1764,7 +1764,7 @@ public class Actions
|
||||
{
|
||||
try
|
||||
{
|
||||
if(Build.VERSION.SDK_INT > Build.VERSION_CODES.O_MR1)
|
||||
if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.P)
|
||||
{
|
||||
if(MobileDataStuff.setMobileNetworkFromAndroid9(desiredState, automationServerRef))
|
||||
{
|
||||
@ -1777,9 +1777,9 @@ public class Actions
|
||||
return false;
|
||||
}
|
||||
}
|
||||
else if (Build.VERSION.SDK_INT > Build.VERSION_CODES.LOLLIPOP)
|
||||
else if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.M)
|
||||
{
|
||||
if (MobileDataStuff.setMobileNetworkTillAndroid5(desiredState, automationServerRef))
|
||||
if (MobileDataStuff.setMobileNetworkAndroid6Till8(desiredState, automationServerRef))
|
||||
{
|
||||
Miscellaneous.logEvent("i", "setDataConnectionWithRoot()", Miscellaneous.getAnyContext().getResources().getString(R.string.dataConWithRootSuccess), 2);
|
||||
return true;
|
||||
@ -1792,7 +1792,7 @@ public class Actions
|
||||
}
|
||||
else
|
||||
{
|
||||
if (MobileDataStuff.setMobileNetworkAndroid6Till8(desiredState, automationServerRef))
|
||||
if (MobileDataStuff.setMobileNetworkTillAndroid5(desiredState, automationServerRef))
|
||||
{
|
||||
Miscellaneous.logEvent("i", "setDataConnectionWithRoot()", Miscellaneous.getAnyContext().getResources().getString(R.string.dataConWithRootSuccess), 2);
|
||||
return true;
|
||||
@ -1813,8 +1813,9 @@ public class Actions
|
||||
rootString = Miscellaneous.getAnyContext().getResources().getString(R.string.phoneIsNotRooted);
|
||||
|
||||
Miscellaneous.logEvent("e", "setDataWithRoot()", "Error setting data setting with root. " + rootString + ": " + Log.getStackTraceString(e), 3);
|
||||
return false;
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
@SuppressLint("NewApi")
|
||||
|
Reference in New Issue
Block a user