Rename hidden isStopped() method.

We introduced a hidden isStopped() for autofill to query the Activity
stop status, this is a final method. But the app that also has a
isStopped() method will break because the method cannot be overrided.

Try to rename the method to let it not generic to fix this app compat
issue. But this doesn't guarantee we don't have name collision in the
future.

Bug: 196929439
Test: manual. install app and the app doesn't crash.

Change-Id: I270066f77a69346b693b8329691d14fbcf66b1c6
This commit is contained in:
Joanne Chung
2021-08-18 11:11:59 +08:00
parent c4512c7788
commit b4b410f4a6
2 changed files with 2 additions and 2 deletions

View File

@@ -8410,7 +8410,7 @@ public class Activity extends ContextThemeWrapper
/**
* @hide
*/
public final boolean isStopped() {
public final boolean isVisibleForAutofill() {
return mStopped;
}

View File

@@ -324,7 +324,7 @@ public final class AutofillClientController implements AutofillManager.AutofillC
@Override
public boolean autofillClientIsVisibleForAutofill() {
return !mActivity.isStopped();
return !mActivity.isVisibleForAutofill();
}
@Override