Merge "Work around issue #65333586: Took phone out of pocket..." into oc-mr1-dev
am: f04b643ca8
Change-Id: Ib788a6ced4e7463f2696ac31362274f88192793d
This commit is contained in:
@@ -25,6 +25,7 @@ import android.hardware.input.InputManager;
|
||||
import android.hardware.input.InputManager.InputDeviceListener;
|
||||
import android.os.SystemProperties;
|
||||
import android.util.Log;
|
||||
import android.util.Slog;
|
||||
import android.view.InputDevice;
|
||||
import android.view.KeyEvent;
|
||||
import android.view.MotionEvent;
|
||||
@@ -630,6 +631,12 @@ public class PointerLocationView extends View implements InputDeviceListener,
|
||||
>> MotionEvent.ACTION_POINTER_INDEX_SHIFT; // will be 0 for UP
|
||||
|
||||
final int id = event.getPointerId(index);
|
||||
if (id >= NP) {
|
||||
Slog.wtf(TAG, "Got pointer ID out of bounds: id=" + id + " arraysize="
|
||||
+ NP + " pointerindex=" + index
|
||||
+ " action=0x" + Integer.toHexString(action));
|
||||
return;
|
||||
}
|
||||
final PointerState ps = mPointers.get(id);
|
||||
ps.mCurDown = false;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user