diff options
| author | Mathew Inwood <mathewi@google.com> | 2021-04-26 08:19:47 +0000 |
|---|---|---|
| committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2021-04-26 08:19:47 +0000 |
| commit | 0bd58c09b2b8424310a9aaa1c53ac585c7db4ce8 (patch) | |
| tree | 5e54718d779496314fffba098859f5a420b62bae /core/java/android | |
| parent | 13e89b75d37f6176323a04ee115907057277337d (diff) | |
| parent | 1f71b142e526c6745bed33d83510537ade496805 (diff) | |
Merge "Revert^2 "API changes as requested by API council.""
Diffstat (limited to 'core/java/android')
| -rw-r--r-- | core/java/android/app/AppCompatCallbacks.java | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/core/java/android/app/AppCompatCallbacks.java b/core/java/android/app/AppCompatCallbacks.java index 28a21f767283..134cef5b6bfa 100644 --- a/core/java/android/app/AppCompatCallbacks.java +++ b/core/java/android/app/AppCompatCallbacks.java @@ -28,7 +28,7 @@ import java.util.Arrays; * * @hide */ -public final class AppCompatCallbacks extends Compatibility.Callbacks { +public final class AppCompatCallbacks implements Compatibility.BehaviorChangeDelegate { private final long[] mDisabledChanges; private final ChangeReporter mChangeReporter; @@ -38,7 +38,7 @@ public final class AppCompatCallbacks extends Compatibility.Callbacks { * @param disabledChanges Set of compatibility changes that are disabled for this process. */ public static void install(long[] disabledChanges) { - Compatibility.setCallbacks(new AppCompatCallbacks(disabledChanges)); + Compatibility.setBehaviorChangeDelegate(new AppCompatCallbacks(disabledChanges)); } private AppCompatCallbacks(long[] disabledChanges) { @@ -48,11 +48,11 @@ public final class AppCompatCallbacks extends Compatibility.Callbacks { ChangeReporter.SOURCE_APP_PROCESS); } - protected void reportChange(long changeId) { + public void onChangeReported(long changeId) { reportChange(changeId, ChangeReporter.STATE_LOGGED); } - protected boolean isChangeEnabled(long changeId) { + public boolean isChangeEnabled(long changeId) { if (Arrays.binarySearch(mDisabledChanges, changeId) < 0) { // Not present in the disabled array reportChange(changeId, ChangeReporter.STATE_ENABLED); |
