Browse Source

cmsdk: correct naming of THIRD_PARTY_KEYGUARD perm

Change-Id: If2d062a90db340f8415d12897b16667fc834a848
TICKET: CYNGNOS-1705
replicant-6.0
d34d 4 years ago
committed by Gerrit Code Review
parent
commit
10da08aa5e
5 changed files with 9 additions and 4 deletions
  1. +1
    -1
      api/cm_current.txt
  2. +5
    -0
      cm/lib/main/java/org/cyanogenmod/platform/internal/LiveLockScreenServiceBroker.java
  3. +1
    -1
      cm/res/AndroidManifest.xml
  4. +1
    -1
      samples/externalviews/keyguardviewprovider/AndroidManifest.xml
  5. +1
    -1
      system-api/cm_system-current.txt

+ 1
- 1
api/cm_current.txt View File

@@ -674,7 +674,7 @@ package cyanogenmod.platform {
field public static final java.lang.String READ_MSIM_PHONE_STATE = "cyanogenmod.permission.READ_MSIM_PHONE_STATE";
field public static final java.lang.String READ_THEMES = "cyanogenmod.permission.READ_THEMES";
field public static final java.lang.String READ_WEATHER = "cyanogenmod.permission.READ_WEATHER";
field public static final java.lang.String THIRD_PARTY_KEYGUARD = "android.permission.THIRD_PARTY_KEYGUARD";
field public static final java.lang.String THIRD_PARTY_KEYGUARD = "cyanogenmod.permission.THIRD_PARTY_KEYGUARD";
field public static final java.lang.String WRITE_ALARMS = "cyanogenmod.permission.WRITE_ALARMS";
field public static final java.lang.String WRITE_DATAUSAGE = "cyanogenmod.permission.WRITE_DATAUSAGE";
field public static final java.lang.String WRITE_SECURE_SETTINGS = "cyanogenmod.permission.WRITE_SECURE_SETTINGS";


+ 5
- 0
cm/lib/main/java/org/cyanogenmod/platform/internal/LiveLockScreenServiceBroker.java View File

@@ -60,6 +60,9 @@ public class LiveLockScreenServiceBroker extends SystemService {

private static final long SERVICE_CONNECTION_WAIT_TIME_MS = 4 * 1000L; // 4 seconds

private static final String DEPRECATED_THIRD_PARTY_KEYGUARD_PERMISSION =
"android.permission.THIRD_PARTY_KEYGUARD";

private Context mContext;
// The actual LLS service to invoke
private ILiveLockScreenManagerProvider mService;
@@ -382,6 +385,8 @@ public class LiveLockScreenServiceBroker extends SystemService {
final PackageManager pm = mContext.getPackageManager();
final boolean hasThirdPartyKeyguardPermission = pm.checkPermission(
Manifest.permission.THIRD_PARTY_KEYGUARD,
llsInfo.component.getPackageName()) == PackageManager.PERMISSION_GRANTED
|| pm.checkPermission(DEPRECATED_THIRD_PARTY_KEYGUARD_PERMISSION,
llsInfo.component.getPackageName()) == PackageManager.PERMISSION_GRANTED;
if (!hasThirdPartyKeyguardPermission) {
Slog.e(TAG, "Package " + llsInfo.component.getPackageName() +


+ 1
- 1
cm/res/AndroidManifest.xml View File

@@ -139,7 +139,7 @@
android:protectionLevel="signature|privileged" />

<!-- Allows an application to be used as a third party keyguard -->
<permission android:name="android.permission.THIRD_PARTY_KEYGUARD"
<permission android:name="cyanogenmod.permission.THIRD_PARTY_KEYGUARD"
android:label="@string/permlab_thirdPartyKeyguard"
android:description="@string/permdesc_thirdPartyKeyguard"
android:protectionLevel="normal" />


+ 1
- 1
samples/externalviews/keyguardviewprovider/AndroidManifest.xml View File

@@ -22,7 +22,7 @@
<uses-sdk android:minSdkVersion="23" android:targetSdkVersion="23" />

<!-- Required permission for third party keyguard components -->
<uses-permission android:name="android.permission.THIRD_PARTY_KEYGUARD" />
<uses-permission android:name="cyanogenmod.permission.THIRD_PARTY_KEYGUARD" />

<application android:label="@string/app_name" android:icon="@drawable/ic_launcher">
<service android:name=".SampleKeyguardProviderService"


+ 1
- 1
system-api/cm_system-current.txt View File

@@ -674,7 +674,7 @@ package cyanogenmod.platform {
field public static final java.lang.String READ_MSIM_PHONE_STATE = "cyanogenmod.permission.READ_MSIM_PHONE_STATE";
field public static final java.lang.String READ_THEMES = "cyanogenmod.permission.READ_THEMES";
field public static final java.lang.String READ_WEATHER = "cyanogenmod.permission.READ_WEATHER";
field public static final java.lang.String THIRD_PARTY_KEYGUARD = "android.permission.THIRD_PARTY_KEYGUARD";
field public static final java.lang.String THIRD_PARTY_KEYGUARD = "cyanogenmod.permission.THIRD_PARTY_KEYGUARD";
field public static final java.lang.String WRITE_ALARMS = "cyanogenmod.permission.WRITE_ALARMS";
field public static final java.lang.String WRITE_DATAUSAGE = "cyanogenmod.permission.WRITE_DATAUSAGE";
field public static final java.lang.String WRITE_SECURE_SETTINGS = "cyanogenmod.permission.WRITE_SECURE_SETTINGS";


Loading…
Cancel
Save