This commit is contained in:
2021-12-19 17:12:24 +01:00
parent 3d8257aeec
commit 64801d8ff2
16 changed files with 154 additions and 344 deletions

View File

@ -36,8 +36,7 @@ public class Action
enableScreenRotation,disableScreenRotation,
startOtherActivity,
waitBeforeNextAction,
wakeupDevice,
turnScreenOnOrOff,
turnScreenOnOrOff,
setAirplaneMode,
setDataConnection,
speakText,
@ -91,8 +90,6 @@ public class Action
return context.getResources().getString(R.string.startOtherActivity);
case waitBeforeNextAction:
return context.getResources().getString(R.string.waitBeforeNextAction);
case wakeupDevice:
return context.getResources().getString(R.string.wakeupDevice);
case turnScreenOnOrOff:
return context.getResources().getString(R.string.turnScreenOnOrOff);
case vibrate:
@ -233,10 +230,6 @@ public class Action
{
returnString.append(Miscellaneous.getAnyContext().getResources().getString(R.string.sendTextMessage));
}
else if(this.getAction().equals(Action_Enum.wakeupDevice))
{
returnString.append(Miscellaneous.getAnyContext().getResources().getString(R.string.wakeupDevice));
}
else if(this.getAction().equals(Action_Enum.turnScreenOnOrOff))
{
if(getParameter1())
@ -415,18 +408,6 @@ public class Action
case waitBeforeNextAction:
Actions.waitBeforeNextAction(Long.parseLong(this.getParameter2()));
break;
case wakeupDevice:
Actions.wakeupDevice(Long.parseLong(this.getParameter2()));
// wakeupDevice() will create a separate thread. That'll take some time, we wait 100ms.
try
{
Thread.sleep(100);
}
catch (InterruptedException e)
{
e.printStackTrace();
}
break;
case turnScreenOnOrOff:
if(getParameter1())
{