diff options
author | Jeff Brown <jeffbrown@android.com> | 2011-06-02 01:26:32 -0700 |
---|---|---|
committer | Jeff Brown <jeffbrown@android.com> | 2011-06-02 15:39:21 -0700 |
commit | 1a84fd1fb7a51f3fe4f8865e1cdd09f3490f696c (patch) | |
tree | cf9491aedb10c8355e62ae8384db0e9f005beb1c /core | |
parent | 19c97d46fb57f87ff45d9e6ea7122b4eb21ede8c (diff) | |
download | frameworks_base-1a84fd1fb7a51f3fe4f8865e1cdd09f3490f696c.zip frameworks_base-1a84fd1fb7a51f3fe4f8865e1cdd09f3490f696c.tar.gz frameworks_base-1a84fd1fb7a51f3fe4f8865e1cdd09f3490f696c.tar.bz2 |
Add a preference panel for mouse speed.
Bug: 4124987
Change-Id: I3ce175d268a1d043cf5878481261b1049a15a149
Diffstat (limited to 'core')
-rw-r--r-- | core/java/android/provider/Settings.java | 11 | ||||
-rw-r--r-- | core/java/android/view/IWindowManager.aidl | 5 | ||||
-rw-r--r-- | core/res/AndroidManifest.xml | 7 | ||||
-rwxr-xr-x | core/res/res/values/strings.xml | 7 |
4 files changed, 30 insertions, 0 deletions
diff --git a/core/java/android/provider/Settings.java b/core/java/android/provider/Settings.java index fbdc0ba..58d9952 100644 --- a/core/java/android/provider/Settings.java +++ b/core/java/android/provider/Settings.java @@ -1791,6 +1791,16 @@ public final class Settings { public static final String SIP_ASK_ME_EACH_TIME = "SIP_ASK_ME_EACH_TIME"; /** + * Pointer speed setting. + * This is an integer value in a range between -7 and +7, so there are 15 possible values. + * -7 = slowest + * 0 = default speed + * +7 = fastest + * @hide + */ + public static final String POINTER_SPEED = "pointer_speed"; + + /** * Settings to backup. This is here so that it's in the same place as the settings * keys and easy to update. * @hide @@ -1854,6 +1864,7 @@ public final class Settings { USE_PTP_INTERFACE, SIP_CALL_OPTIONS, SIP_RECEIVE_CALLS, + POINTER_SPEED, }; // Settings moved to Settings.Secure diff --git a/core/java/android/view/IWindowManager.aidl b/core/java/android/view/IWindowManager.aidl index 4427eb5..ad17edf 100644 --- a/core/java/android/view/IWindowManager.aidl +++ b/core/java/android/view/IWindowManager.aidl @@ -205,4 +205,9 @@ interface IWindowManager * Called by the status bar to notify Views of changes to System UI visiblity. */ void statusBarVisibilityChanged(int visibility); + + /** + * Called by the settings application to temporarily set the pointer speed. + */ + void setPointerSpeed(int speed); } diff --git a/core/res/AndroidManifest.xml b/core/res/AndroidManifest.xml index 2f431c4..441a3bf 100644 --- a/core/res/AndroidManifest.xml +++ b/core/res/AndroidManifest.xml @@ -1071,6 +1071,13 @@ android:description="@string/permdesc_setOrientation" android:protectionLevel="signature" /> + <!-- Allows low-level access to setting the pointer speed. + Not for use by normal applications. --> + <permission android:name="android.permission.SET_POINTER_SPEED" + android:label="@string/permlab_setPointerSpeed" + android:description="@string/permdesc_setPointerSpeed" + android:protectionLevel="signature" /> + <!-- Allows an application to install packages. --> <permission android:name="android.permission.INSTALL_PACKAGES" android:label="@string/permlab_installPackages" diff --git a/core/res/res/values/strings.xml b/core/res/res/values/strings.xml index d5affae..b92bf88 100755 --- a/core/res/res/values/strings.xml +++ b/core/res/res/values/strings.xml @@ -699,6 +699,13 @@ the rotation of the screen at any time. Should never be needed for normal applications.</string> + <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. [CHAR LIMIT=30] --> + <string name="permlab_setPointerSpeed">change pointer speed</string> + <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. [CHAR LIMIT=NONE] --> + <string name="permdesc_setPointerSpeed">Allows an application to change + the mouse or trackpad pointer speed at any time. Should never be needed for + normal applications.</string> + <!-- Title of an application permission, listed so the user can choose whether they want to allow the application to do this. --> <string name="permlab_signalPersistentProcesses">send Linux signals to applications</string> <!-- Description of an application permission, listed so the user can choose whether they want to allow the application to do this. --> |