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

Commit 6c054d11 authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "Fix velocity reporting for negative values > -1"

parents 134ffb0c 4da1ee45
Loading
Loading
Loading
Loading
+5 −1
Original line number Original line Diff line number Diff line
@@ -841,6 +841,10 @@ public class PointerLocationView extends View implements InputDeviceListener,
            }
            }
            value = (float) (Math.rint(value * scale) / scale);
            value = (float) (Math.rint(value * scale) / scale);


            // Corner case: (int)-0.1 will become zero, so the negative sign gets lost
            if ((int) value == 0 && value < 0) {
                append("-");
            }
            append((int) value);
            append((int) value);


            if (precision != 0) {
            if (precision != 0) {