diff options
Diffstat (limited to 'services/java/com/android/server/wm/WindowManagerService.java')
-rw-r--r-- | services/java/com/android/server/wm/WindowManagerService.java | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/services/java/com/android/server/wm/WindowManagerService.java b/services/java/com/android/server/wm/WindowManagerService.java index 7760897..4ff6b06 100644 --- a/services/java/com/android/server/wm/WindowManagerService.java +++ b/services/java/com/android/server/wm/WindowManagerService.java @@ -5947,6 +5947,19 @@ public class WindowManagerService extends IWindowManager.Stub } } + /** + * Temporarily set the pointer speed. Does not save the new setting. + * Used by the settings application. + */ + public void setPointerSpeed(int speed) { + if (!checkCallingPermission(android.Manifest.permission.SET_POINTER_SPEED, + "setPointerSpeed()")) { + throw new SecurityException("Requires SET_POINTER_SPEED permission"); + } + + mInputManager.setPointerSpeed(speed); + } + private WindowState getFocusedWindow() { synchronized (mWindowMap) { return getFocusedWindowLocked(); |