From 93f2b3f9a21407fff6b2187949cc5f318ce05570 Mon Sep 17 00:00:00 2001 From: Ryan Mitchell Date: Fri, 21 Feb 2020 10:42:50 -0800 Subject: [PATCH] Restore UnsupportedAppUsage method call 4579c0aea24d74e0bb262b9019ab14a1fc96c1bb changed the method signature of the constructor of ResourcesKey, which is marked UnsupportedappUsage. Restore the previous signature and provide a new constructor that is hidden. Bug: 147359613 Test: none Change-Id: I391167e9064b1d88f4ad75200a190e5e3b0968cf --- core/java/android/content/res/ResourcesKey.java | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/core/java/android/content/res/ResourcesKey.java b/core/java/android/content/res/ResourcesKey.java index 9e40f46c3c212..9da0f20d10062 100644 --- a/core/java/android/content/res/ResourcesKey.java +++ b/core/java/android/content/res/ResourcesKey.java @@ -54,7 +54,6 @@ public final class ResourcesKey { private final int mHash; - @UnsupportedAppUsage public ResourcesKey(@Nullable String resDir, @Nullable String[] splitResDirs, @Nullable String[] overlayDirs, @@ -85,6 +84,18 @@ public final class ResourcesKey { mHash = hash; } + @UnsupportedAppUsage + public ResourcesKey(@Nullable String resDir, + @Nullable String[] splitResDirs, + @Nullable String[] overlayDirs, + @Nullable String[] libDirs, + int displayId, + @Nullable Configuration overrideConfig, + @Nullable CompatibilityInfo compatInfo) { + this(resDir, splitResDirs, overlayDirs, libDirs, displayId, overrideConfig, compatInfo, + null); + } + public boolean hasOverrideConfiguration() { return !Configuration.EMPTY.equals(mOverrideConfiguration); }