lineage-sdk internal: Add LineageBatteryLights

Migrate frameworks/base lineage feature
code handling to lineage-sdk.

*) Settings observation and most lineage lights
   feature specific code has been moved to the
   lineage-sdk.

*) Battery frameworks services call out to the
   sdk to allow our features to make changes to
   lights values.

Based on the commits:

    Author: DvTonder <david.vantonder@gmail.com>
    Author: Ricardo Cerqueira <cyanogenmod@cerqueira.org>
    Date:   Mon Nov 4 00:57:51 2013 +0000
    Framework: Port CM9 features to CM10
    Change-Id: Ibd63116df90b06f6ce6adb8a0343059bbb999bfb

    Author: Pawit Pornkitprasan <p.pawit@gmail.com>
    Date:   Sun Dec 8 15:24:41 2013 +0700
    BatteryService: fix FC on boot until battery stat is present
    updateLightsLocked() can be called from CM's added SettingsObserver
    when battery stat is not present, causing an FC and a loop until
    battery stat is present.
    Change-Id: Ic4438fe50e98f1aa05ae1d0d26240bf9410fd92f

    Author: Sam Mortimer <sam@mortimer.me.uk>
    Date:   Tue Dec 31 16:22:05 2013 -0800
    [2/2] Framework: instant led test
    Adds support a new notification extra boolean
    EXTRA_FORCE_SHOW_LIGHTS.  Used by settings
    notification light picker to force lights on
    when the screen is on.
    Change-Id: If0a42d32b28fe8c02ef5f7dd148db7eb478fac17

    Author: Michael Bestas <mikeioannina@gmail.com>
    Date:   Mon Aug 18 04:56:28 2014 +0300
    Add support for single color notification LED (1/2)
    Change-Id: I367af77036da9e87c6dd0df552ce4c56d945a44d

    Author: Danesh M <daneshm90@gmail.com>
    Date:   Thu, 12 Nov 2015 10:52:11 -0800
    Framework : Move System settings to CMSettings
    Change-Id: I4e9fb06db7b9ba05e4a7bbe11916bb2271af4727

    Author: Adnan Begovic <adnan@cyngn.com>
    Date:   Mon, 9 Nov 2015 16:26:00 -0800
    fw: Move battery light settings to CMSettings.
    Change-Id: I28e60473356b2a9af152df82d34ad7abc9918682

    Author: Steve Kondik <steve@cyngn.com>
    Date:   Thu Sep 24 11:27:59 2015 -0700
    lights: Automatically generate an LED color for notifications
    Change-Id: I7288e52499819a6a6c75ed9d9ba7cfa1b13c5669
    nms: Only generate LED colors if the device has a multicolored LED
    * Check the overlay value before doing any of this stuff.
    Change-Id: Iedfceba6bfc86b2761d8af57ecab51026bfa4c19
    Change-Id: I7288e52499819a6a6c75ed9d9ba7cfa1b13c5669

    Author: Adrian DC <radian.dc@gmail.com>
    Date:   Sat Oct 14 23:08:47 2017 +0200
    fw: Rebrand to LineageOS and cleanup for Android Oreo
    Change-Id: I21d424433bb52a17eea7974c4ea29a3a16fe1be5

    Author: AdrianDC <radian.dc@gmail.com>
    Date:   Sat Jul 18 12:20:51 2015 +0200
    Lights with Screen On [1/2]: Optional allowment of lights
    Change-Id: I2071147d8ddab80ba0e1e7310e785ac3e03b3c7c
    Lights with screen on: Don't disable leds after the lockscreen
    Change-Id: If8f5b867a34be09fb061bb7ad040b16730f4e263
    Framework : Move System settings to CMSettings
    Change-Id: I4e9fb06db7b9ba05e4a7bbe11916bb2271af4727
    fw: Rebrand to LineageOS and port for Android Oreo
    Change-Id: I65cfeb659fe516ef43aa84b1c6d2eb6876df202a
    Change-Id: If8f5b867a34be09fb061bb7ad040b16730f4e263

    Author: Michael W <baddaemon87@gmail.com>
    Date:   Mon Oct 9 22:04:00 2017 +0200
    Core: Battery warning levels are inclusive, not exclusive
    Change-Id: Ib35b154b6117f7e26b4a3a5aee9254dda3adda12

    Author: Adrian DC <radian.dc@gmail.com>
    Date:   Sat Oct 14 23:08:47 2017 +0200
    fw: Rebrand to LineageOS and cleanup for Android Oreo
    Change-Id: I845f866891386aee808a4e7e80f4ab7c3ad48830

Change-Id: I13fcb1e16756a8008d0850050e0b09ab0b92a56f
1 file changed
tree: 1387ecabf212b9e1a1d7c9a2c3e7543754f391ac
  1. api/
  2. host/
  3. lineage/
  4. packages/
  5. samples/
  6. sdk/
  7. tests/
  8. .gitignore
  9. Android.mk
  10. CleanSpec.mk
  11. org.lineageos.platform.xml
  12. README.md
README.md

LineageOS Platform SDK

The Platform SDK provides a set of APIs that give you easy access to a variety of different features within LineageOS. The SDK exposes APIs and system level framework access in the Android framework that aren't available in any other distribution.

Setup

You can either download from prebuilts hosted on github or pull directly via Gradle.

Building against release artifacts

Our stable releases are mirrored in Maven Central, and you can fetch the current release by setting your build.gradle dependencies to

dependencies {
    compile 'org.lineageos:platform.sdk:5.+'
}

Building against development snapshots

Within build.gradle make sure your repositories list sonatype OSS repos for snapshots

repositories {
    maven {
        url "https://oss.sonatype.org/content/repositories/snapshots/"
    }
}

You can target the future or development branch by setting your dependencies for 6.0-SNAPSHOT

dependencies {
    compile 'org.lineageos:platform.sdk:6.0-SNAPSHOT'
}

WIKI

For further inquiries regarding this project, please reference the wiki.