diff options
author | Joe Onorato <joeo@google.com> | 2010-10-12 14:46:23 -0700 |
---|---|---|
committer | Android Git Automerger <android-git-automerger@android.com> | 2010-10-12 14:46:23 -0700 |
commit | 9a12a3c8d4bb20042cf69e07d268e3a04ac71f96 (patch) | |
tree | 8077adbd81854c5b5571b57a5f9d20f28d92ca75 /services/jni | |
parent | 090ac9f7dd883aa75c899745182471d409a2b762 (diff) | |
parent | ba799098608c7be8ff1e18adfa7dc1f452205a7e (diff) | |
download | frameworks_base-9a12a3c8d4bb20042cf69e07d268e3a04ac71f96.zip frameworks_base-9a12a3c8d4bb20042cf69e07d268e3a04ac71f96.tar.gz frameworks_base-9a12a3c8d4bb20042cf69e07d268e3a04ac71f96.tar.bz2 |
am ba799098: Merge changes I76513387,I335fb671 into gingerbread
Merge commit 'ba799098608c7be8ff1e18adfa7dc1f452205a7e' into gingerbread-plus-aosp
* commit 'ba799098608c7be8ff1e18adfa7dc1f452205a7e':
Remove dead code, and make the animation a setting.
turn off the electron beam
Diffstat (limited to 'services/jni')
-rw-r--r-- | services/jni/Android.mk | 3 | ||||
-rw-r--r-- | services/jni/com_android_server_PowerManagerService.cpp | 13 |
2 files changed, 15 insertions, 1 deletions
diff --git a/services/jni/Android.mk b/services/jni/Android.mk index cdc0a6f..c90879d 100644 --- a/services/jni/Android.mk +++ b/services/jni/Android.mk @@ -23,7 +23,8 @@ LOCAL_SHARED_LIBRARIES := \ libnativehelper \ libsystem_server \ libutils \ - libui + libui \ + libsurfaceflinger_client ifeq ($(TARGET_SIMULATOR),true) ifeq ($(TARGET_OS),linux) diff --git a/services/jni/com_android_server_PowerManagerService.cpp b/services/jni/com_android_server_PowerManagerService.cpp index 146c177..2ec20bd 100644 --- a/services/jni/com_android_server_PowerManagerService.cpp +++ b/services/jni/com_android_server_PowerManagerService.cpp @@ -20,9 +20,14 @@ #include "JNIHelp.h" #include "jni.h" + #include <limits.h> + #include <android_runtime/AndroidRuntime.h> #include <utils/Timers.h> +#include <surfaceflinger/ISurfaceComposer.h> +#include <surfaceflinger/SurfaceComposerClient.h> + #include "com_android_server_PowerManagerService.h" namespace android { @@ -119,6 +124,12 @@ static void android_server_PowerManagerService_nativeSetPowerState(JNIEnv* env, gScreenBright = screenBright; } +static void android_server_PowerManagerService_nativeStartSurfaceFlingerAnimation(JNIEnv* env, + jobject obj) { + sp<ISurfaceComposer> s(ComposerService::getComposerService()); + s->turnElectronBeamOff(0); +} + // ---------------------------------------------------------------------------- static JNINativeMethod gPowerManagerServiceMethods[] = { @@ -127,6 +138,8 @@ static JNINativeMethod gPowerManagerServiceMethods[] = { (void*) android_server_PowerManagerService_nativeInit }, { "nativeSetPowerState", "(ZZ)V", (void*) android_server_PowerManagerService_nativeSetPowerState }, + { "nativeStartSurfaceFlingerAnimation", "()V", + (void*) android_server_PowerManagerService_nativeStartSurfaceFlingerAnimation }, }; #define FIND_CLASS(var, className) \ |