diff --git a/app/build.gradle b/app/build.gradle index 40494d66..220c549b 100644 --- a/app/build.gradle +++ b/app/build.gradle @@ -11,8 +11,8 @@ android { compileSdkVersion 33 buildToolsVersion '29.0.2' useLibrary 'org.apache.http.legacy' - versionCode 141 - versionName "1.8" + versionCode 142 + versionName "1.8.1" testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" } diff --git a/app/src/main/java/com/jens/automation2/Actions.java b/app/src/main/java/com/jens/automation2/Actions.java index 606917c0..f6d05a5d 100644 --- a/app/src/main/java/com/jens/automation2/Actions.java +++ b/app/src/main/java/com/jens/automation2/Actions.java @@ -1107,7 +1107,10 @@ public class Actions externalApplicationIntent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK); // Pack intents - externalApplicationIntent = packParametersIntoIntent(externalApplicationIntent, params, 3); + if(Miscellaneous.isNumeric(params[3])) + externalApplicationIntent = packParametersIntoIntent(externalApplicationIntent, params, 3); + else + externalApplicationIntent = packParametersIntoIntent(externalApplicationIntent, params, 4); if (params[2].equals(ActivityManageActionStartActivity.startByActivityString)) automationServerRef.startActivity(externalApplicationIntent); diff --git a/app/src/main/java/com/jens/automation2/ActivityManageRule.java b/app/src/main/java/com/jens/automation2/ActivityManageRule.java index 3963ba41..16f04b77 100644 --- a/app/src/main/java/com/jens/automation2/ActivityManageRule.java +++ b/app/src/main/java/com/jens/automation2/ActivityManageRule.java @@ -654,7 +654,10 @@ public class ActivityManageRule extends Activity else if(types[i].toString().equals(Trigger_Enum.checkVariable.toString())) items.add(new Item(typesLong[i].toString(), R.drawable.variable)); else if(types[i].toString().equals(Trigger_Enum.calendarEvent.toString())) - items.add(new Item(typesLong[i].toString(), R.drawable.calendar)); + { + if(ActivityPermissions.isPermissionDeclaratedInManifest(ActivityManageRule.this, Manifest.permission.READ_CALENDAR)) + items.add(new Item(typesLong[i].toString(), R.drawable.calendar)); + } else items.add(new Item(typesLong[i].toString(), R.drawable.placeholder)); } diff --git a/fastlane/metadata/android/en-US/changelogs/142.txt b/fastlane/metadata/android/en-US/changelogs/142.txt new file mode 100644 index 00000000..d6db5f2d --- /dev/null +++ b/fastlane/metadata/android/en-US/changelogs/142.txt @@ -0,0 +1,2 @@ +* Fixed: Calendar trigger hidden from Play version +* Fixed: Parameters not correctly supplied when starting other apps \ No newline at end of file