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

Commit 2747cc20 authored by Andrei Stingaceanu's avatar Andrei Stingaceanu Committed by Android Git Automerger
Browse files

am 2e561546: Merge "Floating toolbar shown after rotation in extract mode" into mnc-dev

* commit '2e561546':
  Floating toolbar shown after rotation in extract mode
parents 5d9469c3 2e561546
Loading
Loading
Loading
Loading
+29 −24
Original line number Diff line number Diff line
@@ -4517,7 +4517,10 @@ public class Editor {
            final float eventY = event.getY();
            switch (event.getActionMasked()) {
                case MotionEvent.ACTION_DOWN:

                    if (extractedTextModeWillBeStarted()) {
                        // Prevent duplicating the selection handles until the mode starts.
                        hide();
                    } else {
                        // Remember finger down position, to be able to start selection from there.
                        mMinTouchOffset = mMaxTouchOffset = mTextView.getOffsetForPosition(
                                eventX, eventY);
@@ -4532,7 +4535,8 @@ public class Editor {
                                ViewConfiguration viewConfiguration = ViewConfiguration.get(
                                        mTextView.getContext());
                                int doubleTapSlop = viewConfiguration.getScaledDoubleTapSlop();
                            boolean stayedInArea = distanceSquared < doubleTapSlop * doubleTapSlop;
                                boolean stayedInArea =
                                        distanceSquared < doubleTapSlop * doubleTapSlop;

                                if (stayedInArea && isPositionOnText(eventX, eventY)) {
                                    selectCurrentWordAndStartDrag();
@@ -4545,6 +4549,7 @@ public class Editor {
                        mDownPositionY = eventY;
                        mGestureStayedInTapRegion = true;
                        mHaventMovedEnoughToStartDrag = true;
                    }
                    break;

                case MotionEvent.ACTION_POINTER_DOWN: