Adding permissions for pinning shortcuts.
While pinning shortcuts in DefaultLayoutParser.java a check was failed
showing that our launcher LauncherIndiaGoogle or any 3P launcher
doesn't has access to shortcuts. Adding the permissions to pass the
check.
Test: Tested locally on device.
Bug: 227290255, 259601472
Change-Id: I48ce49775b7005d20ae15b9487f4b0eed64d30a0
diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml
index 7787b7c..d83e40c 100644
--- a/core/res/AndroidManifest.xml
+++ b/core/res/AndroidManifest.xml
@@ -6100,7 +6100,7 @@
<!-- @SystemApi Allows to access all app shortcuts.
@hide -->
<permission android:name="android.permission.ACCESS_SHORTCUTS"
- android:protectionLevel="signature|role" />
+ android:protectionLevel="signature|role|recents" />
<!-- @SystemApi Allows unlimited calls to shortcut mutation APIs.
@hide -->
diff --git a/data/etc/com.android.launcher3.xml b/data/etc/com.android.launcher3.xml
index 36a5134..5616d1d 100644
--- a/data/etc/com.android.launcher3.xml
+++ b/data/etc/com.android.launcher3.xml
@@ -25,5 +25,6 @@
<permission name="android.permission.START_TASKS_FROM_RECENTS"/>
<permission name="android.permission.STATUS_BAR"/>
<permission name="android.permission.STOP_APP_SWITCHES"/>
+ <permission name="android.permission.ACCESS_SHORTCUTS"/>
</privapp-permissions>
</permissions>