am fee0f577: Merge change I99dc6477 into eclair

Merge commit 'fee0f5773335e42f4ffdf2d2d1c344ceee3ccb33' into eclair-plus-aosp

* commit 'fee0f5773335e42f4ffdf2d2d1c344ceee3ccb33':
  Add WindowManagerPolicy.allowKeyRepeat() method for disabling key repeats.
This commit is contained in:
Mike Lockwood
2009-10-22 11:16:14 -07:00
committed by Android Git Automerger
2 changed files with 12 additions and 0 deletions

View File

@ -6227,6 +6227,13 @@ public class WindowManagerService extends IWindowManager.Stub
lt.sample("2 got event ", System.nanoTime() - ev.whenNano);
}
if (lastKey != null && !mPolicy.allowKeyRepeat()) {
// cancel key repeat at the request of the policy.
lastKey = null;
downTime = 0;
lastKeyTime = curTime;
nextKeyTime = curTime + LONG_WAIT;
}
try {
if (ev != null) {
curTime = SystemClock.uptimeMillis();