sdk: Remove most public sdk parts

* Remove droiddoc, it has been commented out since a few versions
* Remove API which hasn't work since a while
* Remove org.lineageos.platform.sdk library
* Remove samples
* Remove obsolete README

Change-Id: Ieb1c2a64ee04480a81d24cb782806397f64adb7d
This commit is contained in:
Michael Bestas
2024-11-02 13:27:14 +02:00
parent 88916babb8
commit 82a2cae27e
42 changed files with 2 additions and 2063 deletions

View File

@@ -72,17 +72,6 @@ lineage_sdk_LOCAL_STATIC_JAVA_LIBRARIES = [
"vendor.lineage.touch-V1.0-java",
]
// READ ME: ########################################################
//
// When updating this list of aidl files, consider if that aidl is
// part of the SDK API. If it is, also add it to the list below that
// is preprocessed and distributed with the SDK. This list should
// not contain any aidl files for parcelables, but the one below should
// if you intend for 3rd parties to be able to send those objects
// across process boundaries.
//
// READ ME: ########################################################
java_library {
name: "org.lineageos.platform",
installable: true,
@@ -133,29 +122,6 @@ java_library {
},
}
// The SDK
// ============================================================
// Included aidl files from lineageos.app namespace
java_library {
name: "org.lineageos.platform.sdk",
required: ["services"],
static_libs: lineage_sdk_LOCAL_STATIC_JAVA_LIBRARIES,
srcs: [
lineage_sdk_src + "/**/*.java",
lineage_sdk_src + "/**/I*.aidl",
// For the generated R.java and Manifest.java
":org.lineageos.platform-res{.aapt.srcjar}",
],
aidl: {
local_include_dirs: ["sdk/src/java"],
},
}
// Minimal LineageSettings lib for apex use.
// ============================================================

View File

@@ -1,152 +0,0 @@
#
# Copyright (C) 2015 The CyanogenMod Project
# 2017-2023 The LineageOS Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
# We have a special case here where we build the library's resources
# independently from its code, so we need to find where the resource
# class source got placed in the course of building the resources.
# Thus, the magic here.
# Also, this module cannot depend directly on the R.java file; if it
# did, the PRIVATE_* vars for R.java wouldn't be guaranteed to be correct.
# Instead, it depends on the R.stamp file, which lists the corresponding
# R.java file as a prerequisite.
lineage_platform_res := APPS/org.lineageos.platform-res_intermediates/aapt
# List of packages used in lineage-api-stubs
lineage_stub_packages := lineageos.app:lineageos.content:lineageos.hardware:lineageos.media:lineageos.os:lineageos.preference:lineageos.profiles:lineageos.providers:lineageos.platform:lineageos.util:lineageos.trust
lineage_framework_module := $(LOCAL_INSTALLED_MODULE)
# Make sure that R.java and Manifest.java are built before we build
# the source for this library.
lineage_framework_res_R_stamp := \
$(call intermediates-dir-for,APPS,org.lineageos.platform-res,,COMMON)/src/R.stamp
LOCAL_ADDITIONAL_DEPENDENCIES := $(lineage_framework_res_R_stamp)
$(lineage_framework_module): | $(dir $(lineage_framework_module))org.lineageos.platform-res.apk
lineage_framework_built := $(call java-lib-deps, org.lineageos.platform)
# ===========================================================
# Common Droiddoc vars
lineage_platform_docs_src_files := \
$(call all-java-files-under, $(lineage_sdk_src)) \
$(call all-html-files-under, $(lineage_sdk_src))
lineage_platform_docs_java_libraries := \
org.lineageos.platform.sdk
# SDK version as defined
lineage_platform_docs_SDK_VERSION := 15.1
# release version
lineage_platform_docs_SDK_REL_ID := 9
lineage_platform_docs_LOCAL_MODULE_CLASS := JAVA_LIBRARIES
lineage_platform_docs_LOCAL_DROIDDOC_SOURCE_PATH := \
$(lineage_platform_docs_src_files)
lineage_platform_docs_LOCAL_ADDITIONAL_JAVA_DIR := \
$(call intermediates-dir-for,JAVA_LIBRARIES,org.lineageos.platform.sdk,,COMMON)
# ==== the api stubs and current.xml ===========================
include $(CLEAR_VARS)
LOCAL_SRC_FILES:= \
$(lineage_platform_docs_src_files)
LOCAL_INTERMEDIATE_SOURCES:= $(lineage_platform_LOCAL_INTERMEDIATE_SOURCES)
LOCAL_JAVA_LIBRARIES:= $(lineage_platform_docs_java_libraries)
LOCAL_MODULE_CLASS:= $(lineage_platform_docs_LOCAL_MODULE_CLASS)
LOCAL_DROIDDOC_SOURCE_PATH:= $(lineage_platform_docs_LOCAL_DROIDDOC_SOURCE_PATH)
LOCAL_ADDITIONAL_JAVA_DIR:= $(lineage_platform_docs_LOCAL_ADDITIONAL_JAVA_DIR)
LOCAL_ADDITIONAL_DEPENDENCIES:= $(lineage_platform_docs_LOCAL_ADDITIONAL_DEPENDENCIES)
LOCAL_MODULE := lineage-api-stubs
LOCAL_DROIDDOC_CUSTOM_TEMPLATE_DIR:= external/doclava/res/assets/templates-sdk
LOCAL_DROIDDOC_STUB_OUT_DIR := $(TARGET_OUT_COMMON_INTERMEDIATES)/JAVA_LIBRARIES/lineage-sdk_stubs_current_intermediates/src
LOCAL_DROIDDOC_OPTIONS:= \
-referenceonly \
-stubpackages $(lineage_stub_packages) \
-exclude org.lineageos.platform.internal \
-api $(INTERNAL_LINEAGE_PLATFORM_API_FILE) \
-removedApi $(INTERNAL_LINEAGE_PLATFORM_REMOVED_API_FILE) \
-nodocs
LOCAL_UNINSTALLABLE_MODULE := true
#include $(BUILD_DROIDDOC)
# $(gen), i.e. framework.aidl, is also needed while building against the current stub.
$(full_target): $(lineage_framework_built) $(gen)
$(INTERNAL_LINEAGE_PLATFORM_API_FILE): $(full_target)
$(call dist-for-goals,sdk,$(INTERNAL_LINEAGE_PLATFORM_API_FILE))
# Documentation
# ===========================================================
include $(CLEAR_VARS)
LOCAL_MODULE := org.lineageos.platform.sdk
LOCAL_INTERMEDIATE_SOURCES:= $(lineage_platform_LOCAL_INTERMEDIATE_SOURCES)
LOCAL_MODULE_CLASS := JAVA_LIBRARIES
LOCAL_MODULE_TAGS := optional
LOCAL_SRC_FILES := $(lineage_platform_docs_src_files)
LOCAL_ADDITONAL_JAVA_DIR := $(lineage_platform_docs_LOCAL_ADDITIONAL_JAVA_DIR)
LOCAL_IS_HOST_MODULE := false
LOCAL_DROIDDOC_CUSTOM_TEMPLATE_DIR := vendor/lineage/build/tools/droiddoc/templates-lineage-sdk
LOCAL_ADDITIONAL_DEPENDENCIES := \
services
LOCAL_JAVA_LIBRARIES := $(lineage_platform_docs_java_libraries)
LOCAL_DROIDDOC_OPTIONS := \
-android \
-offlinemode \
-exclude org.lineageos.platform.internal \
-hidePackage org.lineageos.platform.internal \
-hdf android.whichdoc offline \
-hdf sdk.version $(lineage_platform_docs_docs_SDK_VERSION) \
-hdf sdk.rel.id $(lineage_platform_docs_docs_SDK_REL_ID) \
-hdf sdk.preview 0 \
-since $(LINEAGE_SRC_API_DIR)/1.txt 1 \
-since $(LINEAGE_SRC_API_DIR)/2.txt 2 \
-since $(LINEAGE_SRC_API_DIR)/3.txt 3 \
-since $(LINEAGE_SRC_API_DIR)/4.txt 4 \
-since $(LINEAGE_SRC_API_DIR)/5.txt 5 \
-since $(LINEAGE_SRC_API_DIR)/6.txt 6 \
-since $(LINEAGE_SRC_API_DIR)/7.txt 7 \
-since $(LINEAGE_SRC_API_DIR)/8.txt 8 \
-since $(LINEAGE_SRC_API_DIR)/9.txt 9
$(full_target): $(lineage_framework_built) $(gen)
#include $(BUILD_DROIDDOC)
include $(call first-makefiles-under,$(LOCAL_PATH))
# Cleanup temp vars
# ===========================================================
lineage_platform_docs_src_files :=
lineage_platform_docs_java_libraries :=
lineage_platform_docs_LOCAL_ADDITIONAL_JAVA_DIR :=

View File

@@ -44,6 +44,3 @@ $(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/org.li
$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/lineage-sdk_stubs_current_intermediates)
$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/org.lineageos.platform_intermediates)
$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/obj/JAVA_LIBRARIES/org.lineageos.platform.sdk_intermediates)
# Purge out the api stubs timestamp files (they're used as a dependency for checkapi-lineage)
$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/docs/lineage-api-stubs*)
$(call add-clean-step, rm -rf $(OUT_DIR)/target/common/docs/lineage-system-api-stubs*)

View File

@@ -1,42 +0,0 @@
# 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](https://github.com/LineageOS/android_prebuilts_lineage-sdk/tree/master/current) from prebuilts hosted on github or pull directly via Gradle.
### Building against release artifacts
Our stable releases are mirrored in [Maven Central](http://search.maven.org/#search%7Cga%7C1%7Ca%3A%22platform.sdk%22), and you can fetch the current release by setting your `build.gradle` dependencies to
```gradle
dependencies {
compile 'org.lineageos:platform.sdk:5.+'
}
```
### Building against development snapshots
Within `build.gradle` make sure your `repositories` list sonatype OSS repos for snapshots
```gradle
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`
```gradle
dependencies {
compile 'org.lineageos:platform.sdk:6.0-SNAPSHOT'
}
```
### Wiki
For further inquiries regarding this project, please reference the [wiki](https://wiki.lineageos.org/sdk).

View File

@@ -1,845 +0,0 @@
package lineageos.app {
public final class Profile implements java.lang.Comparable android.os.Parcelable {
ctor public Profile(java.lang.String);
method public void addSecondaryUuid(java.util.UUID);
method public int compareTo(java.lang.Object);
method public int describeContents();
method public lineageos.profiles.AirplaneModeSettings getAirplaneMode();
method public lineageos.profiles.BrightnessSettings getBrightness();
method public lineageos.profiles.ConnectionSettings getConnectionSettingWithSubId(int);
method public java.util.Collection<lineageos.profiles.ConnectionSettings> getConnectionSettings();
method public int getDozeMode();
method public java.lang.String getName();
method public int getNotificationLightMode();
method public int getProfileType();
method public lineageos.profiles.RingModeSettings getRingMode();
method public lineageos.profiles.LockSettings getScreenLockMode();
method public java.util.UUID[] getSecondaryUuids();
method public lineageos.profiles.ConnectionSettings getSettingsForConnection(int);
method public lineageos.profiles.StreamSettings getSettingsForStream(int);
method public java.util.Collection<lineageos.profiles.StreamSettings> getStreamSettings();
method public int getTriggerState(int, java.lang.String);
method public java.util.ArrayList<lineageos.app.Profile.ProfileTrigger> getTriggersFromType(int);
method public java.util.UUID getUuid();
method public boolean isConditionalType();
method public void setAirplaneMode(lineageos.profiles.AirplaneModeSettings);
method public void setBrightness(lineageos.profiles.BrightnessSettings);
method public void setConnectionSettings(lineageos.profiles.ConnectionSettings);
method public void setDozeMode(int);
method public void setName(java.lang.String);
method public void setNotificationLightMode(int);
method public void setProfileType(int);
method public void setRingMode(lineageos.profiles.RingModeSettings);
method public void setScreenLockMode(lineageos.profiles.LockSettings);
method public void setSecondaryUuids(java.util.List<java.util.UUID>);
method public void setStreamSettings(lineageos.profiles.StreamSettings);
method public void setTrigger(lineageos.app.Profile.ProfileTrigger);
method public void writeToParcel(android.os.Parcel, int);
}
public static class Profile.DozeMode {
ctor public Profile.DozeMode();
field public static final int DEFAULT = 0; // 0x0
field public static final int DISABLE = 2; // 0x2
field public static final int ENABLE = 1; // 0x1
}
public static class Profile.LockMode {
ctor public Profile.LockMode();
field public static final int DEFAULT = 0; // 0x0
field public static final int DISABLE = 2; // 0x2
field public static final int INSECURE = 1; // 0x1
}
public static class Profile.NotificationLightMode {
ctor public Profile.NotificationLightMode();
field public static final int DEFAULT = 0; // 0x0
field public static final int DISABLE = 2; // 0x2
field public static final int ENABLE = 1; // 0x1
}
public static class Profile.ProfileTrigger implements android.os.Parcelable {
ctor public Profile.ProfileTrigger(int, java.lang.String, int, java.lang.String);
method public int describeContents();
method public java.lang.String getId();
method public java.lang.String getName();
method public int getState();
method public int getType();
method public void writeToParcel(android.os.Parcel, int);
}
public static class Profile.TriggerState {
ctor public Profile.TriggerState();
field public static final int DISABLED = 2; // 0x2
field public static final int ON_A2DP_CONNECT = 3; // 0x3
field public static final int ON_A2DP_DISCONNECT = 4; // 0x4
field public static final int ON_CONNECT = 0; // 0x0
field public static final int ON_DISCONNECT = 1; // 0x1
}
public static class Profile.TriggerType {
ctor public Profile.TriggerType();
field public static final int BLUETOOTH = 1; // 0x1
field public static final int WIFI = 0; // 0x0
}
public static class Profile.Type {
ctor public Profile.Type();
field public static final int CONDITIONAL = 1; // 0x1
field public static final int TOGGLE = 0; // 0x0
}
public class ProfileManager {
method public void addProfile(lineageos.app.Profile);
method public lineageos.app.Profile getActiveProfile();
method public static lineageos.app.ProfileManager getInstance(android.content.Context);
method public lineageos.app.Profile getProfile(java.util.UUID);
method public java.lang.String[] getProfileNames();
method public lineageos.app.Profile[] getProfiles();
method public boolean isProfilesEnabled();
method public boolean profileExists(java.lang.String);
method public boolean profileExists(java.util.UUID);
method public void removeProfile(lineageos.app.Profile);
method public void resetAll();
method public void setActiveProfile(java.util.UUID);
method public void updateProfile(lineageos.app.Profile);
field public static final java.lang.String ACTION_PROFILE_PICKER = "lineageos.platform.intent.action.PROFILE_PICKER";
field public static final java.lang.String EXTRA_LAST_PROFILE_NAME = "lastName";
field public static final java.lang.String EXTRA_LAST_PROFILE_UUID = "lastUuid";
field public static final java.lang.String EXTRA_PROFILES_STATE = "profile_state";
field public static final java.lang.String EXTRA_PROFILE_DIALOG_THEME = "lineageos.platform.intent.extra.profile.DIALOG_THEME";
field public static final java.lang.String EXTRA_PROFILE_EXISTING_UUID = "lineageos.platform.extra.profile.EXISTING_UUID";
field public static final java.lang.String EXTRA_PROFILE_NAME = "name";
field public static final java.lang.String EXTRA_PROFILE_PICKED_UUID = "lineageos.platform.intent.extra.profile.PICKED_UUID";
field public static final java.lang.String EXTRA_PROFILE_SHOW_NONE = "lineageos.platform.intent.extra.profile.SHOW_NONE";
field public static final java.lang.String EXTRA_PROFILE_TITLE = "lineageos.platform.intent.extra.profile.TITLE";
field public static final java.lang.String EXTRA_PROFILE_UUID = "uuid";
field public static final java.lang.String INTENT_ACTION_PROFILE_SELECTED = "lineageos.platform.intent.action.PROFILE_SELECTED";
field public static final java.lang.String INTENT_ACTION_PROFILE_UPDATED = "lineageos.platform.intent.action.PROFILE_UPDATED";
field public static final java.util.UUID NO_PROFILE;
field public static final java.lang.String PROFILES_STATE_CHANGED_ACTION = "lineageos.platform.app.profiles.PROFILES_STATE_CHANGED";
field public static final int PROFILES_STATE_DISABLED = 0; // 0x0
field public static final int PROFILES_STATE_ENABLED = 1; // 0x1
}
}
package lineageos.content {
public class Intent {
ctor public Intent();
}
}
package lineageos.hardware {
public class DisplayMode implements android.os.Parcelable {
ctor public DisplayMode(int, java.lang.String);
method public int describeContents();
method public void writeToParcel(android.os.Parcel, int);
field public final int id;
field public final java.lang.String name;
}
public class HSIC implements android.os.Parcelable {
ctor public HSIC(float, float, float, float, float);
method public int describeContents();
method public java.lang.String flatten();
method public static lineageos.hardware.HSIC fromFloatArray(float[]);
method public float getContrast();
method public float getHue();
method public float getIntensity();
method public float getSaturation();
method public float getSaturationThreshold();
method public float[] toFloatArray();
method public int[] toRGB();
method public static lineageos.hardware.HSIC unflattenFrom(java.lang.String) throws java.lang.NumberFormatException;
method public void writeToParcel(android.os.Parcel, int);
}
public final class LineageHardwareManager {
method public boolean get(int);
method public int getColorBalance();
method public android.util.Range<java.lang.Integer> getColorBalanceRange();
method public lineageos.hardware.DisplayMode getCurrentDisplayMode();
method public lineageos.hardware.DisplayMode getDefaultDisplayMode();
method public lineageos.hardware.HSIC getDefaultPictureAdjustment();
method public int[] getDisplayColorCalibration();
method public int getDisplayColorCalibrationMax();
method public int getDisplayColorCalibrationMin();
method public lineageos.hardware.DisplayMode[] getDisplayModes();
method public static lineageos.hardware.LineageHardwareManager getInstance(android.content.Context);
method public lineageos.hardware.HSIC getPictureAdjustment();
method public java.util.List<android.util.Range<java.lang.Float>> getPictureAdjustmentRanges();
method public lineageos.hardware.TouchscreenGesture[] getTouchscreenGestures();
method public int getVibratorDefaultIntensity();
method public int getVibratorIntensity();
method public int getVibratorMaxIntensity();
method public int getVibratorMinIntensity();
method public int getVibratorWarningIntensity();
method public boolean isSunlightEnhancementSelfManaged();
method public boolean isSupported(int);
method public boolean requireAdaptiveBacklightForSunlightEnhancement();
method public boolean set(int, boolean);
method public boolean setColorBalance(int);
method public boolean setDisplayColorCalibration(int[]);
method public boolean setDisplayMode(lineageos.hardware.DisplayMode, boolean);
method public boolean setPictureAdjustment(lineageos.hardware.HSIC);
method public boolean setTouchscreenGestureEnabled(lineageos.hardware.TouchscreenGesture, boolean);
method public boolean setVibratorIntensity(int);
field public static final int FEATURE_ADAPTIVE_BACKLIGHT = 1; // 0x1
field public static final int FEATURE_ANTI_FLICKER = 2097152; // 0x200000
field public static final int FEATURE_AUTO_CONTRAST = 4096; // 0x1000
field public static final int FEATURE_COLOR_BALANCE = 131072; // 0x20000
field public static final int FEATURE_COLOR_ENHANCEMENT = 2; // 0x2
field public static final int FEATURE_DISPLAY_COLOR_CALIBRATION = 4; // 0x4
field public static final int FEATURE_DISPLAY_MODES = 8192; // 0x2000
field public static final int FEATURE_HIGH_TOUCH_POLLING_RATE = 8; // 0x8
field public static final int FEATURE_HIGH_TOUCH_SENSITIVITY = 16; // 0x10
field public static final int FEATURE_KEY_DISABLE = 32; // 0x20
field public static final int FEATURE_KEY_SWAP = 64; // 0x40
field public static final int FEATURE_PICTURE_ADJUSTMENT = 262144; // 0x40000
field public static final int FEATURE_READING_ENHANCEMENT = 16384; // 0x4000
field public static final int FEATURE_SUNLIGHT_ENHANCEMENT = 256; // 0x100
field public static final int FEATURE_TOUCHSCREEN_GESTURES = 524288; // 0x80000
field public static final int FEATURE_TOUCH_HOVERING = 2048; // 0x800
field public static final int FEATURE_VIBRATOR = 1024; // 0x400
}
public class LiveDisplayConfig implements android.os.Parcelable {
ctor public LiveDisplayConfig(java.util.BitSet, int, int, int, boolean, boolean, boolean, boolean, android.util.Range<java.lang.Integer>, android.util.Range<java.lang.Integer>, android.util.Range<java.lang.Float>, android.util.Range<java.lang.Float>, android.util.Range<java.lang.Float>, android.util.Range<java.lang.Float>, android.util.Range<java.lang.Float>);
method public int describeContents();
method public android.util.Range<java.lang.Integer> getColorBalanceRange();
method public android.util.Range<java.lang.Integer> getColorTemperatureRange();
method public android.util.Range<java.lang.Float> getContrastRange();
method public boolean getDefaultAutoContrast();
method public boolean getDefaultAutoOutdoorMode();
method public boolean getDefaultCABC();
method public boolean getDefaultColorEnhancement();
method public int getDefaultDayTemperature();
method public int getDefaultMode();
method public int getDefaultNightTemperature();
method public android.util.Range<java.lang.Float> getHueRange();
method public android.util.Range<java.lang.Float> getIntensityRange();
method public java.util.List<android.util.Range<java.lang.Float>> getPictureAdjustmentRanges();
method public android.util.Range<java.lang.Float> getSaturationRange();
method public android.util.Range<java.lang.Float> getSaturationThresholdRange();
method public boolean hasFeature(int);
method public boolean hasModeSupport();
method public boolean isAvailable();
method public void writeToParcel(android.os.Parcel, int);
}
public class LiveDisplayManager {
method public float[] getColorAdjustment();
method public lineageos.hardware.LiveDisplayConfig getConfig();
method public int getDayColorTemperature();
method public lineageos.hardware.HSIC getDefaultPictureAdjustment();
method public static synchronized lineageos.hardware.LiveDisplayManager getInstance(android.content.Context);
method public int getMode();
method public int getNightColorTemperature();
method public lineageos.hardware.HSIC getPictureAdjustment();
method public boolean isAntiFlickerEnabled();
method public boolean isAutoContrastEnabled();
method public boolean isAutomaticOutdoorModeEnabled();
method public boolean isCABCEnabled();
method public boolean isColorEnhancementEnabled();
method public boolean isNightModeEnabled();
method public boolean setAutoContrastEnabled(boolean);
method public boolean setAutomaticOutdoorModeEnabled(boolean);
method public boolean setCABCEnabled(boolean);
method public boolean setColorAdjustment(float[]);
method public boolean setColorEnhancementEnabled(boolean);
method public boolean setDayColorTemperature(int);
method public boolean setMode(int);
method public boolean setNightColorTemperature(int);
method public boolean setPictureAdjustment(lineageos.hardware.HSIC);
field public static final int ADJUSTMENT_CONTRAST = 3; // 0x3
field public static final int ADJUSTMENT_HUE = 0; // 0x0
field public static final int ADJUSTMENT_INTENSITY = 2; // 0x2
field public static final int ADJUSTMENT_SATURATION = 1; // 0x1
field public static final int FEATURE_ANTI_FLICKER = 19; // 0x13
field public static final int FEATURE_AUTO_CONTRAST = 11; // 0xb
field public static final int FEATURE_CABC = 10; // 0xa
field public static final int FEATURE_COLOR_ADJUSTMENT = 13; // 0xd
field public static final int FEATURE_COLOR_BALANCE = 16; // 0x10
field public static final int FEATURE_COLOR_ENHANCEMENT = 12; // 0xc
field public static final int FEATURE_DISPLAY_MODES = 15; // 0xf
field public static final int FEATURE_MANAGED_OUTDOOR_MODE = 14; // 0xe
field public static final int FEATURE_PICTURE_ADJUSTMENT = 17; // 0x11
field public static final int FEATURE_READING_ENHANCEMENT = 18; // 0x12
field public static final int MODE_AUTO = 2; // 0x2
field public static final int MODE_DAY = 4; // 0x4
field public static final int MODE_NIGHT = 1; // 0x1
field public static final int MODE_OFF = 0; // 0x0
field public static final int MODE_OUTDOOR = 3; // 0x3
}
public class TouchscreenGesture implements android.os.Parcelable {
ctor public TouchscreenGesture(int, java.lang.String, int);
method public int describeContents();
method public void writeToParcel(android.os.Parcel, int);
field public final int id;
field public final int keycode;
field public final java.lang.String name;
}
}
package lineageos.os {
public class Build {
ctor public Build();
method public static java.lang.String getNameForSDKInt(int);
field public static final java.lang.String LINEAGEOS_DISPLAY_VERSION;
field public static final java.lang.String LINEAGEOS_VERSION;
field public static final java.lang.String UNKNOWN = "unknown";
}
public static class Build.LINEAGE_VERSION {
ctor public Build.LINEAGE_VERSION();
field public static final int SDK_INT;
}
public static class Build.LINEAGE_VERSION_CODES {
ctor public Build.LINEAGE_VERSION_CODES();
field public static final int APRICOT = 1; // 0x1
field public static final int BOYSENBERRY = 2; // 0x2
field public static final int CANTALOUPE = 3; // 0x3
field public static final int DRAGON_FRUIT = 4; // 0x4
field public static final int ELDERBERRY = 5; // 0x5
field public static final int FIG = 6; // 0x6
field public static final int GUAVA = 7; // 0x7
field public static final int HACKBERRY = 8; // 0x8
field public static final int ILAMA = 9; // 0x9
}
public final class Concierge {
method public static lineageos.os.Concierge.ParcelInfo prepareParcel(android.os.Parcel);
method public static lineageos.os.Concierge.ParcelInfo receiveParcel(android.os.Parcel);
}
public static final class Concierge.ParcelInfo {
method public void complete();
method public int getParcelVersion();
}
}
package lineageos.platform {
public final class Manifest {
ctor public Manifest();
}
public static final class Manifest.permission {
ctor public Manifest.permission();
field public static final java.lang.String HARDWARE_ABSTRACTION_ACCESS = "lineageos.permission.HARDWARE_ABSTRACTION_ACCESS";
field public static final java.lang.String MANAGE_LIVEDISPLAY = "lineageos.permission.MANAGE_LIVEDISPLAY";
field public static final java.lang.String MANAGE_REMOTE_PREFERENCES = "lineageos.permission.MANAGE_REMOTE_PREFERENCES";
field public static final java.lang.String MODIFY_PROFILES = "lineageos.permission.MODIFY_PROFILES";
field public static final java.lang.String TRUST_INTERFACE = "lineageos.permission.TRUST_INTERFACE";
field public static final java.lang.String WRITE_SECURE_SETTINGS = "lineageos.permission.WRITE_SECURE_SETTINGS";
field public static final java.lang.String WRITE_SETTINGS = "lineageos.permission.WRITE_SETTINGS";
}
public final class R {
ctor public R();
}
public static final class R.anim {
ctor public R.anim();
}
public static final class R.array {
ctor public R.array();
}
public static final class R.attr {
ctor public R.attr();
field public static final int minSummaryLines = 1057030154; // 0x3f01000a
field public static final int replacesKey = 1057030153; // 0x3f010009
field public static final int requiresAction = 1057030152; // 0x3f010008
field public static final int requiresConfig = 1057030148; // 0x3f010004
field public static final int requiresConfigMask = 1057030155; // 0x3f01000b
field public static final int requiresFeature = 1057030147; // 0x3f010003
field public static final int requiresOwner = 1057030150; // 0x3f010006
field public static final int requiresPackage = 1057030146; // 0x3f010002
field public static final int requiresProperty = 1057030149; // 0x3f010005
field public static final int xmlRes = 1057030151; // 0x3f010007
}
public static final class R.bool {
ctor public R.bool();
}
public static final class R.color {
ctor public R.color();
}
public static final class R.dimen {
ctor public R.dimen();
}
public static final class R.drawable {
ctor public R.drawable();
}
public static final class R.integer {
ctor public R.integer();
}
public static final class R.string {
ctor public R.string();
}
public static final class R.xml {
ctor public R.xml();
}
}
package lineageos.preference {
public class GlobalSettingSwitchPreference extends lineageos.preference.SelfRemovingSwitchPreference {
ctor public GlobalSettingSwitchPreference(android.content.Context, android.util.AttributeSet, int);
ctor public GlobalSettingSwitchPreference(android.content.Context, android.util.AttributeSet);
ctor public GlobalSettingSwitchPreference(android.content.Context);
}
public class LineageGlobalSettingSwitchPreference extends lineageos.preference.SelfRemovingSwitchPreference {
ctor public LineageGlobalSettingSwitchPreference(android.content.Context, android.util.AttributeSet, int);
ctor public LineageGlobalSettingSwitchPreference(android.content.Context, android.util.AttributeSet);
ctor public LineageGlobalSettingSwitchPreference(android.content.Context);
}
public class LineageGlobalSettingListPreference extends lineageos.preference.SelfRemovingListPreference {
ctor public LineageGlobalSettingListPreference(android.content.Context, android.util.AttributeSet, int);
ctor public LineageGlobalSettingListPreference(android.content.Context, android.util.AttributeSet);
method public int getIntValue(int);
}
public class LineageSecureSettingListPreference extends lineageos.preference.SelfRemovingListPreference {
ctor public LineageSecureSettingListPreference(android.content.Context, android.util.AttributeSet, int);
ctor public LineageSecureSettingListPreference(android.content.Context, android.util.AttributeSet);
method public int getIntValue(int);
}
public class LineageSecureSettingSwitchPreference extends lineageos.preference.SelfRemovingSwitchPreference {
ctor public LineageSecureSettingSwitchPreference(android.content.Context, android.util.AttributeSet, int);
ctor public LineageSecureSettingSwitchPreference(android.content.Context, android.util.AttributeSet);
ctor public LineageSecureSettingSwitchPreference(android.content.Context);
}
public class LineageSystemSettingDropDownPreference extends lineageos.preference.SelfRemovingDropDownPreference {
ctor public LineageSystemSettingDropDownPreference(android.content.Context, android.util.AttributeSet, int);
ctor public LineageSystemSettingDropDownPreference(android.content.Context, android.util.AttributeSet);
method public int getIntValue(int);
}
public class LineageSystemSettingListPreference extends lineageos.preference.SelfRemovingListPreference {
ctor public LineageSystemSettingListPreference(android.content.Context, android.util.AttributeSet, int);
ctor public LineageSystemSettingListPreference(android.content.Context, android.util.AttributeSet);
method public int getIntValue(int);
}
public class LineageSystemSettingSwitchPreference extends lineageos.preference.SelfRemovingSwitchPreference {
ctor public LineageSystemSettingSwitchPreference(android.content.Context, android.util.AttributeSet, int);
ctor public LineageSystemSettingSwitchPreference(android.content.Context, android.util.AttributeSet);
ctor public LineageSystemSettingSwitchPreference(android.content.Context);
}
public class RemotePreference extends lineageos.preference.SelfRemovingPreference {
ctor public RemotePreference(android.content.Context, android.util.AttributeSet, int, int);
ctor public RemotePreference(android.content.Context, android.util.AttributeSet, int);
ctor public RemotePreference(android.content.Context, android.util.AttributeSet);
method public android.content.Intent getReceiverIntent();
method protected java.lang.String getRemoteKey(android.os.Bundle);
method public void onRemoteUpdated(android.os.Bundle);
field public static final java.lang.String ACTION_REFRESH_PREFERENCE = "lineageos.intent.action.REFRESH_PREFERENCE";
field public static final java.lang.String ACTION_UPDATE_PREFERENCE = "lineageos.intent.action.UPDATE_PREFERENCE";
field public static final java.lang.String EXTRA_ENABLED = ":lineage:pref_enabled";
field public static final java.lang.String EXTRA_KEY = ":lineage:pref_key";
field public static final java.lang.String EXTRA_SUMMARY = ":lineage:pref_summary";
field public static final java.lang.String META_REMOTE_KEY = "org.lineageos.settings.summary.key";
field public static final java.lang.String META_REMOTE_RECEIVER = "org.lineageos.settings.summary.receiver";
field protected final android.content.Context mContext;
}
public class RemotePreferenceUpdater extends android.content.BroadcastReceiver {
ctor public RemotePreferenceUpdater();
method protected boolean fillResultExtras(android.content.Context, java.lang.String, android.os.Bundle);
method protected java.lang.String getSummary(android.content.Context, java.lang.String);
method public static void notifyChanged(android.content.Context, java.lang.String);
method public void onReceive(android.content.Context, android.content.Intent);
}
public class SecureSettingSwitchPreference extends lineageos.preference.SelfRemovingSwitchPreference {
ctor public SecureSettingSwitchPreference(android.content.Context, android.util.AttributeSet, int);
ctor public SecureSettingSwitchPreference(android.content.Context, android.util.AttributeSet);
ctor public SecureSettingSwitchPreference(android.content.Context);
}
public class SelfRemovingDropDownPreference extends androidx.preference.DropDownPreference {
ctor public SelfRemovingDropDownPreference(android.content.Context, android.util.AttributeSet, int);
ctor public SelfRemovingDropDownPreference(android.content.Context, android.util.AttributeSet);
ctor public SelfRemovingDropDownPreference(android.content.Context);
method public boolean isAvailable();
method public void setAvailable(boolean);
}
public class SelfRemovingListPreference extends androidx.preference.ListPreference {
ctor public SelfRemovingListPreference(android.content.Context, android.util.AttributeSet, int);
ctor public SelfRemovingListPreference(android.content.Context, android.util.AttributeSet);
ctor public SelfRemovingListPreference(android.content.Context);
method public boolean isAvailable();
method public void setAvailable(boolean);
}
public class SelfRemovingPreference extends androidx.preference.Preference {
ctor public SelfRemovingPreference(android.content.Context, android.util.AttributeSet, int, int);
ctor public SelfRemovingPreference(android.content.Context, android.util.AttributeSet, int);
ctor public SelfRemovingPreference(android.content.Context, android.util.AttributeSet);
ctor public SelfRemovingPreference(android.content.Context);
method public boolean isAvailable();
method public void setAvailable(boolean);
}
public class SelfRemovingSwitchPreference extends androidx.preference.SwitchPreference {
ctor public SelfRemovingSwitchPreference(android.content.Context, android.util.AttributeSet, int);
ctor public SelfRemovingSwitchPreference(android.content.Context, android.util.AttributeSet);
ctor public SelfRemovingSwitchPreference(android.content.Context);
method public boolean isAvailable();
method public void setAvailable(boolean);
}
public class SettingsHelper {
method public static synchronized lineageos.preference.SettingsHelper get(android.content.Context);
method public boolean getBoolean(android.net.Uri, boolean);
method public int getInt(android.net.Uri, int);
method public java.lang.String getString(android.net.Uri);
method public void putBoolean(android.net.Uri, boolean);
method public void putInt(android.net.Uri, int);
method public void putString(android.net.Uri, java.lang.String);
method public void startWatching(lineageos.preference.SettingsHelper.OnSettingsChangeListener, android.net.Uri...);
method public void stopWatching(lineageos.preference.SettingsHelper.OnSettingsChangeListener);
}
public static abstract interface SettingsHelper.OnSettingsChangeListener {
method public abstract void onSettingsChanged(android.net.Uri);
}
public class SystemSettingSwitchPreference extends lineageos.preference.SelfRemovingSwitchPreference {
ctor public SystemSettingSwitchPreference(android.content.Context, android.util.AttributeSet, int);
ctor public SystemSettingSwitchPreference(android.content.Context, android.util.AttributeSet);
ctor public SystemSettingSwitchPreference(android.content.Context);
}
}
package lineageos.profiles {
public final class AirplaneModeSettings implements android.os.Parcelable {
ctor public AirplaneModeSettings(android.os.Parcel);
ctor public AirplaneModeSettings();
ctor public AirplaneModeSettings(int, boolean);
method public int describeContents();
method public int getValue();
method public boolean isOverride();
method public void setOverride(boolean);
method public void setValue(int);
method public void writeToParcel(android.os.Parcel, int);
}
public static class AirplaneModeSettings.BooleanState {
ctor public AirplaneModeSettings.BooleanState();
field public static final int STATE_DISABLED = 0; // 0x0
field public static final int STATE_ENABLED = 1; // 0x1
}
public final class BrightnessSettings implements android.os.Parcelable {
ctor public BrightnessSettings(android.os.Parcel);
ctor public BrightnessSettings();
ctor public BrightnessSettings(int, boolean);
method public int describeContents();
method public int getValue();
method public boolean isOverride();
method public void setOverride(boolean);
method public void setValue(int);
method public void writeToParcel(android.os.Parcel, int);
}
public final class ConnectionSettings implements android.os.Parcelable {
ctor public ConnectionSettings(android.os.Parcel);
ctor public ConnectionSettings(int);
ctor public ConnectionSettings(int, int, boolean);
method public int describeContents();
method public int getConnectionId();
method public int getSubId();
method public int getValue();
method public boolean isOverride();
method public void setOverride(boolean);
method public void setSubId(int);
method public void setValue(int);
method public void writeToParcel(android.os.Parcel, int);
field public static final int PROFILE_CONNECTION_2G3G4G = 9; // 0x9
field public static final int PROFILE_CONNECTION_BLUETOOTH = 7; // 0x7
field public static final int PROFILE_CONNECTION_LOCATION = 6; // 0x6
field public static final int PROFILE_CONNECTION_MOBILEDATA = 0; // 0x0
field public static final int PROFILE_CONNECTION_NFC = 8; // 0x8
field public static final int PROFILE_CONNECTION_SYNC = 5; // 0x5
field public static final int PROFILE_CONNECTION_WIFI = 1; // 0x1
field public static final int PROFILE_CONNECTION_WIFIAP = 2; // 0x2
}
public static class ConnectionSettings.BooleanState {
ctor public ConnectionSettings.BooleanState();
field public static final int STATE_DISABLED = 0; // 0x0
field public static final int STATE_ENABLED = 1; // 0x1
}
public final class LockSettings implements android.os.Parcelable {
ctor public LockSettings(android.os.Parcel);
ctor public LockSettings();
ctor public LockSettings(int);
method public int describeContents();
method public int getValue();
method public void setValue(int);
method public void writeToParcel(android.os.Parcel, int);
}
public final class RingModeSettings implements android.os.Parcelable {
ctor public RingModeSettings(android.os.Parcel);
ctor public RingModeSettings();
ctor public RingModeSettings(java.lang.String, boolean);
method public int describeContents();
method public java.lang.String getValue();
method public boolean isOverride();
method public void setOverride(boolean);
method public void setValue(java.lang.String);
method public void writeToParcel(android.os.Parcel, int);
field public static final java.lang.String RING_MODE_MUTE = "mute";
field public static final java.lang.String RING_MODE_NORMAL = "normal";
field public static final java.lang.String RING_MODE_VIBRATE = "vibrate";
}
public final class StreamSettings implements android.os.Parcelable {
ctor public StreamSettings(android.os.Parcel);
ctor public StreamSettings(int);
ctor public StreamSettings(int, int, boolean);
method public int describeContents();
method public int getStreamId();
method public int getValue();
method public boolean isOverride();
method public void setOverride(boolean);
method public void setValue(int);
method public void writeToParcel(android.os.Parcel, int);
}
}
package lineageos.providers {
public final class LineageSettings {
ctor public LineageSettings();
field public static final java.lang.String ACTION_DATA_USAGE = "lineageos.settings.ACTION_DATA_USAGE";
field public static final java.lang.String ACTION_LIVEDISPLAY_SETTINGS = "lineageos.settings.LIVEDISPLAY_SETTINGS";
field public static final java.lang.String ACTION_TRUST_INTERFACE = "lineageos.settings.TRUST_INTERFACE";
field public static final java.lang.String AUTHORITY = "lineagesettings";
}
public static final class LineageSettings.Global extends android.provider.Settings.NameValueTable {
ctor public LineageSettings.Global();
method public static float getFloat(android.content.ContentResolver, java.lang.String, float);
method public static float getFloat(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static int getInt(android.content.ContentResolver, java.lang.String, int);
method public static int getInt(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static long getLong(android.content.ContentResolver, java.lang.String, long);
method public static long getLong(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static java.lang.String getString(android.content.ContentResolver, java.lang.String);
method public static java.lang.String getString(android.content.ContentResolver, java.lang.String, java.lang.String);
method public static android.net.Uri getUriFor(java.lang.String);
method public static boolean putFloat(android.content.ContentResolver, java.lang.String, float);
method public static boolean putInt(android.content.ContentResolver, java.lang.String, int);
method public static boolean putLong(android.content.ContentResolver, java.lang.String, long);
method public static boolean putString(android.content.ContentResolver, java.lang.String, java.lang.String);
field public static final android.net.Uri CONTENT_URI;
field public static final java.lang.String SYS_PROP_LINEAGE_SETTING_VERSION = "sys.lineage_settings_global_version";
}
public static class LineageSettings.LineageSettingNotFoundException extends android.util.AndroidException {
ctor public LineageSettings.LineageSettingNotFoundException(java.lang.String);
}
public static final class LineageSettings.Secure extends android.provider.Settings.NameValueTable {
ctor public LineageSettings.Secure();
method public static float getFloat(android.content.ContentResolver, java.lang.String, float);
method public static float getFloat(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static int getInt(android.content.ContentResolver, java.lang.String, int);
method public static int getInt(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static long getLong(android.content.ContentResolver, java.lang.String, long);
method public static long getLong(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static java.lang.String getString(android.content.ContentResolver, java.lang.String);
method public static java.lang.String getString(android.content.ContentResolver, java.lang.String, java.lang.String);
method public static android.net.Uri getUriFor(java.lang.String);
method public static boolean putFloat(android.content.ContentResolver, java.lang.String, float);
method public static boolean putInt(android.content.ContentResolver, java.lang.String, int);
method public static boolean putLong(android.content.ContentResolver, java.lang.String, long);
method public static boolean putString(android.content.ContentResolver, java.lang.String, java.lang.String);
field public static final android.net.Uri CONTENT_URI;
field public static final java.lang.String SYS_PROP_LINEAGE_SETTING_VERSION = "sys.lineage_settings_secure_version";
field public static final java.lang.String TRUST_WARNINGS = "trust_warnings";
}
public static final class LineageSettings.System extends android.provider.Settings.NameValueTable {
ctor public LineageSettings.System();
method public static float getFloat(android.content.ContentResolver, java.lang.String, float);
method public static float getFloat(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static int getInt(android.content.ContentResolver, java.lang.String, int);
method public static int getInt(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static long getLong(android.content.ContentResolver, java.lang.String, long);
method public static long getLong(android.content.ContentResolver, java.lang.String) throws lineageos.providers.LineageSettings.LineageSettingNotFoundException;
method public static java.lang.String getString(android.content.ContentResolver, java.lang.String);
method public static java.lang.String getString(android.content.ContentResolver, java.lang.String, java.lang.String);
method public static android.net.Uri getUriFor(java.lang.String);
method public static boolean putFloat(android.content.ContentResolver, java.lang.String, float);
method public static boolean putInt(android.content.ContentResolver, java.lang.String, int);
method public static boolean putLong(android.content.ContentResolver, java.lang.String, long);
method public static boolean putString(android.content.ContentResolver, java.lang.String, java.lang.String);
field public static final java.lang.String APP_SWITCH_WAKE_SCREEN = "app_switch_wake_screen";
field public static final java.lang.String ASSIST_WAKE_SCREEN = "assist_wake_screen";
field public static final java.lang.String BACK_WAKE_SCREEN = "back_wake_screen";
field public static final java.lang.String BATTERY_LIGHT_BRIGHTNESS_LEVEL = "battery_light_brightness_level";
field public static final java.lang.String BATTERY_LIGHT_BRIGHTNESS_LEVEL_ZEN = "battery_light_brightness_level_zen";
field public static final java.lang.String BATTERY_LIGHT_ENABLED = "battery_light_enabled";
field public static final java.lang.String BATTERY_LIGHT_FULL_COLOR = "battery_light_full_color";
field public static final java.lang.String BATTERY_LIGHT_LOW_COLOR = "battery_light_low_color";
field public static final java.lang.String BATTERY_LIGHT_MEDIUM_COLOR = "battery_light_medium_color";
field public static final java.lang.String BATTERY_LIGHT_PULSE = "battery_light_pulse";
field public static final java.lang.String BLUETOOTH_ACCEPT_ALL_FILES = "bluetooth_accept_all_files";
field public static final java.lang.String BUTTON_BACKLIGHT_ONLY_WHEN_PRESSED = "button_backlight_only_when_pressed";
field public static final java.lang.String CALL_RECORDING_FORMAT = "call_recording_format";
field public static final java.lang.String CAMERA_LAUNCH = "camera_launch";
field public static final java.lang.String CAMERA_SLEEP_ON_RELEASE = "camera_sleep_on_release";
field public static final java.lang.String CAMERA_WAKE_SCREEN = "camera_wake_screen";
field public static final android.net.Uri CONTENT_URI;
field public static final java.lang.String DISPLAY_ANTI_FLICKER = "display_anti_flicker";
field public static final java.lang.String DISPLAY_AUTO_CONTRAST = "display_auto_contrast";
field public static final java.lang.String DISPLAY_AUTO_OUTDOOR_MODE = "display_auto_outdoor_mode";
field public static final java.lang.String DISPLAY_CABC = "display_low_power";
field public static final java.lang.String DISPLAY_COLOR_ADJUSTMENT = "display_color_adjustment";
field public static final java.lang.String DISPLAY_COLOR_ENHANCE = "display_color_enhance";
field public static final java.lang.String DISPLAY_PICTURE_ADJUSTMENT = "display_picture_adjustment";
field public static final java.lang.String DISPLAY_READING_MODE = "display_reading_mode";
field public static final java.lang.String DISPLAY_TEMPERATURE_DAY = "display_temperature_day";
field public static final java.lang.String DISPLAY_TEMPERATURE_MODE = "display_temperature_mode";
field public static final java.lang.String DISPLAY_TEMPERATURE_NIGHT = "display_temperature_night";
field public static final java.lang.String DOUBLE_TAP_SLEEP_GESTURE = "double_tap_sleep_gesture";
field public static final java.lang.String HEADSET_CONNECT_PLAYER = "headset_connect_player";
field public static final java.lang.String HIGH_TOUCH_POLLING_RATE_ENABLE = "high_touch_polling_rate_enable";
field public static final java.lang.String HIGH_TOUCH_SENSITIVITY_ENABLE = "high_touch_sensitivity_enable";
field public static final java.lang.String HOME_WAKE_SCREEN = "home_wake_screen";
field public static final java.lang.String INCREASING_RING = "increasing_ring";
field public static final java.lang.String INCREASING_RING_RAMP_UP_TIME = "increasing_ring_ramp_up_time";
field public static final java.lang.String INCREASING_RING_START_VOLUME = "increasing_ring_start_vol";
field public static final java.lang.String KEY_APP_SWITCH_ACTION = "key_app_switch_action";
field public static final java.lang.String KEY_APP_SWITCH_LONG_PRESS_ACTION = "key_app_switch_long_press_action";
field public static final java.lang.String KEY_ASSIST_ACTION = "key_assist_action";
field public static final java.lang.String KEY_ASSIST_LONG_PRESS_ACTION = "key_assist_long_press_action";
field public static final java.lang.String KEY_EDGE_LONG_SWIPE_ACTION = "key_edge_long_swipe_action";
field public static final java.lang.String KEY_HOME_DOUBLE_TAP_ACTION = "key_home_double_tap_action";
field public static final java.lang.String KEY_HOME_LONG_PRESS_ACTION = "key_home_long_press_action";
field public static final java.lang.String KEY_MENU_ACTION = "key_menu_action";
field public static final java.lang.String KEY_MENU_LONG_PRESS_ACTION = "key_menu_long_press_action";
field public static final java.lang.String LOCKSCREEN_PIN_SCRAMBLE_LAYOUT = "lockscreen_scramble_pin_layout";
field public static final java.lang.String LOCKSCREEN_ROTATION = "lockscreen_rotation";
field public static final java.lang.String LONG_SCREEN_APPS = "long_screen_apps";
field public static final java.lang.String MENU_WAKE_SCREEN = "menu_wake_screen";
field public static final java.lang.String NAVBAR_LEFT_IN_LANDSCAPE = "navigation_bar_left";
field public static final java.lang.String NAVIGATION_BAR_MENU_ARROW_KEYS = "navigation_bar_menu_arrow_keys";
field public static final java.lang.String NAVIGATION_BAR_HINT = "navigation_bar_hint";
field public static final java.lang.String NAV_BUTTONS = "nav_buttons";
field public static final java.lang.String NOTIFICATION_LIGHT_BRIGHTNESS_LEVEL = "notification_light_brightness_level";
field public static final java.lang.String NOTIFICATION_LIGHT_BRIGHTNESS_LEVEL_ZEN = "notification_light_brightness_level_zen";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_CALL_COLOR = "notification_light_pulse_call_color";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_CALL_LED_OFF = "notification_light_pulse_call_led_off";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_CALL_LED_ON = "notification_light_pulse_call_led_on";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_CUSTOM_ENABLE = "notification_light_pulse_custom_enable";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_CUSTOM_VALUES = "notification_light_pulse_custom_values";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_DEFAULT_COLOR = "notification_light_pulse_default_color";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_OFF = "notification_light_pulse_default_led_off";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_ON = "notification_light_pulse_default_led_on";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_VMAIL_COLOR = "notification_light_pulse_vmail_color";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_VMAIL_LED_OFF = "notification_light_pulse_vmail_led_off";
field public static final java.lang.String NOTIFICATION_LIGHT_PULSE_VMAIL_LED_ON = "notification_light_pulse_vmail_led_on";
field public static final java.lang.String NOTIFICATION_LIGHT_SCREEN_ON = "notification_light_screen_on_enable";
field public static final java.lang.String NOTIFICATION_PLAY_QUEUE = "notification_play_queue";
field public static final java.lang.String PROXIMITY_ON_WAKE = "proximity_on_wake";
field public static final java.lang.String QS_SHOW_BRIGHTNESS_SLIDER = "qs_show_brightness_slider";
field public static final java.lang.String RECENTS_SHOW_SEARCH_BAR = "recents_show_search_bar";
field public static final java.lang.String SHOW_ALARM_ICON = "show_alarm_icon";
field public static final java.lang.String STATUS_BAR_AM_PM = "status_bar_am_pm";
field public static final java.lang.String STATUS_BAR_BATTERY_STYLE = "status_bar_battery_style";
field public static final java.lang.String STATUS_BAR_CLOCK = "status_bar_clock";
field public static final java.lang.String STATUS_BAR_IME_SWITCHER = "status_bar_ime_switcher";
field public static final java.lang.String STATUS_BAR_QUICK_QS_PULLDOWN = "qs_quick_pulldown";
field public static final java.lang.String STATUS_BAR_SHOW_BATTERY_PERCENT = "status_bar_show_battery_percent";
field public static final java.lang.String STYLUS_ICON_ENABLED = "stylus_icon_enabled";
field public static final java.lang.String SWAP_VOLUME_KEYS_ON_ROTATION = "swap_volume_keys_on_rotation";
field public static final java.lang.String SYSTEM_PROFILES_ENABLED = "system_profiles_enabled";
field public static final java.lang.String SYS_PROP_LINEAGE_SETTING_VERSION = "sys.lineage_settings_system_version";
field public static final java.lang.String T9_SEARCH_INPUT_LOCALE = "t9_search_input_locale";
field public static final java.lang.String TORCH_LONG_PRESS_POWER_GESTURE = "torch_long_press_power_gesture";
field public static final java.lang.String TORCH_LONG_PRESS_POWER_TIMEOUT = "torch_long_press_power_timeout";
field public static final java.lang.String TOUCHSCREEN_GESTURE_HAPTIC_FEEDBACK = "touchscreen_gesture_haptic_feedback";
field public static final java.lang.String USE_EDGE_SERVICE_FOR_GESTURES = "edge_service_for_gestures";
field public static final java.lang.String VOLBTN_MUSIC_CONTROLS = "volbtn_music_controls";
field public static final java.lang.String VOLUME_ADJUST_SOUNDS_ENABLED = "volume_adjust_sounds_enabled";
field public static final java.lang.String VOLUME_ANSWER_CALL = "volume_answer_call";
field public static final java.lang.String VOLUME_WAKE_SCREEN = "volume_wake_screen";
field public static final java.lang.String ZEN_ALLOW_LIGHTS = "allow_lights";
field public static final java.lang.String ZEN_PRIORITY_ALLOW_LIGHTS = "zen_priority_allow_lights";
}
}
package lineageos.trust {
public class TrustInterface {
method public static lineageos.trust.TrustInterface getInstance(android.content.Context);
method public int getLevelForFeature(int);
method public boolean postNotificationForFeature(int);
method public boolean removeNotificationForFeature(int);
field public static final int ERROR_UNDEFINED = -1; // 0xffffffff
field public static final int TRUST_FEATURE_ENCRYPTION = 4; // 0x4
field public static final int TRUST_FEATURE_KEYS = 5; // 0x5
field public static final int TRUST_FEATURE_LEVEL_BAD = 2; // 0x2
field public static final int TRUST_FEATURE_LEVEL_GOOD = 0; // 0x0
field public static final int TRUST_FEATURE_LEVEL_POOR = 1; // 0x1
field public static final int TRUST_FEATURE_PLATFORM_SECURITY_PATCH = 2; // 0x2
field public static final int TRUST_FEATURE_SELINUX = 0; // 0x0
field public static final int TRUST_FEATURE_VENDOR_SECURITY_PATCH = 3; // 0x3
field public static final java.lang.String TRUST_INTERFACE_PERMISSION = "lineageos.permission.TRUST_INTERFACE";
field public static final int TRUST_WARN_PUBLIC_KEY = 4; // 0x4
field public static final int TRUST_WARN_SELINUX = 1; // 0x1
}
}
package lineageos.util {
public class ColorUtils {
ctor public ColorUtils();
method public static double calculateDeltaE(double, double, double, double, double, double);
method public static float[] convertRGBtoLAB(int);
method public static int dropAlpha(int);
method public static int findPerceptuallyNearestColor(int, int[]);
method public static int findPerceptuallyNearestSolidColor(int);
method public static int generateAlertColorFromDrawable(android.graphics.drawable.Drawable);
method public static lineageos.util.palette.Palette.Swatch getDominantSwatch(lineageos.util.palette.Palette);
method public static float[] temperatureToRGB(int);
}
}

View File

@@ -1,7 +0,0 @@
.gradle
/local.properties
/.idea/workspace.xml
/.idea/libraries
.DS_Store
/build
/captures

View File

@@ -1,19 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<module external.linked.project.id="MyApplication" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$" external.system.id="GRADLE" external.system.module.group="" external.system.module.version="unspecified" type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="java-gradle" name="Java-Gradle">
<configuration>
<option name="BUILD_FOLDER_PATH" value="$MODULE_DIR$/build" />
<option name="BUILDABLE" value="false" />
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_7" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<excludeFolder url="file://$MODULE_DIR$/.gradle" />
</content>
<orderEntry type="inheritedJdk" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
</module>

View File

@@ -1 +0,0 @@
/build

View File

@@ -1,98 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<module external.linked.project.id=":app" external.linked.project.path="$MODULE_DIR$" external.root.project.path="$MODULE_DIR$/.." external.system.id="GRADLE" external.system.module.group="MyApplication" external.system.module.version="unspecified" type="JAVA_MODULE" version="4">
<component name="FacetManager">
<facet type="android-gradle" name="Android-Gradle">
<configuration>
<option name="GRADLE_PROJECT_PATH" value=":app" />
</configuration>
</facet>
<facet type="android" name="Android">
<configuration>
<option name="SELECTED_BUILD_VARIANT" value="debug" />
<option name="SELECTED_TEST_ARTIFACT" value="_android_test_" />
<option name="ASSEMBLE_TASK_NAME" value="assembleDebug" />
<option name="COMPILE_JAVA_TASK_NAME" value="compileDebugSources" />
<option name="ASSEMBLE_TEST_TASK_NAME" value="assembleDebugAndroidTest" />
<option name="COMPILE_JAVA_TEST_TASK_NAME" value="compileDebugAndroidTestSources" />
<afterSyncTasks>
<task>generateDebugAndroidTestSources</task>
<task>generateDebugSources</task>
</afterSyncTasks>
<option name="ALLOW_USER_CONFIGURATION" value="false" />
<option name="MANIFEST_FILE_RELATIVE_PATH" value="/src/main/AndroidManifest.xml" />
<option name="RES_FOLDER_RELATIVE_PATH" value="/src/main/res" />
<option name="RES_FOLDERS_RELATIVE_PATH" value="file://$MODULE_DIR$/src/main/res" />
<option name="ASSETS_FOLDER_RELATIVE_PATH" value="/src/main/assets" />
</configuration>
</facet>
</component>
<component name="NewModuleRootManager" LANGUAGE_LEVEL="JDK_1_7" inherit-compiler-output="false">
<output url="file://$MODULE_DIR$/build/intermediates/classes/debug" />
<output-test url="file://$MODULE_DIR$/build/intermediates/classes/androidTest/debug" />
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/debug" isTestSource="false" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/debug" isTestSource="false" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/debug" isTestSource="false" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/debug" isTestSource="false" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/debug" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/generated/debug" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/r/androidTest/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/aidl/androidTest/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/buildConfig/androidTest/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/source/rs/androidTest/debug" isTestSource="true" generated="true" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/rs/androidTest/debug" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/build/generated/res/generated/androidTest/debug" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/debug/res" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/debug/resources" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/debug/assets" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/debug/aidl" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/debug/java" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/debug/jni" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/debug/rs" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/res" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/main/resources" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/main/assets" type="java-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/main/aidl" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/java" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/jni" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/main/rs" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/res" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/resources" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/assets" type="java-test-resource" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/aidl" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/java" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/jni" isTestSource="true" />
<sourceFolder url="file://$MODULE_DIR$/src/androidTest/rs" isTestSource="true" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/assets" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/bundles" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/classes" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/coverage-instrumented-classes" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dependency-cache" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dex" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/dex-cache" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/appcompat-v7/22.2.1/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/exploded-aar/com.android.support/support-v4/22.2.1/jars" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/incremental" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/jacoco" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/javaResources" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/libs" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/lint" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/manifests" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/ndk" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/pre-dexed" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/proguard" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/res" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/rs" />
<excludeFolder url="file://$MODULE_DIR$/build/intermediates/symbols" />
<excludeFolder url="file://$MODULE_DIR$/build/outputs" />
<excludeFolder url="file://$MODULE_DIR$/build/tmp" />
</content>
<orderEntry type="jdk" jdkName="Android API 22 Platform" jdkType="Android SDK" />
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" exported="" name="platform.sdk-2.0-SNAPSHOT" level="project" />
<orderEntry type="library" exported="" name="support-v4-22.2.1" level="project" />
<orderEntry type="library" exported="" name="support-annotations-22.2.1" level="project" />
<orderEntry type="library" exported="" name="appcompat-v7-22.2.1" level="project" />
</component>
</module>

View File

@@ -1,29 +0,0 @@
apply plugin: 'com.android.application'
android {
compileSdkVersion 22
buildToolsVersion "19.1.0"
defaultConfig {
applicationId "com.example.test.myapplication"
minSdkVersion 15
targetSdkVersion 22
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.android.support:appcompat-v7:22.+'
}
dependencies {
compile 'org.lineageos:platform.sdk:2.0-SNAPSHOT'
}

View File

@@ -1,17 +0,0 @@
# Add project specific ProGuard rules here.
# By default, the flags in this file are appended to flags specified
# in /usr/local/var/lib/android-sdk/tools/proguard/proguard-android.txt
# You can edit the include path and order by changing the proguardFiles
# directive in build.gradle.
#
# For more details, see
# http://developer.android.com/guide/developing/tools/proguard.html
# Add any project specific keep options here:
# If your project uses WebView with JS, uncomment the following
# and specify the fully qualified class name to the JavaScript interface
# class:
#-keepclassmembers class fqcn.of.javascript.interface.for.webview {
# public *;
#}

View File

@@ -1,13 +0,0 @@
package com.example.test.myapplication;
import android.app.Application;
import android.test.ApplicationTestCase;
/**
* <a href="http://d.android.com/tools/testing/testing_android.html">Testing Fundamentals</a>
*/
public class ApplicationTest extends ApplicationTestCase<Application> {
public ApplicationTest() {
super(Application.class);
}
}

View File

@@ -1,33 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="com.example.test.myapplication" >
<uses-permission android:name="android.permission.CALL_PHONE" />
<uses-permission android:name="lineageos.permission.PUBLISH_CUSTOM_TILE" />
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="lineageos.permission.MODIFY_PROFILES" />
<application
android:allowBackup="true"
android:icon="@mipmap/ic_launcher"
android:label="@string/app_name"
android:theme="@style/AppTheme" >
<activity
android:name=".MainActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" />
<category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<receiver android:name=".DeleteIntentReceiver"
android:enabled="true"
android:exported="true">
<intent-filter>
<action android:name="com.example.test.myapplication.ACTION_DELETED"/>
</intent-filter>
</receiver>
</application>
</manifest>

View File

@@ -1,21 +0,0 @@
package com.example.test.myapplication;
import android.content.BroadcastReceiver;
import android.content.Context;
import android.content.Intent;
import android.widget.Toast;
/**
* Created by test on 8/7/15.
*/
public class DeleteIntentReceiver extends BroadcastReceiver {
public static final String DELETE_ACTION = "com.example.test.myapplication.ACTION_DELETED";
@Override
public void onReceive(Context context, Intent intent) {
if (DELETE_ACTION.equals(intent.getAction())) {
Toast.makeText(context, "WE WERE DELETED", Toast.LENGTH_SHORT).show();
}
}
}

View File

@@ -1,189 +0,0 @@
package com.example.test.myapplication;
import android.app.PendingIntent;
import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.net.wifi.WifiConfiguration;
import android.net.wifi.WifiManager;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.Button;
import android.widget.RemoteViews;
import android.widget.Toast;
import androidx.appcompat.app.AppCompatActivity;
import java.util.ArrayList;
import java.util.List;
import lineageos.app.LineageStatusBarManager;
import lineageos.app.CustomTile;
import lineageos.app.Profile;
import lineageos.app.ProfileManager;
import lineageos.profiles.ConnectionSettings;
public class MainActivity extends AppCompatActivity implements View.OnClickListener {
private LineageStatusBarManager mLineageStatusBarManager;
private Button mPublishRemoteViewButton;
private ProfileManager mProfileMangager;
private WifiManager mWifiManager;
private Profile mProfile;
private List<WifiTrigger> mTriggers = new ArrayList<WifiTrigger>();
private Button mProfileButton;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.activity_main);
// CUSTOM TILES
mLineageStatusBarManager = LineageStatusBarManager.getInstance(this);
mPublishRemoteViewButton = (Button) findViewById(R.id.publish_remote_view_tile);
mPublishRemoteViewButton.setOnClickListener(this);
// PROFILES
mProfileButton = (Button) findViewById(R.id.publish_ap_triggered_profile);
mProfileButton.setOnClickListener(this);
mProfileManager = ProfileManager.getInstance(this);
mWifiManager = (WifiManager) getSystemService(Context.WIFI_SERVICE);
populateWifiTriggerList();
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
// Inflate the menu; this adds items to the action bar if it is present.
getMenuInflater().inflate(R.menu.menu_main, menu);
return true;
}
@Override
public boolean onOptionsItemSelected(MenuItem item) {
// Handle action bar item clicks here. The action bar will
// automatically handle clicks on the Home/Up button, so long
// as you specify a parent activity in AndroidManifest.xml.
int id = item.getItemId();
//noinspection SimplifiableIfStatement
if (id == R.id.action_settings) {
return true;
}
return super.onOptionsItemSelected(item);
}
@Override
public void onClick(View v) {
switch (v.getId()) {
case R.id.publish_remote_view_tile:
Intent intent = new Intent(Intent.ACTION_DIAL);
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
intent.setData(Uri.parse("tel:2813308004"));
PendingIntent pendingIntent = PendingIntent.getActivity(this, 0, intent,
PendingIntent.FLAG_IMMUTABLE);
RemoteViews remoteViews = new RemoteViews(getPackageName(), R.layout.tile_remote_view);
remoteViews.setOnClickPendingIntent(R.id.remote_view_button, pendingIntent);
CustomTile.RemoteExpandedStyle remoteExpandedStyle = new CustomTile.RemoteExpandedStyle();
remoteExpandedStyle.setRemoteViews(remoteViews);
Intent deleteIntent = new Intent();
deleteIntent.setAction(DeleteIntentReceiver.DELETE_ACTION);
CustomTile customTile = new CustomTile.Builder(this)
.setDeleteIntent(PendingIntent.getBroadcast(this, 0, deleteIntent, 0))
.setLabel("Remote Tile")
.setIcon(R.mipmap.ic_launcher)
.setContentDescription("Remote Expanded Style Tile")
.setExpandedStyle(remoteExpandedStyle)
.build();
mLineageStatusBarManager.publishTile(1337, customTile);
break;
case R.id.publish_ap_triggered_profile:
mProfile = new Profile("Enable Bluetooth on WiFi connect");
mProfile.setProfileType(Profile.Type.TOGGLE);
final String triggerId;
final String triggerName;
final int triggerType;
final int triggerState;
WifiTrigger trigger = mTriggers.get(0); // get first AP, doesn't matter what it is
// Populate the arguments for the ProfileTrigger
triggerId = trigger.getSSID();
triggerName = trigger.getTitle();
triggerType = Profile.TriggerType.WIFI; // This is a wifi trigger
triggerState = Profile.TriggerState.ON_CONNECT; // On Connect of this, trigger
Profile.ProfileTrigger profileTrigger =
new Profile.ProfileTrigger(triggerType, triggerId, triggerState, triggerName);
ConnectionSettings connectionSettings = new ConnectionSettings(
ConnectionSettings.PROFILE_CONNECTION_BLUETOOTH,
ConnectionSettings.BooleanState.STATE_ENABLED, true);
mProfile.setConnectionSettings(connectionSettings);
mProfile.setTrigger(profileTrigger);
mProfileManager.addProfile(mProfile);
mProfileManager.setActiveProfile(mProfile.getUuid());
Toast.makeText(this, "Set up for AP " + triggerId + "\n" +
"With state pending on " + triggerState, Toast.LENGTH_SHORT).show();
break;
}
}
private void populateWifiTriggerList() {
final List<WifiConfiguration> configs = mWifiManager.getConfiguredNetworks();
if (configs != null) {
for (WifiConfiguration config : configs) {
WifiTrigger wifiTrigger = new WifiTrigger(config);
mTriggers.add(wifiTrigger);
}
}
}
public static class WifiTrigger {
public String mSSID;
public WifiConfiguration mConfig;
public WifiTrigger(WifiConfiguration config) {
mConfig = config;
loadConfig(config);
}
public String getSSID() {
return mSSID;
}
public String getTitle() {
return mSSID;
}
private void loadConfig(WifiConfiguration config) {
mSSID = (config.SSID == null ? "" : removeDoubleQuotes(config.SSID));
mConfig = config;
}
public static String removeDoubleQuotes(String string) {
final int length = string.length();
if (length >= 2) {
if (string.startsWith("\"") && string.endsWith("\"")) {
return string.substring(1, length - 1);
}
}
return string;
}
}
}

View File

@@ -1,22 +0,0 @@
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools" android:layout_width="match_parent"
android:layout_height="match_parent" android:paddingLeft="@dimen/activity_horizontal_margin"
android:paddingRight="@dimen/activity_horizontal_margin"
android:paddingTop="@dimen/activity_vertical_margin"
android:paddingBottom="@dimen/activity_vertical_margin"
android:orientation="vertical"
tools:context=".MainActivity">
<Button
android:text="Publish Remote View Tile"
android:id="@+id/publish_remote_view_tile"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<Button
android:text="Publish AP Triggered Profile"
android:id="@+id/publish_ap_triggered_profile"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</LinearLayout>

View File

@@ -1,23 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical" android:layout_width="match_parent"
android:layout_height="match_parent">
<LinearLayout
android:orientation="vertical"
android:layout_width="wrap_content"
android:layout_height="wrap_content">
<ImageView
android:src="@android:drawable/ic_menu_sort_alphabetically"
android:layout_width="48dp"
android:layout_height="48dp" />
<Button
android:id="@+id/remote_view_button"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="Click me"/>
</LinearLayout>
</LinearLayout>

View File

@@ -1,6 +0,0 @@
<menu xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools" tools:context=".MainActivity">
<item android:id="@+id/action_settings" android:title="@string/action_settings"
android:orderInCategory="100" app:showAsAction="never" />
</menu>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.5 KiB

View File

@@ -1,6 +0,0 @@
<resources>
<!-- Example customization of dimensions originally defined in res/values/dimens.xml
(such as screen margins) for screens with more than 820dp of available width. This
would include 7" and 10" devices in landscape (~960dp and ~1280dp respectively). -->
<dimen name="activity_horizontal_margin">64dp</dimen>
</resources>

View File

@@ -1,5 +0,0 @@
<resources>
<!-- Default screen margins, per the Android Design guidelines. -->
<dimen name="activity_horizontal_margin">16dp</dimen>
<dimen name="activity_vertical_margin">16dp</dimen>
</resources>

View File

@@ -1,6 +0,0 @@
<resources>
<string name="app_name">My Application</string>
<string name="hello_world">Hello world!</string>
<string name="action_settings">Settings</string>
</resources>

View File

@@ -1,8 +0,0 @@
<resources>
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<!-- Customize your theme here. -->
</style>
</resources>

View File

@@ -1,23 +0,0 @@
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:1.2.3'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
allprojects {
repositories {
mavenCentral()
jcenter()
maven {
url "https://oss.sonatype.org/content/repositories/snapshots/"
}
}
}

View File

@@ -1,18 +0,0 @@
# Project-wide Gradle settings.
# IDE (e.g. Android Studio) users:
# Gradle settings configured through the IDE *will override*
# any settings specified in this file.
# For more details on how to configure your build environment visit
# http://www.gradle.org/docs/current/userguide/build_environment.html
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
# Default value: -Xmx10248m -XX:MaxPermSize=256m
# org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8
# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects
# org.gradle.parallel=true

View File

@@ -1,6 +0,0 @@
#Thu Aug 06 21:22:49 PDT 2015
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-2.4-all.zip

View File

@@ -1,164 +0,0 @@
#!/usr/bin/env bash
##############################################################################
##
## Gradle start up script for UN*X
##
##############################################################################
# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
DEFAULT_JVM_OPTS=""
APP_NAME="Gradle"
APP_BASE_NAME=`basename "$0"`
# Use the maximum available, or set MAX_FD != -1 to use that value.
MAX_FD="maximum"
warn ( ) {
echo "$*"
}
die ( ) {
echo
echo "$*"
echo
exit 1
}
# OS specific support (must be 'true' or 'false').
cygwin=false
msys=false
darwin=false
case "`uname`" in
CYGWIN* )
cygwin=true
;;
Darwin* )
darwin=true
;;
MINGW* )
msys=true
;;
esac
# For Cygwin, ensure paths are in UNIX format before anything is touched.
if $cygwin ; then
[ -n "$JAVA_HOME" ] && JAVA_HOME=`cygpath --unix "$JAVA_HOME"`
fi
# Attempt to set APP_HOME
# Resolve links: $0 may be a link
PRG="$0"
# Need this for relative symlinks.
while [ -h "$PRG" ] ; do
ls=`ls -ld "$PRG"`
link=`expr "$ls" : '.*-> \(.*\)$'`
if expr "$link" : '/.*' > /dev/null; then
PRG="$link"
else
PRG=`dirname "$PRG"`"/$link"
fi
done
SAVED="`pwd`"
cd "`dirname \"$PRG\"`/" >&-
APP_HOME="`pwd -P`"
cd "$SAVED" >&-
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
if [ -n "$JAVA_HOME" ] ; then
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
# IBM's JDK on AIX uses strange locations for the executables
JAVACMD="$JAVA_HOME/jre/sh/java"
else
JAVACMD="$JAVA_HOME/bin/java"
fi
if [ ! -x "$JAVACMD" ] ; then
die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
else
JAVACMD="java"
which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
Please set the JAVA_HOME variable in your environment to match the
location of your Java installation."
fi
# Increase the maximum file descriptors if we can.
if [ "$cygwin" = "false" -a "$darwin" = "false" ] ; then
MAX_FD_LIMIT=`ulimit -H -n`
if [ $? -eq 0 ] ; then
if [ "$MAX_FD" = "maximum" -o "$MAX_FD" = "max" ] ; then
MAX_FD="$MAX_FD_LIMIT"
fi
ulimit -n $MAX_FD
if [ $? -ne 0 ] ; then
warn "Could not set maximum file descriptor limit: $MAX_FD"
fi
else
warn "Could not query maximum file descriptor limit: $MAX_FD_LIMIT"
fi
fi
# For Darwin, add options to specify how the application appears in the dock
if $darwin; then
GRADLE_OPTS="$GRADLE_OPTS \"-Xdock:name=$APP_NAME\" \"-Xdock:icon=$APP_HOME/media/gradle.icns\""
fi
# For Cygwin, switch paths to Windows format before running java
if $cygwin ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
# We build the pattern for arguments to be converted via cygpath
ROOTDIRSRAW=`find -L / -maxdepth 1 -mindepth 1 -type d 2>/dev/null`
SEP=""
for dir in $ROOTDIRSRAW ; do
ROOTDIRS="$ROOTDIRS$SEP$dir"
SEP="|"
done
OURCYGPATTERN="(^($ROOTDIRS))"
# Add a user-defined pattern to the cygpath arguments
if [ "$GRADLE_CYGPATTERN" != "" ] ; then
OURCYGPATTERN="$OURCYGPATTERN|($GRADLE_CYGPATTERN)"
fi
# Now convert the arguments - kludge to limit ourselves to /bin/sh
i=0
for arg in "$@" ; do
CHECK=`echo "$arg"|egrep -c "$OURCYGPATTERN" -`
CHECK2=`echo "$arg"|egrep -c "^-"` ### Determine if an option
if [ $CHECK -ne 0 ] && [ $CHECK2 -eq 0 ] ; then ### Added a condition
eval `echo args$i`=`cygpath --path --ignore --mixed "$arg"`
else
eval `echo args$i`="\"$arg\""
fi
i=$((i+1))
done
case $i in
(0) set -- ;;
(1) set -- "$args0" ;;
(2) set -- "$args0" "$args1" ;;
(3) set -- "$args0" "$args1" "$args2" ;;
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
esac
fi
# Split up the JVM_OPTS And GRADLE_OPTS values into an array, following the shell quoting and substitution rules
function splitJvmOpts() {
JVM_OPTS=("$@")
}
eval splitJvmOpts $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS
JVM_OPTS[${#JVM_OPTS[*]}]="-Dorg.gradle.appname=$APP_BASE_NAME"
exec "$JAVACMD" "${JVM_OPTS[@]}" -classpath "$CLASSPATH" org.gradle.wrapper.GradleWrapperMain "$@"

View File

@@ -1,90 +0,0 @@
@if "%DEBUG%" == "" @echo off
@rem ##########################################################################
@rem
@rem Gradle startup script for Windows
@rem
@rem ##########################################################################
@rem Set local scope for the variables with windows NT shell
if "%OS%"=="Windows_NT" setlocal
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS=
set DIRNAME=%~dp0
if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
@rem Find java.exe
if defined JAVA_HOME goto findJavaFromJavaHome
set JAVA_EXE=java.exe
%JAVA_EXE% -version >NUL 2>&1
if "%ERRORLEVEL%" == "0" goto init
echo.
echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH.
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:findJavaFromJavaHome
set JAVA_HOME=%JAVA_HOME:"=%
set JAVA_EXE=%JAVA_HOME%/bin/java.exe
if exist "%JAVA_EXE%" goto init
echo.
echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME%
echo.
echo Please set the JAVA_HOME variable in your environment to match the
echo location of your Java installation.
goto fail
:init
@rem Get command-line arguments, handling Windowz variants
if not "%OS%" == "Windows_NT" goto win9xME_args
if "%@eval[2+2]" == "4" goto 4NT_args
:win9xME_args
@rem Slurp the command line arguments.
set CMD_LINE_ARGS=
set _SKIP=2
:win9xME_args_slurp
if "x%~1" == "x" goto execute
set CMD_LINE_ARGS=%*
goto execute
:4NT_args
@rem Get arguments from the 4NT Shell from JP Software
set CMD_LINE_ARGS=%$
:execute
@rem Setup the command line
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%
:end
@rem End local scope for the variables with windows NT shell
if "%ERRORLEVEL%"=="0" goto mainEnd
:fail
rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of
rem the _cmd.exe /c_ return code!
if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1
exit /b 1
:mainEnd
if "%OS%"=="Windows_NT" endlocal
:omega

View File

@@ -1 +0,0 @@
include ':app'

View File

@@ -1,19 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.lineageos.samples.profiles"
android:versionCode="1"
android:versionName="1.0">
<uses-permission android:name="android.permission.ACCESS_WIFI_STATE" />
<uses-permission android:name="lineageos.permission.MODIFY_PROFILES" />
<application android:label="@string/app_name" android:icon="@drawable/ic_launcher">
<activity android:name="MainActivity"
android:label="@string/app_name">
<intent-filter>
<action android:name="android.intent.action.MAIN"/>
<category android:name="android.intent.category.LAUNCHER"/>
</intent-filter>
</activity>
</application>
</manifest>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

View File

@@ -1,19 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:gravity="center_horizontal"
>
<Button
android:id="@+id/create_bluetooth_on_wifi_trigger_connect"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/bluetooth_on_wifi_trigger"/>
<TextView
android:id="@+id/create_bt_on_wifi_status"
android:layout_width="match_parent"
android:layout_height="300dp" />
</LinearLayout>

View File

@@ -1,5 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<string name="app_name">Profiles Sample</string>
<string name="bluetooth_on_wifi_trigger">Create profile that triggers on top AP from WifiManager</string>
</resources>

View File

@@ -1,137 +0,0 @@
/*
* Copyright (C) 2015 The CyanogenMod Project
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.lineageos.samples.profiles;
import android.app.Activity;
import android.content.Context;
import android.net.wifi.WifiConfiguration;
import android.net.wifi.WifiManager;
import android.os.Bundle;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;
import lineageos.app.Profile;
import lineageos.app.ProfileManager;
import lineageos.profiles.ConnectionSettings;
import java.util.ArrayList;
import java.util.List;
/**
* Created by adnan on 8/4/15.
*/
public class MainActivity extends Activity implements View.OnClickListener {
private ProfileManager mProfileManager;
private WifiManager mWifiManager;
private Profile mProfile;
private List<WifiTrigger> mTriggers = new ArrayList<WifiTrigger>();
private Button mProfileButton;
private TextView mTextView;
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.main);
mProfileManager = ProfileManager.getInstance(this);
mWifiManager = (WifiManager) getSystemService(Context.WIFI_SERVICE);
populateWifiTriggerList();
mProfileButton = (Button) findViewById(R.id.create_bluetooth_on_wifi_trigger_connect);
mTextView = (TextView) findViewById(R.id.create_bt_on_wifi_status);
mProfileButton.setOnClickListener(this);
}
@Override
public void onClick(View view) {
mProfile = new Profile("Enable Bluetooth on WiFi connect");
mProfile.setProfileType(Profile.Type.TOGGLE);
final String triggerId;
final String triggerName;
final int triggerType;
final int triggerState;
WifiTrigger trigger = mTriggers.get(0); // get first AP, doesn't matter what it is
// Populate the arguments for the ProfileTrigger
triggerId = trigger.getSSID();
triggerName = trigger.getTitle();
triggerType = Profile.TriggerType.WIFI; // This is a wifi trigger
triggerState = Profile.TriggerState.ON_CONNECT; // On Connect of this, trigger
Profile.ProfileTrigger profileTrigger =
new Profile.ProfileTrigger(triggerType, triggerId, triggerState, triggerName);
ConnectionSettings connectionSettings = new ConnectionSettings(
ConnectionSettings.PROFILE_CONNECTION_BLUETOOTH,
ConnectionSettings.BooleanState.STATE_ENABLED, true);
mProfile.setConnectionSettings(connectionSettings);
mProfile.setTrigger(profileTrigger);
mProfileManager.addProfile(mProfile);
mTextView.setText("Set up for AP " + triggerId + "\n" +
"With state pending on " + triggerState);
}
private void populateWifiTriggerList() {
final List<WifiConfiguration> configs = mWifiManager.getConfiguredNetworks();
if (configs != null) {
for (WifiConfiguration config : configs) {
WifiTrigger wifiTrigger = new WifiTrigger(config);
mTriggers.add(wifiTrigger);
}
}
}
public static class WifiTrigger {
public String mSSID;
public WifiConfiguration mConfig;
public WifiTrigger(WifiConfiguration config) {
mConfig = config;
loadConfig(config);
}
public String getSSID() {
return mSSID;
}
public String getTitle() {
return mSSID;
}
private void loadConfig(WifiConfiguration config) {
mSSID = (config.SSID == null ? "" : removeDoubleQuotes(config.SSID));
mConfig = config;
}
public static String removeDoubleQuotes(String string) {
final int length = string.length();
if (length >= 2) {
if (string.startsWith("\"") && string.endsWith("\"")) {
return string.substring(1, length - 1);
}
}
return string;
}
}
}

View File

@@ -19,7 +19,7 @@ include $(CLEAR_VARS)
LOCAL_MODULE_TAGS := tests
LOCAL_STATIC_JAVA_LIBRARIES := \
org.lineageos.platform.sdk \
org.lineageos.platform.internal \
android-support-test \
mockito-target
@@ -41,7 +41,7 @@ include $(CLEAR_VARS)
LOCAL_MODULE_TAGS := tests
LOCAL_STATIC_JAVA_LIBRARIES := \
org.lineageos.platform.sdk \
org.lineageos.platform.internal \
android-support-test \
mockito-target