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

Commit a79c7e42 authored by Hyunyoung Song's avatar Hyunyoung Song Committed by Android (Google) Code Review
Browse files

Merge "Hide keyboard only when scrolling happens" into sc-dev

parents d12feb57 a907a995
Loading
Loading
Loading
Loading
+3 −4
Original line number Diff line number Diff line
@@ -131,11 +131,10 @@ public class ExtendedEditText extends EditText {
    public void reset() {
        if (!TextUtils.isEmpty(getText())) {
            setText("");
        } else {
        }
        if (FeatureFlags.ENABLE_DEVICE_SEARCH.get()) {
            return;
        }
        }
        if (isFocused()) {
            View nextFocus = focusSearch(View.FOCUS_DOWN);
            if (nextFocus != null) {
+1 −5
Original line number Diff line number Diff line
@@ -246,11 +246,7 @@ public class AllAppsContainerView extends SpringRelativeLayout implements DragSo
            hideInput();
            return false;
        }
        boolean shouldScroll = rv.shouldContainerScroll(ev, mLauncher.getDragLayer());
        if (shouldScroll) {
            hideInput();
        }
        return shouldScroll;
        return rv.shouldContainerScroll(ev, mLauncher.getDragLayer());
    }

    @Override
+2 −0
Original line number Diff line number Diff line
@@ -31,6 +31,7 @@ import android.util.Log;
import android.util.SparseIntArray;
import android.view.MotionEvent;
import android.view.View;
import android.view.WindowInsets;

import androidx.recyclerview.widget.RecyclerView;

@@ -188,6 +189,7 @@ public class AllAppsRecyclerView extends BaseRecyclerView {
            case SCROLL_STATE_DRAGGING:
                mgr.logger().sendToInteractionJankMonitor(
                        LAUNCHER_ALLAPPS_VERTICAL_SWIPE_BEGIN, this);
                getWindowInsetsController().hide(WindowInsets.Type.ime());
                break;
            case SCROLL_STATE_IDLE:
                mgr.logger().sendToInteractionJankMonitor(
+1 −0
Original line number Diff line number Diff line
@@ -246,6 +246,7 @@ public class AllAppsTransitionController
     * TODO: This logic should go in {@link LauncherState}
     */
    private void onProgressAnimationEnd() {
        if (FeatureFlags.ENABLE_DEVICE_SEARCH.get()) return;
        if (Float.compare(mProgress, 1f) == 0) {
            mAppsView.reset(false /* animate */);
        }
+1 −1
Original line number Diff line number Diff line
@@ -144,7 +144,7 @@ public class AllAppsSearchBarController

    @Override
    public void onFocusChange(View view, boolean hasFocus) {
        if (!hasFocus) {
        if (!hasFocus && !FeatureFlags.ENABLE_DEVICE_SEARCH.get()) {
            mInput.hideKeyboard();
        }
    }
Loading