commit | b494b30453f7b5f3c3c10d3e9c5b406f722025c4 | [log] [tgz] |
---|---|---|
author | Tadashi G. Takaoka <takaoka@google.com> | Thu Dec 06 09:57:24 2012 -0800 |
committer | Android (Google) Code Review <android-gerrit@google.com> | Thu Dec 06 09:57:24 2012 -0800 |
tree | c08bac64e2ff0fd1599505a0b77ce5452b44a582 | |
parent | d582c38ba8573bb4eefdfa46450ad64a6b52de46 [diff] | |
parent | 8c93e513ad346311144f89fe616c6794c11558f0 [diff] |
Merge "Fix off by one bug in gesture trail drawing"
diff --git a/java/src/com/android/inputmethod/keyboard/internal/GesturePreviewTrail.java b/java/src/com/android/inputmethod/keyboard/internal/GesturePreviewTrail.java index 80562cb..3a57f67 100644 --- a/java/src/com/android/inputmethod/keyboard/internal/GesturePreviewTrail.java +++ b/java/src/com/android/inputmethod/keyboard/internal/GesturePreviewTrail.java
@@ -159,7 +159,7 @@ float r1 = maxWidth / 2.0f; // Initialize bounds rectangle. outBoundsRect.set(p1x, p1y, p1x, p1y); - for (int i = startIndex + 1; i < trailSize - 1; i++) { + for (int i = startIndex + 1; i < trailSize; i++) { final int elapsedTime = sinceDown - eventTimes[i]; final int p2x = getXCoordValue(xCoords[i]); final int p2y = yCoords[i];