From 6410338e574777aa177c683279eccdefb0594847 Mon Sep 17 00:00:00 2001 From: Joanne Chung Date: Mon, 23 Aug 2021 17:57:10 +0800 Subject: [PATCH] Copy AutofillOptions into derived Contexts 0cfcde8 fixes missing ContentCaptureOptions in the derived Context. The same issue should also exist for AutofillOptions in the derived Contexts. This change copy AutofillOptions into derived Contexts. The existing AttachedContextActivityTest verifies the derived Contexts. But this don't really reflact the issue, we will add a test later to reflect the issue. Bug: 194542019 Test: atest AttachedContextActivityTest Change-Id: I45bc87a6de37700de61d4a906001d6a4bec339ca --- core/java/android/app/ContextImpl.java | 1 + 1 file changed, 1 insertion(+) diff --git a/core/java/android/app/ContextImpl.java b/core/java/android/app/ContextImpl.java index d0acacf20a897..b443c0b517938 100644 --- a/core/java/android/app/ContextImpl.java +++ b/core/java/android/app/ContextImpl.java @@ -3124,6 +3124,7 @@ class ContextImpl extends Context { mIsConfigurationBasedContext = container.mIsConfigurationBasedContext; mContextType = container.mContextType; mContentCaptureOptions = container.mContentCaptureOptions; + mAutofillOptions = container.mAutofillOptions; } else { mBasePackageName = packageInfo.mPackageName; ApplicationInfo ainfo = packageInfo.getApplicationInfo();