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

Commit 19abf2d7 authored by Leon Scroggins's avatar Leon Scroggins
Browse files

Do not store the find callback until action mode starts.

Bug:3331652

Prevents a bug where showFindDialog was apparently
called twice.

Change-Id: Ida473ef1b9b1b8b641fa3432b55d7a92eb7d0808
parent 748ba9a9
Loading
Loading
Loading
Loading
+3 −3
Original line number Diff line number Diff line
@@ -2961,12 +2961,12 @@ public class WebView extends AbsoluteLayout
     * @return boolean True if the find dialog is shown, false otherwise.
     */
    public boolean showFindDialog(String text, boolean showIme) {
        mFindCallback = new FindActionModeCallback(mContext);
        if (startActionMode(mFindCallback) == null) {
        FindActionModeCallback callback = new FindActionModeCallback(mContext);
        if (startActionMode(callback) == null) {
            // Could not start the action mode, so end Find on page
            mFindCallback = null;
            return false;
        }
        mFindCallback = callback;
        setFindIsUp(true);
        mFindCallback.setWebView(this);
        if (showIme) {