diff options
| author | 2009-11-25 12:34:28 -0800 | |
|---|---|---|
| committer | 2009-11-25 12:34:28 -0800 | |
| commit | f3e291a05d1e30fe409b06ca43538ca22ee2e69b (patch) | |
| tree | 73d0001d6d8ab3a980b0730c1105e647b453dd97 | |
| parent | a85a0ac1072c7653fdafa791416658154b76ac0d (diff) | |
| parent | b11832de735e95aac1a1b9e900dbbd8285cee3ad (diff) | |
Merge change Id7b9903e into eclair-mr2
* changes:
Add setAttentionLight() to IPowerManager for the Phone app.
| -rw-r--r-- | core/java/android/os/IPowerManager.aidl | 1 | ||||
| -rw-r--r-- | services/java/com/android/server/PowerManagerService.java | 5 |
2 files changed, 6 insertions, 0 deletions
diff --git a/core/java/android/os/IPowerManager.aidl b/core/java/android/os/IPowerManager.aidl index 70a634ffdb01..0afc537cb1b9 100644 --- a/core/java/android/os/IPowerManager.aidl +++ b/core/java/android/os/IPowerManager.aidl @@ -34,4 +34,5 @@ interface IPowerManager // sets the brightness of the backlights (screen, keyboard, button) 0-255 void setBacklightBrightness(int brightness); + void setAttentionLight(boolean on, int color); } diff --git a/services/java/com/android/server/PowerManagerService.java b/services/java/com/android/server/PowerManagerService.java index b1ecb3c22512..ca7d94a683ea 100644 --- a/services/java/com/android/server/PowerManagerService.java +++ b/services/java/com/android/server/PowerManagerService.java @@ -2476,6 +2476,11 @@ class PowerManagerService extends IPowerManager.Stub } } + public void setAttentionLight(boolean on, int color) { + mContext.enforceCallingOrSelfPermission(android.Manifest.permission.DEVICE_POWER, null); + mLightsService.setAttentionLight(on, color); + } + private void enableProximityLockLocked() { if (mDebugProximitySensor) { Log.d(TAG, "enableProximityLockLocked"); |