Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3a32213c authored by Mike Lockwood's avatar Mike Lockwood
Browse files

Remove HardwareService and move vibrator support to VibratorService.



The lights support is only needed by PowerManagerService and NotificationManagerService, so we do not need a Binder API for it.
Move backlight and notification light support to new LightsService class.
The camera flash is now handled directly by the camera HAL, so the flash Hardware service flash support is obsolete.

Change-Id: I086d681f54668e7f7de3e8b90df3de19d59833c5
Signed-off-by: default avatarMike Lockwood <lockwood@android.com>
parent f90b1261
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -108,13 +108,13 @@ LOCAL_SRC_FILES += \
	core/java/android/hardware/ISensorService.aidl \
	core/java/android/net/IConnectivityManager.aidl \
	core/java/android/os/ICheckinService.aidl \
	core/java/android/os/IHardwareService.aidl \
	core/java/android/os/IMessenger.aidl \
	core/java/android/os/IMountService.aidl \
	core/java/android/os/INetStatService.aidl \
	core/java/android/os/IParentalControlCallback.aidl \
	core/java/android/os/IPermissionController.aidl \
	core/java/android/os/IPowerManager.aidl \
	core/java/android/os/IVibratorService.aidl \
    core/java/android/service/wallpaper/IWallpaperConnection.aidl \
    core/java/android/service/wallpaper/IWallpaperEngine.aidl \
    core/java/android/service/wallpaper/IWallpaperService.aidl \
+1 −10
Original line number Diff line number Diff line
@@ -17,19 +17,10 @@
package android.os;

/** {@hide} */
interface IHardwareService
interface IVibratorService
{
    // Vibrator support
    void vibrate(long milliseconds, IBinder token);
    void vibratePattern(in long[] pattern, int repeat, IBinder token);
    void cancelVibrate(IBinder token);

    // flashlight support
    boolean getFlashlightEnabled();
    void setFlashlightEnabled(boolean on);
    void enableCameraFlash(int milliseconds);

    // for the phone
    void setAttentionLight(boolean on, int color);
}
+3 −3
Original line number Diff line number Diff line
@@ -23,14 +23,14 @@ package android.os;
 */
public class Vibrator
{
    IHardwareService mService;
    IVibratorService mService;
    private final Binder mToken = new Binder();

    /** @hide */
    public Vibrator()
    {
        mService = IHardwareService.Stub.asInterface(
                ServiceManager.getService("hardware"));
        mService = IVibratorService.Stub.asInterface(
                ServiceManager.getService("vibrator"));
    }

    /**
+0 −1
Original line number Diff line number Diff line
@@ -54,7 +54,6 @@ LOCAL_SRC_FILES:= \
	android_os_SystemClock.cpp \
	android_os_SystemProperties.cpp \
	android_os_UEventObserver.cpp \
	android_os_Hardware.cpp \
	android_net_LocalSocketImpl.cpp \
	android_net_NetUtils.cpp \
	android_net_wifi_Wifi.cpp \
+0 −2
Original line number Diff line number Diff line
@@ -130,7 +130,6 @@ extern int register_android_os_ParcelFileDescriptor(JNIEnv *env);
extern int register_android_os_Power(JNIEnv *env);
extern int register_android_os_StatFs(JNIEnv *env);
extern int register_android_os_SystemProperties(JNIEnv *env);
extern int register_android_os_Hardware(JNIEnv* env);
extern int register_android_os_SystemClock(JNIEnv* env);
extern int register_android_os_FileObserver(JNIEnv *env);
extern int register_android_os_FileUtils(JNIEnv *env);
@@ -1166,7 +1165,6 @@ static const RegJNIRec gRegJNI[] = {
    REG_JNI(register_android_text_KeyCharacterMap),
    REG_JNI(register_android_os_Process),
    REG_JNI(register_android_os_Binder),
    REG_JNI(register_android_os_Hardware),
    REG_JNI(register_android_view_Display),
    REG_JNI(register_android_nio_utils),
    REG_JNI(register_android_graphics_PixelFormat),
Loading