Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a94c5277 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Autofill a manual request directly when it only has one dataset."

parents c8e2d5ba f7a7bb6b
Loading
Loading
Loading
Loading
+8 −0
Original line number Original line Diff line number Diff line
@@ -23,6 +23,7 @@ import static android.view.autofill.AutofillManager.FLAG_VIEW_ENTERED;
import static android.view.autofill.AutofillManager.FLAG_VIEW_EXITED;
import static android.view.autofill.AutofillManager.FLAG_VIEW_EXITED;
import static android.view.autofill.AutofillManager.FLAG_START_SESSION;
import static android.view.autofill.AutofillManager.FLAG_START_SESSION;
import static android.view.autofill.AutofillManager.FLAG_VALUE_CHANGED;
import static android.view.autofill.AutofillManager.FLAG_VALUE_CHANGED;
import static android.view.autofill.AutofillManager.FLAG_MANUAL_REQUEST;


import static com.android.server.autofill.Helper.DEBUG;
import static com.android.server.autofill.Helper.DEBUG;
import static com.android.server.autofill.Helper.VERBOSE;
import static com.android.server.autofill.Helper.VERBOSE;
@@ -1128,6 +1129,13 @@ final class AutofillManagerServiceImpl {
                return;
                return;
            }
            }


            if ((mFlags & FLAG_MANUAL_REQUEST) != 0 && response.getDatasets() != null
                    && response.getDatasets().size() == 1) {
                Slog.d(TAG, "autofilling manual request directly");
                autoFill(response.getDatasets().get(0));
                return;
            }

            mCurrentViewState.setResponse(mCurrentResponse);
            mCurrentViewState.setResponse(mCurrentResponse);
        }
        }