Merge "Fix selection expansion detection logic."
This commit is contained in:
committed by
Android (Google) Code Review
commit
ff37557795
@@ -4299,10 +4299,15 @@ public class Editor {
|
||||
|
||||
boolean isExpanding;
|
||||
final float xDiff = x - mPrevX;
|
||||
if (atRtl == isStartHandle()) {
|
||||
isExpanding = xDiff > 0 || currLine > mPreviousLineTouched;
|
||||
if (isStartHandle()) {
|
||||
isExpanding = currLine < mPreviousLineTouched;
|
||||
} else {
|
||||
isExpanding = xDiff < 0 || currLine < mPreviousLineTouched;
|
||||
isExpanding = currLine > mPreviousLineTouched;
|
||||
}
|
||||
if (atRtl == isStartHandle()) {
|
||||
isExpanding |= xDiff > 0;
|
||||
} else {
|
||||
isExpanding |= xDiff < 0;
|
||||
}
|
||||
|
||||
if (mTextView.getHorizontallyScrolling()) {
|
||||
|
||||
Reference in New Issue
Block a user