Loading core/res/res/values/config.xml +4 −0 Original line number Diff line number Diff line Loading @@ -218,4 +218,8 @@ <!-- Component name of the default wallpaper. This will be ImageWallpaper if not specified --> <string name="default_wallpaper_component">@null</string> <!-- Use notification light instead of attention light --> <bool name="config_hasIntrusiveLed">false</bool> </resources> services/java/com/android/server/HardwareService.java +9 −2 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package com.android.server; import com.android.cts.stub.R; import com.android.internal.app.IBatteryStats; import com.android.server.am.BatteryStatsService; Loading Loading @@ -319,7 +320,10 @@ public class HardwareService extends IHardwareService.Stub { if (!mAttentionLightOn && !mPulsing) { mPulsing = true; // Use LIGHT_ID_NOTIFICATIONS to allow full color. LIGHT_ID_ATTENTION only allows white and blue setLight_native(mNativePointer, LIGHT_ID_NOTIFICATIONS, color, int lightId = mContext.getResources().getBoolean( com.android.internal.R.bool.config_hasIntrusiveLed) ? LIGHT_ID_NOTIFICATIONS : LIGHT_ID_ATTENTION; setLight_native(mNativePointer, lightId, color, LIGHT_FLASH_HARDWARE, 7, 0, 0); mH.sendMessageDelayed(Message.obtain(mH, 1), 2000); } Loading @@ -336,7 +340,10 @@ public class HardwareService extends IHardwareService.Stub { if (mPulsing) { mPulsing = false; // Use LIGHT_ID_NOTIFICATIONS to allow full color. LIGHT_ID_ATTENTION only allows white and blue setLight_native(mNativePointer, LIGHT_ID_NOTIFICATIONS, int lightId = mContext.getResources().getBoolean( com.android.internal.R.bool.config_hasIntrusiveLed) ? LIGHT_ID_NOTIFICATIONS : LIGHT_ID_ATTENTION; setLight_native(mNativePointer, lightId, mAttentionLightOn ? 0xffffffff : 0, LIGHT_FLASH_NONE, 0, 0, 0); } Loading Loading
core/res/res/values/config.xml +4 −0 Original line number Diff line number Diff line Loading @@ -218,4 +218,8 @@ <!-- Component name of the default wallpaper. This will be ImageWallpaper if not specified --> <string name="default_wallpaper_component">@null</string> <!-- Use notification light instead of attention light --> <bool name="config_hasIntrusiveLed">false</bool> </resources>
services/java/com/android/server/HardwareService.java +9 −2 Original line number Diff line number Diff line Loading @@ -16,6 +16,7 @@ package com.android.server; import com.android.cts.stub.R; import com.android.internal.app.IBatteryStats; import com.android.server.am.BatteryStatsService; Loading Loading @@ -319,7 +320,10 @@ public class HardwareService extends IHardwareService.Stub { if (!mAttentionLightOn && !mPulsing) { mPulsing = true; // Use LIGHT_ID_NOTIFICATIONS to allow full color. LIGHT_ID_ATTENTION only allows white and blue setLight_native(mNativePointer, LIGHT_ID_NOTIFICATIONS, color, int lightId = mContext.getResources().getBoolean( com.android.internal.R.bool.config_hasIntrusiveLed) ? LIGHT_ID_NOTIFICATIONS : LIGHT_ID_ATTENTION; setLight_native(mNativePointer, lightId, color, LIGHT_FLASH_HARDWARE, 7, 0, 0); mH.sendMessageDelayed(Message.obtain(mH, 1), 2000); } Loading @@ -336,7 +340,10 @@ public class HardwareService extends IHardwareService.Stub { if (mPulsing) { mPulsing = false; // Use LIGHT_ID_NOTIFICATIONS to allow full color. LIGHT_ID_ATTENTION only allows white and blue setLight_native(mNativePointer, LIGHT_ID_NOTIFICATIONS, int lightId = mContext.getResources().getBoolean( com.android.internal.R.bool.config_hasIntrusiveLed) ? LIGHT_ID_NOTIFICATIONS : LIGHT_ID_ATTENTION; setLight_native(mNativePointer, lightId, mAttentionLightOn ? 0xffffffff : 0, LIGHT_FLASH_NONE, 0, 0, 0); } Loading