Chromium Code Reviews| Index: ui/events/gesture_detection/mock_motion_event.cc |
| diff --git a/ui/events/gesture_detection/mock_motion_event.cc b/ui/events/gesture_detection/mock_motion_event.cc |
| index 2cc8da738ac9c4f785d5d1ad32472ee2c38e7c6a..3ee63dffb4114596c148724a874064628208e6d8 100644 |
| --- a/ui/events/gesture_detection/mock_motion_event.cc |
| +++ b/ui/events/gesture_detection/mock_motion_event.cc |
| @@ -137,7 +137,7 @@ void MockMotionEvent::PressPoint(float x, float y) { |
| if (pointer_count == 1 && (action == ACTION_UP || action == ACTION_CANCEL)) |
| pointer_count = 0; |
| - DCHECK_LT(pointer_count + 1, static_cast<size_t>(MAX_POINTERS)); |
| + DCHECK_LT(pointer_count, static_cast<size_t>(MAX_POINTERS)); |
|
tdresser
2014/04/25 19:26:48
I believe this was a bug, can you double check?
jdduke (slow)
2014/04/25 19:38:55
It should be correct, note the |pointer_count++| c
tdresser
2014/04/25 19:43:25
So if I have 2 fingers down, and I press another f
jdduke (slow)
2014/04/25 19:45:26
It evaluates 2 < 3, then does the increment.
jdduke (slow)
2014/04/25 19:46:58
Ugg, lol yeah I was checking *your* code, not the
|
| points[pointer_count++] = gfx::PointF(x, y); |
| action = pointer_count > 1 ? ACTION_POINTER_DOWN : ACTION_DOWN; |
| } |