From 76f0f19a329d8bf3a8fbd20374067af275202186 Mon Sep 17 00:00:00 2001 From: TYM Tsai Date: Thu, 17 Feb 2022 01:47:29 +0800 Subject: [PATCH] Show only dialog presentations in the fill dialog Remove fallback to dropdown presentation if there is no dialog presentation. So the fill dialog will only shows suggestions that is exactly set a dialog presentation. Bug: 219956625 Test: Manual Change-Id: I5665e98b17dc2dcff252af3579a69e9a832f8385 --- .../com/android/server/autofill/ui/DialogFillUi.java | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/services/autofill/java/com/android/server/autofill/ui/DialogFillUi.java b/services/autofill/java/com/android/server/autofill/ui/DialogFillUi.java index e1229939e2cab..75d9b7eeecbca 100644 --- a/services/autofill/java/com/android/server/autofill/ui/DialogFillUi.java +++ b/services/autofill/java/com/android/server/autofill/ui/DialogFillUi.java @@ -275,12 +275,10 @@ final class DialogFillUi { if (index >= 0) { RemoteViews presentation = dataset.getFieldDialogPresentation(index); if (presentation == null) { - Slog.w(TAG, "fallback to presentation"); - presentation = dataset.getFieldPresentation(index); - } - if (presentation == null) { - Slog.w(TAG, "not displaying UI on field " + focusedViewId + " because " - + "service didn't provide a presentation for it on " + dataset); + if (sDebug) { + Slog.w(TAG, "not displaying UI on field " + focusedViewId + " because " + + "service didn't provide a presentation for it on " + dataset); + } continue; } final View view;