lineage-sdk: rebrand step 2: update file contents
Change-Id: I9881acc57cdc0aeea2b296aac12a8af932d30aea
This commit is contained in:
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.alarmclock;
|
||||
package lineageos.alarmclock;
|
||||
|
||||
import android.net.Uri;
|
||||
import android.provider.BaseColumns;
|
||||
@@ -37,9 +37,9 @@ import android.provider.BaseColumns;
|
||||
* </ul>
|
||||
*
|
||||
* <p>
|
||||
* Requires {@link cyanogenmod.alarmclock.CyanogenModAlarmClock#READ_ALARMS_PERMISSION}
|
||||
* Requires {@link lineageos.alarmclock.LineageOSAlarmClock#READ_ALARMS_PERMISSION}
|
||||
* to read from the provider.
|
||||
* Requires {@link cyanogenmod.alarmclock.CyanogenModAlarmClock#WRITE_ALARMS_PERMISSION} to write
|
||||
* Requires {@link lineageos.alarmclock.LineageOSAlarmClock#WRITE_ALARMS_PERMISSION} to write
|
||||
* to the provider.
|
||||
* </p>
|
||||
*/
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.alarmclock;
|
||||
package lineageos.alarmclock;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
@@ -26,13 +26,13 @@ import android.provider.AlarmClock;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* The CyanogenModAlarmClock class contains utilities for interacting with
|
||||
* a variety of Alarm features that the CyanogenMod AlarmClock application
|
||||
* The LineageOSAlarmClock class contains utilities for interacting with
|
||||
* a variety of Alarm features that the LineageOS AlarmClock application
|
||||
* (based on AOSP DeskClock) supports.
|
||||
*/
|
||||
public class CyanogenModAlarmClock {
|
||||
public class LineageOSAlarmClock {
|
||||
/**
|
||||
* The package name of the CyanogenMod DeskClock application.
|
||||
* The package name of the LineageOS DeskClock application.
|
||||
*/
|
||||
private static final String DESKCLOCK_PACKAGE = "com.android.deskclock";
|
||||
|
||||
@@ -43,26 +43,26 @@ public class CyanogenModAlarmClock {
|
||||
* @see #ACTION_SET_ALARM_ENABLED
|
||||
*/
|
||||
public static final String MODIFY_ALARMS_PERMISSION
|
||||
= "cyanogenmod.alarmclock.permission.MODIFY_ALARMS";
|
||||
= "lineageos.alarmclock.permission.MODIFY_ALARMS";
|
||||
|
||||
/**
|
||||
* Allows an application to have read access to all alarms in the
|
||||
* CyanogenMod DeskClock application.
|
||||
* LineageOS DeskClock application.
|
||||
*
|
||||
* @see cyanogenmod.alarmclock.ClockContract
|
||||
* @see lineageos.alarmclock.ClockContract
|
||||
*/
|
||||
public static final String READ_ALARMS_PERMISSION
|
||||
= "cyanogenmod.alarmclock.permission.READ_ALARMS";
|
||||
= "lineageos.alarmclock.permission.READ_ALARMS";
|
||||
|
||||
/**
|
||||
* Allows an application to have write access to all alarms in the
|
||||
* CyanogenMod DeskClock application. This is a system level permission.
|
||||
* LineageOS DeskClock application. This is a system level permission.
|
||||
*
|
||||
* @see cyanogenmod.alarmclock.ClockContract
|
||||
* @see lineageos.alarmclock.ClockContract
|
||||
* @hide
|
||||
*/
|
||||
public static final String WRITE_ALARMS_PERMISSION
|
||||
= "cyanogenmod.alarmclock.permission.WRITE_ALARMS";
|
||||
= "lineageos.alarmclock.permission.WRITE_ALARMS";
|
||||
|
||||
/**
|
||||
* Service Action: Set an existing alarm to be either enabled or disabled.
|
||||
@@ -83,13 +83,13 @@ public class CyanogenModAlarmClock {
|
||||
* <h3>Request parameters</h3>
|
||||
* <ul>
|
||||
* <li>{@link #EXTRA_ALARM_ID} <em>(required)</em>: The id of the alarm to modify,
|
||||
* as stored in {@link cyanogenmod.alarmclock.ClockContract.AlarmsColumns#_ID}</li>
|
||||
* as stored in {@link lineageos.alarmclock.ClockContract.AlarmsColumns#_ID}</li>
|
||||
* <li>{@link #EXTRA_ENABLED} <em>(required)</em>: Whether to set this alarm to be enabled
|
||||
* or disabled. </li>
|
||||
* </ul>
|
||||
*/
|
||||
public static final String ACTION_SET_ALARM_ENABLED
|
||||
= "cyanogenmod.alarmclock.SET_ALARM_ENABLED";
|
||||
= "lineageos.alarmclock.SET_ALARM_ENABLED";
|
||||
|
||||
/**
|
||||
* Bundle extra: The id of the alarm.
|
||||
@@ -99,13 +99,13 @@ public class CyanogenModAlarmClock {
|
||||
* This extra is required.
|
||||
* </p><p>
|
||||
* The value is an {@link Long} and is the ID stored in
|
||||
* {@link cyanogenmod.alarmclock.ClockContract.AlarmsColumns#_ID} for this alarm.
|
||||
* {@link lineageos.alarmclock.ClockContract.AlarmsColumns#_ID} for this alarm.
|
||||
* </p>
|
||||
*
|
||||
* @see #ACTION_SET_ALARM_ENABLED
|
||||
* @see #EXTRA_ENABLED
|
||||
*/
|
||||
public static final String EXTRA_ALARM_ID = "cyanogenmod.intent.extra.alarmclock.ID";
|
||||
public static final String EXTRA_ALARM_ID = "lineageos.intent.extra.alarmclock.ID";
|
||||
|
||||
/**
|
||||
* Bundle extra: Whether to set the alarm to enabled to disabled.
|
||||
@@ -121,12 +121,12 @@ public class CyanogenModAlarmClock {
|
||||
* @see #ACTION_SET_ALARM_ENABLED
|
||||
* @see #EXTRA_ALARM_ID
|
||||
*/
|
||||
public static final String EXTRA_ENABLED = "cyanogenmod.intent.extra.alarmclock.ENABLED";
|
||||
public static final String EXTRA_ENABLED = "lineageos.intent.extra.alarmclock.ENABLED";
|
||||
|
||||
/**
|
||||
* <p>
|
||||
* Retrieves an Intent that is prepopulated with the proper action and ComponentName to
|
||||
* create a new alarm in the CyanogenMod DeskClock application.
|
||||
* create a new alarm in the LineageOS DeskClock application.
|
||||
* </p>
|
||||
* <p> The action will be set to {@link android.provider.AlarmClock#ACTION_SET_ALARM}. Use the
|
||||
* Intent extras contained at {@link android.provider.AlarmClock} to configure the alarm.
|
||||
@@ -136,7 +136,7 @@ public class CyanogenModAlarmClock {
|
||||
* </p>
|
||||
*
|
||||
* @see android.provider.AlarmClock#ACTION_SET_ALARM
|
||||
* @return The Intent to create a new alarm with the CyanogenMod DeskClock application.
|
||||
* @return The Intent to create a new alarm with the LineageOS DeskClock application.
|
||||
*/
|
||||
public static Intent createAlarmIntent(Context context) {
|
||||
Intent intent = new Intent();
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.annotation.NonNull;
|
||||
import android.app.AppGlobals;
|
||||
@@ -29,7 +29,7 @@ import android.os.RemoteException;
|
||||
import android.os.UserHandle;
|
||||
import android.util.Log;
|
||||
|
||||
import cyanogenmod.platform.Manifest;
|
||||
import lineageos.platform.Manifest;
|
||||
|
||||
/**
|
||||
* Base Live lock screen manager service to be extended by applications that implement the
|
||||
@@ -107,7 +107,7 @@ abstract public class BaseLiveLockManagerService extends Service
|
||||
|
||||
/**
|
||||
* Returns true if the caller has been granted the
|
||||
* {@link cyanogenmod.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS_PRIVATE}
|
||||
* {@link lineageos.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS_PRIVATE}
|
||||
* permission.
|
||||
*
|
||||
* @return
|
||||
@@ -118,7 +118,7 @@ abstract public class BaseLiveLockManagerService extends Service
|
||||
}
|
||||
|
||||
/**
|
||||
* Enforces the {@link cyanogenmod.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS}
|
||||
* Enforces the {@link lineageos.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS}
|
||||
* permission.
|
||||
*/
|
||||
protected final void enforceAccessPermission() {
|
||||
@@ -130,7 +130,7 @@ abstract public class BaseLiveLockManagerService extends Service
|
||||
|
||||
/**
|
||||
* Enforces the
|
||||
* {@link cyanogenmod.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS_PRIVATE}
|
||||
* {@link lineageos.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS_PRIVATE}
|
||||
* permission.
|
||||
*/
|
||||
protected final void enforcePrivateAccessPermission() {
|
||||
@@ -141,7 +141,7 @@ abstract public class BaseLiveLockManagerService extends Service
|
||||
/**
|
||||
* Enforces the LLS being shown/canceled is from the calling package or from a system app that
|
||||
* has the
|
||||
* {@link cyanogenmod.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS_PRIVATE}
|
||||
* {@link lineageos.platform.Manifest.permission#LIVE_LOCK_SCREEN_MANAGER_ACCESS_PRIVATE}
|
||||
* permission.
|
||||
*
|
||||
* @param pkg Package name of caller
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
parcelable CustomTile;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.app.PendingIntent;
|
||||
import android.content.Context;
|
||||
@@ -26,17 +26,17 @@ import android.os.Parcelable;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.widget.RemoteViews;
|
||||
import cyanogenmod.os.Build;
|
||||
import lineageos.os.Build;
|
||||
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
/**
|
||||
* A class that represents a quick settings tile
|
||||
*
|
||||
* <p>The {@link cyanogenmod.app.CustomTile.Builder} has been added to make it
|
||||
* <p>The {@link lineageos.app.CustomTile.Builder} has been added to make it
|
||||
* easier to construct CustomTiles.</p>
|
||||
*/
|
||||
public class CustomTile implements Parcelable {
|
||||
@@ -138,7 +138,7 @@ public class CustomTile implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.APRICOT) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.APRICOT) {
|
||||
if (parcel.readInt() != 0) {
|
||||
this.onClick = PendingIntent.CREATOR.createFromParcel(parcel);
|
||||
}
|
||||
@@ -160,7 +160,7 @@ public class CustomTile implements Parcelable {
|
||||
this.icon = parcel.readInt();
|
||||
}
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
this.resourcesPackageName = parcel.readString();
|
||||
this.collapsePanel = (parcel.readInt() == 1);
|
||||
if (parcel.readInt() != 0) {
|
||||
@@ -172,7 +172,7 @@ public class CustomTile implements Parcelable {
|
||||
this.sensitiveData = (parcel.readInt() == 1);
|
||||
}
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.DRAGON_FRUIT) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.DRAGON_FRUIT) {
|
||||
if (parcel.readInt() != 0) {
|
||||
this.onLongClick = PendingIntent.CREATOR.createFromParcel(parcel);
|
||||
}
|
||||
@@ -184,7 +184,7 @@ public class CustomTile implements Parcelable {
|
||||
|
||||
/**
|
||||
* Constructs a CustomTile object with default values.
|
||||
* You might want to consider using {@link cyanogenmod.app.CustomTile.Builder} instead.
|
||||
* You might want to consider using {@link lineageos.app.CustomTile.Builder} instead.
|
||||
*/
|
||||
public CustomTile()
|
||||
{
|
||||
@@ -381,14 +381,14 @@ public class CustomTile implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.APRICOT) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.APRICOT) {
|
||||
if (parcel.readInt() != 0) {
|
||||
expandedItems = parcel.createTypedArray(ExpandedItem.CREATOR);
|
||||
}
|
||||
styleId = parcel.readInt();
|
||||
}
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcel.readInt() != 0) {
|
||||
contentViews = RemoteViews.CREATOR.createFromParcel(parcel);
|
||||
}
|
||||
@@ -667,7 +667,7 @@ public class CustomTile implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.APRICOT) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.APRICOT) {
|
||||
if (parcel.readInt() != 0) {
|
||||
onClickPendingIntent = PendingIntent.CREATOR.createFromParcel(parcel);
|
||||
}
|
||||
@@ -680,7 +680,7 @@ public class CustomTile implements Parcelable {
|
||||
itemDrawableResourceId = parcel.readInt();
|
||||
}
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcel.readInt() != 0) {
|
||||
itemBitmapResource = Bitmap.CREATOR.createFromParcel(parcel);
|
||||
}
|
||||
@@ -885,9 +885,9 @@ public class CustomTile implements Parcelable {
|
||||
};
|
||||
|
||||
/**
|
||||
* Builder class for {@link cyanogenmod.app.CustomTile} objects.
|
||||
* Builder class for {@link lineageos.app.CustomTile} objects.
|
||||
*
|
||||
* Provides a convenient way to set the various fields of a {@link cyanogenmod.app.CustomTile}
|
||||
* Provides a convenient way to set the various fields of a {@link lineageos.app.CustomTile}
|
||||
*
|
||||
* <p>Example:
|
||||
*
|
||||
@@ -927,7 +927,7 @@ public class CustomTile implements Parcelable {
|
||||
/**
|
||||
* Set the label for the custom tile
|
||||
* @param label a string to be used for the custom tile label
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setLabel(String label) {
|
||||
mLabel = label;
|
||||
@@ -937,7 +937,7 @@ public class CustomTile implements Parcelable {
|
||||
/**
|
||||
* Set the label for the custom tile
|
||||
* @param id a string resource id to be used for the custom tile label
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setLabel(int id) {
|
||||
mLabel = mContext.getString(id);
|
||||
@@ -947,7 +947,7 @@ public class CustomTile implements Parcelable {
|
||||
/**
|
||||
* Set the content description for the custom tile
|
||||
* @param contentDescription a string to explain content
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setContentDescription(String contentDescription) {
|
||||
mContentDescription = contentDescription;
|
||||
@@ -957,7 +957,7 @@ public class CustomTile implements Parcelable {
|
||||
/**
|
||||
* Set the content description for the custom tile
|
||||
* @param id a string resource id to explain content
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setContentDescription(int id) {
|
||||
mContentDescription = mContext.getString(id);
|
||||
@@ -967,7 +967,7 @@ public class CustomTile implements Parcelable {
|
||||
/**
|
||||
* Set a {@link android.app.PendingIntent} to be fired on custom tile click
|
||||
* @param intent
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setOnClickIntent(PendingIntent intent) {
|
||||
mOnClick = intent;
|
||||
@@ -978,7 +978,7 @@ public class CustomTile implements Parcelable {
|
||||
* Set a {@link android.app.PendingIntent} to be fired on custom tile long press.
|
||||
* Note: if this is an activity, the host panel will automatically collapse.
|
||||
* @param intent
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setOnLongClickIntent(PendingIntent intent) {
|
||||
mOnLongClick = intent;
|
||||
@@ -989,7 +989,7 @@ public class CustomTile implements Parcelable {
|
||||
* Set a settings {@link android.content.Intent} to be fired on custom
|
||||
* tile detail pane click
|
||||
* @param intent
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setOnSettingsClickIntent(Intent intent) {
|
||||
mOnSettingsClick = intent;
|
||||
@@ -999,7 +999,7 @@ public class CustomTile implements Parcelable {
|
||||
/**
|
||||
* Set a {@link android.net.Uri} to be broadcasted in an intent on custom tile click
|
||||
* @param uri
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setOnClickUri(Uri uri) {
|
||||
mOnClickUri = uri;
|
||||
@@ -1010,7 +1010,7 @@ public class CustomTile implements Parcelable {
|
||||
* Set an icon for the custom tile to be presented to the user
|
||||
*
|
||||
* @param drawableId
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setIcon(int drawableId) {
|
||||
mIcon = drawableId;
|
||||
@@ -1023,7 +1023,7 @@ public class CustomTile implements Parcelable {
|
||||
* This will unset {@link #setIcon(int)} if utilized together.
|
||||
* @see CustomTile#remoteIcon
|
||||
* @param remoteIcon
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setIcon(Bitmap remoteIcon) {
|
||||
mIcon = 0; // empty
|
||||
@@ -1034,7 +1034,7 @@ public class CustomTile implements Parcelable {
|
||||
/**
|
||||
* Set an {@link ExpandedStyle} to to be displayed when a user clicks the custom tile
|
||||
* @param expandedStyle
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setExpandedStyle(ExpandedStyle expandedStyle) {
|
||||
if (mExpandedStyle != expandedStyle) {
|
||||
@@ -1050,7 +1050,7 @@ public class CustomTile implements Parcelable {
|
||||
* Set whether or not the Statusbar Panel should be collapsed when an
|
||||
* {@link #onClick} or {@link #onClickUri} event is fired.
|
||||
* @param bool
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder shouldCollapsePanel(boolean bool) {
|
||||
mCollapsePanel = bool;
|
||||
@@ -1063,7 +1063,7 @@ public class CustomTile implements Parcelable {
|
||||
*
|
||||
* @see CustomTile#deleteIntent
|
||||
* @param intent
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder setDeleteIntent(PendingIntent intent) {
|
||||
mDeleteIntent = intent;
|
||||
@@ -1074,7 +1074,7 @@ public class CustomTile implements Parcelable {
|
||||
* Indicates whether this tile has sensitive data that have to be hidden
|
||||
* on secure lockscreens.
|
||||
* @param bool
|
||||
* @return {@link cyanogenmod.app.CustomTile.Builder}
|
||||
* @return {@link lineageos.app.CustomTile.Builder}
|
||||
*/
|
||||
public Builder hasSensitiveData(boolean bool) {
|
||||
mSensitiveData = bool;
|
||||
@@ -1082,8 +1082,8 @@ public class CustomTile implements Parcelable {
|
||||
}
|
||||
|
||||
/**
|
||||
* Create a {@link cyanogenmod.app.CustomTile} object
|
||||
* @return {@link cyanogenmod.app.CustomTile}
|
||||
* Create a {@link lineageos.app.CustomTile} object
|
||||
* @return {@link lineageos.app.CustomTile}
|
||||
*/
|
||||
public CustomTile build() {
|
||||
CustomTile tile = new CustomTile();
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.annotation.SdkConstant;
|
||||
import android.app.Service;
|
||||
@@ -26,22 +26,22 @@ import android.os.RemoteException;
|
||||
import android.os.ServiceManager;
|
||||
import android.util.Log;
|
||||
|
||||
import cyanogenmod.app.ICustomTileListener;
|
||||
import cyanogenmod.app.IStatusBarCustomTileHolder;
|
||||
import cyanogenmod.app.ICMStatusBarManager;
|
||||
import lineageos.app.ICustomTileListener;
|
||||
import lineageos.app.IStatusBarCustomTileHolder;
|
||||
import lineageos.app.ILineageStatusBarManager;
|
||||
|
||||
/**
|
||||
* A service that receives calls from the system when new custom tiles are
|
||||
* posted or removed.
|
||||
* <p>To extend this class, you must declare the service in your manifest file with
|
||||
* the cyanogenmod.permission.BIND_CUSTOM_TILE_LISTENER_SERVICE
|
||||
* the lineageos.permission.BIND_CUSTOM_TILE_LISTENER_SERVICE
|
||||
* and include an intent filter with the {@link #SERVICE_INTERFACE} action. For example:</p>
|
||||
* <pre>
|
||||
* <service android:name=".CustomTileListener"
|
||||
* android:label="@string/service_name"
|
||||
* android:permission="cyanogenmod.permission.BIND_CUSTOM_TILE_LISTENER_SERVICE">
|
||||
* android:permission="lineageos.permission.BIND_CUSTOM_TILE_LISTENER_SERVICE">
|
||||
* <intent-filter>
|
||||
* <action android:name="cyanogenmod.app.CustomTileListenerService" />
|
||||
* <action android:name="lineageos.app.CustomTileListenerService" />
|
||||
* </intent-filter>
|
||||
* </service></pre>
|
||||
*/
|
||||
@@ -53,10 +53,10 @@ public class CustomTileListenerService extends Service {
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.SERVICE_ACTION)
|
||||
public static final String SERVICE_INTERFACE
|
||||
= "cyanogenmod.app.CustomTileListenerService";
|
||||
= "lineageos.app.CustomTileListenerService";
|
||||
|
||||
private ICustomTileListenerWrapper mWrapper = null;
|
||||
private ICMStatusBarManager mStatusBarService;
|
||||
private ILineageStatusBarManager mStatusBarService;
|
||||
/** Only valid after a successful call to (@link registerAsService}. */
|
||||
private int mCurrentUser;
|
||||
|
||||
@@ -68,10 +68,10 @@ public class CustomTileListenerService extends Service {
|
||||
return mWrapper;
|
||||
}
|
||||
|
||||
private final ICMStatusBarManager getStatusBarInterface() {
|
||||
private final ILineageStatusBarManager getStatusBarInterface() {
|
||||
if (mStatusBarService == null) {
|
||||
mStatusBarService = ICMStatusBarManager.Stub.asInterface(
|
||||
ServiceManager.getService(CMContextConstants.CM_STATUS_BAR_SERVICE));
|
||||
mStatusBarService = ILineageStatusBarManager.Stub.asInterface(
|
||||
ServiceManager.getService(LineageContextConstants.LINEAGE_STATUS_BAR_SERVICE));
|
||||
}
|
||||
return mStatusBarService;
|
||||
}
|
||||
@@ -93,7 +93,7 @@ public class CustomTileListenerService extends Service {
|
||||
if (isBound()) {
|
||||
return;
|
||||
}
|
||||
ICMStatusBarManager statusBarInterface = mStatusBarService;
|
||||
ILineageStatusBarManager statusBarInterface = mStatusBarService;
|
||||
if (mStatusBarService != null) {
|
||||
mWrapper = new ICustomTileListenerWrapper();
|
||||
statusBarInterface.registerListener(mWrapper, componentName, currentUser);
|
||||
@@ -110,7 +110,7 @@ public class CustomTileListenerService extends Service {
|
||||
*/
|
||||
public void unregisterAsSystemService() throws RemoteException {
|
||||
if (isBound()) {
|
||||
ICMStatusBarManager statusBarInterface = mStatusBarService;
|
||||
ILineageStatusBarManager statusBarInterface = mStatusBarService;
|
||||
statusBarInterface.unregisterListener(mWrapper, mCurrentUser);
|
||||
mWrapper = null;
|
||||
mStatusBarService = null;
|
||||
@@ -168,7 +168,7 @@ public class CustomTileListenerService extends Service {
|
||||
/**
|
||||
* Implement this method to learn about new custom tiles as they are posted by apps.
|
||||
*
|
||||
* @param sbc A data structure encapsulating the original {@link cyanogenmod.app.CustomTile}
|
||||
* @param sbc A data structure encapsulating the original {@link lineageos.app.CustomTile}
|
||||
* object as well as its identifying information (tag and id) and source
|
||||
* (package name).
|
||||
*/
|
||||
@@ -180,7 +180,7 @@ public class CustomTileListenerService extends Service {
|
||||
* Implement this method to learn when custom tiles are removed.
|
||||
*
|
||||
* @param sbc A data structure encapsulating at least the original information (tag and id)
|
||||
* and source (package name) used to post the {@link cyanogenmod.app.CustomTile} that
|
||||
* and source (package name) used to post the {@link lineageos.app.CustomTile} that
|
||||
* was just removed.
|
||||
*/
|
||||
public void onCustomTileRemoved(StatusBarPanelCustomTile sbc) {
|
||||
@@ -197,12 +197,12 @@ public class CustomTileListenerService extends Service {
|
||||
}
|
||||
|
||||
/**
|
||||
* Inform the {@link cyanogenmod.app.CMStatusBarManager} about dismissal of a single custom tile.
|
||||
* Inform the {@link lineageos.app.LineageStatusBarManager} about dismissal of a single custom tile.
|
||||
* <p>
|
||||
* Use this if your listener has a user interface that allows the user to dismiss individual
|
||||
* custom tiles, similar to the behavior of Android's status bar and notification panel.
|
||||
* It should be called after the user dismisses a single custom tile using your UI;
|
||||
* upon being informed, the cmstatusbar manager will actually remove the custom tile
|
||||
* upon being informed, the lineagestatusbar manager will actually remove the custom tile
|
||||
* and you will get an {@link #onCustomTileRemoved(StatusBarPanelCustomTile)} callback.
|
||||
* <P>
|
||||
*
|
||||
@@ -217,7 +217,7 @@ public class CustomTileListenerService extends Service {
|
||||
mStatusBarService.removeCustomTileFromListener(
|
||||
mWrapper, pkg, tag, id);
|
||||
} catch (android.os.RemoteException ex) {
|
||||
Log.v(TAG, "Unable to contact cmstautusbar manager", ex);
|
||||
Log.v(TAG, "Unable to contact lineagestatusbar manager", ex);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import cyanogenmod.app.IStatusBarCustomTileHolder;
|
||||
import cyanogenmod.app.StatusBarPanelCustomTile;
|
||||
import lineageos.app.IStatusBarCustomTileHolder;
|
||||
import lineageos.app.StatusBarPanelCustomTile;
|
||||
|
||||
/** @hide */
|
||||
oneway interface ICustomTileListener
|
||||
|
||||
@@ -14,15 +14,15 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.content.ComponentName;
|
||||
|
||||
import cyanogenmod.app.CustomTile;
|
||||
import cyanogenmod.app.ICustomTileListener;
|
||||
import lineageos.app.CustomTile;
|
||||
import lineageos.app.ICustomTileListener;
|
||||
|
||||
/** @hide */
|
||||
interface ICMStatusBarManager {
|
||||
interface ILineageStatusBarManager {
|
||||
// --- Methods below are for use by 3rd party applications to publish quick
|
||||
// settings tiles to the status bar panel
|
||||
// You need the PUBLISH_CUSTOM_TILE permission
|
||||
|
||||
@@ -14,14 +14,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.telephony.SubscriptionInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/** @hide */
|
||||
interface ICMTelephonyManager {
|
||||
interface ILineageTelephonyManager {
|
||||
// --- Methods below are for use by 3rd party applications to manage phone and data connection
|
||||
// You need the READ_MSIM_PHONE_STATE permission
|
||||
List<SubscriptionInfo> getSubInformation();
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
** limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import cyanogenmod.app.LiveLockScreenInfo;
|
||||
import lineageos.app.LiveLockScreenInfo;
|
||||
|
||||
/**
|
||||
* Listener interface for notifying clients that the current Live lock screen has changed.
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
** limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import cyanogenmod.app.ILiveLockScreenChangeListener;
|
||||
import cyanogenmod.app.LiveLockScreenInfo;
|
||||
import lineageos.app.ILiveLockScreenChangeListener;
|
||||
import lineageos.app.LiveLockScreenInfo;
|
||||
|
||||
/** @hide */
|
||||
interface ILiveLockScreenManager {
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
** limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import cyanogenmod.app.ILiveLockScreenChangeListener;
|
||||
import cyanogenmod.app.LiveLockScreenInfo;
|
||||
import lineageos.app.ILiveLockScreenChangeListener;
|
||||
import lineageos.app.LiveLockScreenInfo;
|
||||
|
||||
/**
|
||||
* Interface to be implemented by services that support the
|
||||
@@ -62,4 +62,4 @@ interface ILiveLockScreenManagerProvider {
|
||||
* Unregisters a previously registered ILiveLockScreenChangeListener.
|
||||
*/
|
||||
boolean unregisterChangeListener(in ILiveLockScreenChangeListener listener);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
** limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
/** {@hide} */
|
||||
interface IPartnerInterface
|
||||
|
||||
@@ -15,9 +15,9 @@
|
||||
** limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import cyanogenmod.app.Profile;
|
||||
import lineageos.app.Profile;
|
||||
import android.app.NotificationGroup;
|
||||
import android.os.ParcelUuid;
|
||||
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import cyanogenmod.app.StatusBarPanelCustomTile;
|
||||
import lineageos.app.StatusBarPanelCustomTile;
|
||||
|
||||
/** @hide */
|
||||
interface IStatusBarCustomTileHolder {
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.annotation.SdkConstant;
|
||||
|
||||
@@ -22,121 +22,121 @@ import android.annotation.SdkConstant;
|
||||
* @hide
|
||||
* TODO: We need to somehow make these managers accessible via getSystemService
|
||||
*/
|
||||
public final class CMContextConstants {
|
||||
public final class LineageContextConstants {
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
private CMContextConstants() {
|
||||
private LineageContextConstants() {
|
||||
// Empty constructor
|
||||
}
|
||||
|
||||
/**
|
||||
* Use with {@link android.content.Context#getSystemService} to retrieve a
|
||||
* {@link cyanogenmod.app.CMStatusBarManager} for informing the user of
|
||||
* {@link lineageos.app.LineageStatusBarManager} for informing the user of
|
||||
* background events.
|
||||
*
|
||||
* @see android.content.Context#getSystemService
|
||||
* @see cyanogenmod.app.CMStatusBarManager
|
||||
* @see lineageos.app.LineageStatusBarManager
|
||||
*/
|
||||
public static final String CM_STATUS_BAR_SERVICE = "cmstatusbar";
|
||||
public static final String LINEAGE_STATUS_BAR_SERVICE = "lineagestatusbar";
|
||||
|
||||
/**
|
||||
* Use with {@link android.content.Context#getSystemService} to retrieve a
|
||||
* {@link cyanogenmod.app.ProfileManager} for informing the user of
|
||||
* {@link lineageos.app.ProfileManager} for informing the user of
|
||||
* background events.
|
||||
*
|
||||
* @see android.content.Context#getSystemService
|
||||
* @see cyanogenmod.app.ProfileManager
|
||||
* @see lineageos.app.ProfileManager
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_PROFILE_SERVICE = "profile";
|
||||
public static final String LINEAGE_PROFILE_SERVICE = "profile";
|
||||
|
||||
/**
|
||||
* Use with {@link android.content.Context#getSystemService} to retrieve a
|
||||
* {@link cyanogenmod.app.PartnerInterface} interact with system settings.
|
||||
* {@link lineageos.app.PartnerInterface} interact with system settings.
|
||||
*
|
||||
* @see android.content.Context#getSystemService
|
||||
* @see cyanogenmod.app.PartnerInterface
|
||||
* @see lineageos.app.PartnerInterface
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_PARTNER_INTERFACE = "cmpartnerinterface";
|
||||
public static final String LINEAGE_PARTNER_INTERFACE = "lineagepartnerinterface";
|
||||
|
||||
/**
|
||||
* Use with {@link android.content.Context#getSystemService} to retrieve a
|
||||
* {@link cyanogenmod.app.CMTelephonyManager} to manage the phone and
|
||||
* {@link lineageos.app.LineageTelephonyManager} to manage the phone and
|
||||
* data connection.
|
||||
*
|
||||
* @see android.content.Context#getSystemService
|
||||
* @see cyanogenmod.app.CMTelephonyManager
|
||||
* @see lineageos.app.LineageTelephonyManager
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_TELEPHONY_MANAGER_SERVICE = "cmtelephonymanager";
|
||||
public static final String LINEAGE_TELEPHONY_MANAGER_SERVICE = "lineagetelephonymanager";
|
||||
|
||||
/**
|
||||
* Use with {@link android.content.Context#getSystemService} to retrieve a
|
||||
* {@link cyanogenmod.hardware.CMHardwareManager} to manage the extended
|
||||
* {@link lineageos.hardware.LineageHardwareManager} to manage the extended
|
||||
* hardware features of the device.
|
||||
*
|
||||
* @see android.content.Context#getSystemService
|
||||
* @see cyanogenmod.hardware.CMHardwareManager
|
||||
* @see lineageos.hardware.LineageHardwareManager
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_HARDWARE_SERVICE = "cmhardware";
|
||||
public static final String LINEAGE_HARDWARE_SERVICE = "lineagehardware";
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_APP_SUGGEST_SERVICE = "cmappsuggest";
|
||||
public static final String LINEAGE_APP_SUGGEST_SERVICE = "lineageappsuggest";
|
||||
|
||||
/**
|
||||
* Control device power profile and characteristics.
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_PERFORMANCE_SERVICE = "cmperformance";
|
||||
public static final String LINEAGE_PERFORMANCE_SERVICE = "lineageperformance";
|
||||
|
||||
/**
|
||||
* Controls changing and applying themes
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_THEME_SERVICE = "cmthemes";
|
||||
public static final String LINEAGE_THEME_SERVICE = "lineagethemes";
|
||||
|
||||
/**
|
||||
* Manages composed icons
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_ICON_CACHE_SERVICE = "cmiconcache";
|
||||
public static final String LINEAGE_ICON_CACHE_SERVICE = "lineageiconcache";
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_LIVE_LOCK_SCREEN_SERVICE = "cmlivelockscreen";
|
||||
public static final String LINEAGE_LIVE_LOCK_SCREEN_SERVICE = "lineagelivelockscreen";
|
||||
|
||||
/**
|
||||
* Use with {@link android.content.Context#getSystemService} to retrieve a
|
||||
* {@link cyanogenmod.weather.CMWeatherManager} to manage the weather service
|
||||
* {@link lineageos.weather.LineageWeatherManager} to manage the weather service
|
||||
* settings and request weather updates
|
||||
*
|
||||
* @see android.content.Context#getSystemService
|
||||
* @see cyanogenmod.weather.CMWeatherManager
|
||||
* @see lineageos.weather.LineageWeatherManager
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_WEATHER_SERVICE = "cmweather";
|
||||
public static final String LINEAGE_WEATHER_SERVICE = "lineageweather";
|
||||
|
||||
/**
|
||||
* Manages display color adjustments
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_LIVEDISPLAY_SERVICE = "cmlivedisplay";
|
||||
public static final String LINEAGE_LIVEDISPLAY_SERVICE = "lineagelivedisplay";
|
||||
|
||||
|
||||
/**
|
||||
@@ -144,75 +144,75 @@ public final class CMContextConstants {
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public static final String CM_AUDIO_SERVICE = "cmaudio";
|
||||
public static final String LINEAGE_AUDIO_SERVICE = "lineageaudio";
|
||||
|
||||
/**
|
||||
* Features supported by the CMSDK.
|
||||
* Features supported by the Lineage SDK.
|
||||
*/
|
||||
public static class Features {
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the hardware abstraction
|
||||
* framework service utilized by the cmsdk.
|
||||
* framework service utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String HARDWARE_ABSTRACTION = "org.cyanogenmod.hardware";
|
||||
public static final String HARDWARE_ABSTRACTION = "org.lineageos.hardware";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm status bar service
|
||||
* utilzed by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage status bar service
|
||||
* utilzed by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String STATUSBAR = "org.cyanogenmod.statusbar";
|
||||
public static final String STATUSBAR = "org.lineageos.statusbar";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm profiles service
|
||||
* utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage profiles service
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String PROFILES = "org.cyanogenmod.profiles";
|
||||
public static final String PROFILES = "org.lineageos.profiles";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm app suggest service
|
||||
* utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage app suggest service
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String APP_SUGGEST = "org.cyanogenmod.appsuggest";
|
||||
public static final String APP_SUGGEST = "org.lineageos.appsuggest";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm telephony service
|
||||
* utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage telephony service
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String TELEPHONY = "org.cyanogenmod.telephony";
|
||||
public static final String TELEPHONY = "org.lineageos.telephony";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm theme service
|
||||
* utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage theme service
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String THEMES = "org.cyanogenmod.theme";
|
||||
public static final String THEMES = "org.lineageos.theme";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm performance service
|
||||
* utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage performance service
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String PERFORMANCE = "org.cyanogenmod.performance";
|
||||
public static final String PERFORMANCE = "org.lineageos.performance";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm partner service
|
||||
* utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage partner service
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String PARTNER = "org.cyanogenmod.partner";
|
||||
public static final String PARTNER = "org.lineageos.partner";
|
||||
|
||||
/*
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
@@ -220,30 +220,30 @@ public final class CMContextConstants {
|
||||
* feature.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String LIVE_LOCK_SCREEN = "org.cyanogenmod.livelockscreen";
|
||||
public static final String LIVE_LOCK_SCREEN = "org.lineageos.livelockscreen";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the cm weather weather
|
||||
* service utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the lineage weather weather
|
||||
* service utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String WEATHER_SERVICES = "org.cyanogenmod.weather";
|
||||
public static final String WEATHER_SERVICES = "org.lineageos.weather";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the LiveDisplay service
|
||||
* utilized by the cmsdk.
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String LIVEDISPLAY = "org.cyanogenmod.livedisplay";
|
||||
public static final String LIVEDISPLAY = "org.lineageos.livedisplay";
|
||||
|
||||
/**
|
||||
* Feature for {@link PackageManager#getSystemAvailableFeatures} and
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the CM audio extensions
|
||||
* utilized by the cmsdk.
|
||||
* {@link PackageManager#hasSystemFeature}: The device includes the Lineage audio extensions
|
||||
* utilized by the lineage sdk.
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.FEATURE)
|
||||
public static final String AUDIO = "org.cyanogenmod.audio";
|
||||
public static final String AUDIO = "org.lineageos.audio";
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.IBinder;
|
||||
@@ -24,10 +24,10 @@ import android.os.UserHandle;
|
||||
import android.util.Log;
|
||||
import android.util.Slog;
|
||||
|
||||
import cyanogenmod.app.ICMStatusBarManager;
|
||||
import lineageos.app.ILineageStatusBarManager;
|
||||
|
||||
/**
|
||||
* The CMStatusBarManager allows you to publish and remove CustomTiles within the
|
||||
* The LineageStatusBarManager allows you to publish and remove CustomTiles within the
|
||||
* Quick Settings Panel.
|
||||
*
|
||||
* <p>
|
||||
@@ -44,20 +44,20 @@ import cyanogenmod.app.ICMStatusBarManager;
|
||||
* this custom tile.
|
||||
*
|
||||
* <p>
|
||||
* To get the instance of this class, utilize CMStatusBarManager#getInstance(Context context)
|
||||
* To get the instance of this class, utilize LineageStatusBarManager#getInstance(Context context)
|
||||
*
|
||||
* @see cyanogenmod.app.CustomTile
|
||||
* @see lineageos.app.CustomTile
|
||||
*/
|
||||
public class CMStatusBarManager {
|
||||
private static final String TAG = "CMStatusBarManager";
|
||||
public class LineageStatusBarManager {
|
||||
private static final String TAG = "LineageStatusBarManager";
|
||||
private static boolean localLOGV = false;
|
||||
|
||||
private Context mContext;
|
||||
|
||||
private static ICMStatusBarManager sService;
|
||||
private static ILineageStatusBarManager sService;
|
||||
|
||||
private static CMStatusBarManager sCMStatusBarManagerInstance;
|
||||
private CMStatusBarManager(Context context) {
|
||||
private static LineageStatusBarManager sLineageStatusBarManagerInstance;
|
||||
private LineageStatusBarManager(Context context) {
|
||||
Context appContext = context.getApplicationContext();
|
||||
if (appContext != null) {
|
||||
mContext = appContext;
|
||||
@@ -67,23 +67,23 @@ public class CMStatusBarManager {
|
||||
sService = getService();
|
||||
|
||||
if (context.getPackageManager().hasSystemFeature(
|
||||
cyanogenmod.app.CMContextConstants.Features.STATUSBAR) && sService == null) {
|
||||
Log.wtf(TAG, "Unable to get CMStatusBarService. The service either" +
|
||||
lineageos.app.LineageContextConstants.Features.STATUSBAR) && sService == null) {
|
||||
Log.wtf(TAG, "Unable to get LineageStatusBarService. The service either" +
|
||||
" crashed, was not started, or the interface has been called to early in" +
|
||||
" SystemServer init");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get or create an instance of the {@link cyanogenmod.app.CMStatusBarManager}
|
||||
* Get or create an instance of the {@link lineageos.app.LineageStatusBarManager}
|
||||
* @param context
|
||||
* @return {@link cyanogenmod.app.CMStatusBarManager}
|
||||
* @return {@link lineageos.app.LineageStatusBarManager}
|
||||
*/
|
||||
public static CMStatusBarManager getInstance(Context context) {
|
||||
if (sCMStatusBarManagerInstance == null) {
|
||||
sCMStatusBarManagerInstance = new CMStatusBarManager(context);
|
||||
public static LineageStatusBarManager getInstance(Context context) {
|
||||
if (sLineageStatusBarManagerInstance == null) {
|
||||
sLineageStatusBarManagerInstance = new LineageStatusBarManager(context);
|
||||
}
|
||||
return sCMStatusBarManagerInstance;
|
||||
return sLineageStatusBarManagerInstance;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -91,7 +91,7 @@ public class CMStatusBarManager {
|
||||
* the same id has already been posted by your application and has not yet been removed, it
|
||||
* will be replaced by the updated information.
|
||||
*
|
||||
* You will need the cyanogenmod.permission.PUBLISH_CUSTOM_TILE
|
||||
* You will need the lineageos.permission.PUBLISH_CUSTOM_TILE
|
||||
* to utilize this functionality.
|
||||
*
|
||||
* @param id An identifier for this customTile unique within your
|
||||
@@ -108,18 +108,18 @@ public class CMStatusBarManager {
|
||||
* the same tag and id has already been posted by your application and has not yet been
|
||||
* removed, it will be replaced by the updated information.
|
||||
*
|
||||
* You will need the cyanogenmod.permission.PUBLISH_CUSTOM_TILE
|
||||
* You will need the lineageos.permission.PUBLISH_CUSTOM_TILE
|
||||
* to utilize this functionality.
|
||||
*
|
||||
* @param tag A string identifier for this custom tile. May be {@code null}.
|
||||
* @param id An identifier for this custom tile. The pair (tag, id) must be unique
|
||||
* within your application.
|
||||
* @param customTile A {@link cyanogenmod.app.CustomTile} object describing what to
|
||||
* @param customTile A {@link lineageos.app.CustomTile} object describing what to
|
||||
* show the user. Must not be null.
|
||||
*/
|
||||
public void publishTile(String tag, int id, CustomTile customTile) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMStatusBarManagerService");
|
||||
Log.w(TAG, "not connected to LineageStatusBarManagerService");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -133,27 +133,27 @@ public class CMStatusBarManager {
|
||||
Log.w(TAG, "notify: id corrupted: sent " + id + ", got back " + idOut[0]);
|
||||
}
|
||||
} catch (RemoteException e) {
|
||||
Slog.w("CMStatusBarManager", "warning: no cm status bar service");
|
||||
Slog.w("LineageStatusBarManager", "warning: no lineage status bar service");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Similar to {@link cyanogenmod.app.CMStatusBarManager#publishTile(int id, cyanogenmod.app.CustomTile)},
|
||||
* Similar to {@link lineageos.app.LineageStatusBarManager#publishTile(int id, lineageos.app.CustomTile)},
|
||||
* however lets you specify a {@link android.os.UserHandle}
|
||||
*
|
||||
* You will need the cyanogenmod.permission.PUBLISH_CUSTOM_TILE
|
||||
* You will need the lineageos.permission.PUBLISH_CUSTOM_TILE
|
||||
* to utilize this functionality.
|
||||
*
|
||||
* @param tag A string identifier for this custom tile. May be {@code null}.
|
||||
* @param id An identifier for this custom tile. The pair (tag, id) must be unique
|
||||
* within your application.
|
||||
* @param customTile A {@link cyanogenmod.app.CustomTile} object describing what to
|
||||
* @param customTile A {@link lineageos.app.CustomTile} object describing what to
|
||||
* show the user. Must not be null.
|
||||
* @param user A user handle to publish the tile as.
|
||||
*/
|
||||
public void publishTileAsUser(String tag, int id, CustomTile customTile, UserHandle user) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMStatusBarManagerService");
|
||||
Log.w(TAG, "not connected to LineageStatusBarManagerService");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -167,14 +167,14 @@ public class CMStatusBarManager {
|
||||
Log.w(TAG, "notify: id corrupted: sent " + id + ", got back " + idOut[0]);
|
||||
}
|
||||
} catch (RemoteException e) {
|
||||
Slog.w("CMStatusBarManager", "warning: no cm status bar service");
|
||||
Slog.w("LineageStatusBarManager", "warning: no lineage status bar service");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Remove a custom tile that's currently published to the StatusBarPanel.
|
||||
*
|
||||
* You will need the cyanogenmod.permission.PUBLISH_CUSTOM_TILE
|
||||
* You will need the lineageos.permission.PUBLISH_CUSTOM_TILE
|
||||
* to utilize this functionality.
|
||||
*
|
||||
* @param id The identifier for the custom tile to be removed.
|
||||
@@ -186,7 +186,7 @@ public class CMStatusBarManager {
|
||||
/**
|
||||
* Remove a custom tile that's currently published to the StatusBarPanel.
|
||||
*
|
||||
* You will need the cyanogenmod.platform.PUBLISH_CUSTOM_TILE
|
||||
* You will need the lineageos.platform.PUBLISH_CUSTOM_TILE
|
||||
* to utilize this functionality.
|
||||
*
|
||||
* @param tag The string identifier for the custom tile to be removed.
|
||||
@@ -194,7 +194,7 @@ public class CMStatusBarManager {
|
||||
*/
|
||||
public void removeTile(String tag, int id) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMStatusBarManagerService");
|
||||
Log.w(TAG, "not connected to LineageStatusBarManagerService");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -203,15 +203,15 @@ public class CMStatusBarManager {
|
||||
try {
|
||||
sService.removeCustomTileWithTag(pkg, tag, id, UserHandle.myUserId());
|
||||
} catch (RemoteException e) {
|
||||
Slog.w("CMStatusBarManager", "warning: no cm status bar service");
|
||||
Slog.w("LineageStatusBarManager", "warning: no lineage status bar service");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Similar to {@link cyanogenmod.app.CMStatusBarManager#removeTile(String tag, int id)}
|
||||
* Similar to {@link lineageos.app.LineageStatusBarManager#removeTile(String tag, int id)}
|
||||
* however lets you specific a {@link android.os.UserHandle}
|
||||
*
|
||||
* You will need the cyanogenmod.platform.PUBLISH_CUSTOM_TILE
|
||||
* You will need the lineageos.platform.PUBLISH_CUSTOM_TILE
|
||||
* to utilize this functionality.
|
||||
*
|
||||
* @param tag The string identifier for the custom tile to be removed.
|
||||
@@ -220,7 +220,7 @@ public class CMStatusBarManager {
|
||||
*/
|
||||
public void removeTileAsUser(String tag, int id, UserHandle user) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMStatusBarManagerService");
|
||||
Log.w(TAG, "not connected to LineageStatusBarManagerService");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -233,13 +233,13 @@ public class CMStatusBarManager {
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public ICMStatusBarManager getService() {
|
||||
public ILineageStatusBarManager getService() {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_STATUS_BAR_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_STATUS_BAR_SERVICE);
|
||||
if (b != null) {
|
||||
sService = ICMStatusBarManager.Stub.asInterface(b);
|
||||
sService = ILineageStatusBarManager.Stub.asInterface(b);
|
||||
return sService;
|
||||
}
|
||||
return null;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.IBinder;
|
||||
@@ -26,30 +26,30 @@ import android.util.Slog;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import cyanogenmod.app.CMContextConstants;
|
||||
import lineageos.app.LineageContextConstants;
|
||||
|
||||
/**
|
||||
* The CMTelephonyManager allows you to view and manage the phone state and
|
||||
* The LineageTelephonyManager allows you to view and manage the phone state and
|
||||
* the data connection, with multiple SIMs support.
|
||||
*
|
||||
* <p>
|
||||
* To get the instance of this class, utilize CMTelephonyManager#getInstance(Context context)
|
||||
* To get the instance of this class, utilize LineageTelephonyManager#getInstance(Context context)
|
||||
*/
|
||||
public class CMTelephonyManager {
|
||||
public class LineageTelephonyManager {
|
||||
|
||||
/**
|
||||
* Subscription ID used to set the default Phone and SMS to "ask every time".
|
||||
*/
|
||||
public static final int ASK_FOR_SUBSCRIPTION_ID = 0;
|
||||
|
||||
private static final String TAG = "CMTelephonyManager";
|
||||
private static final String TAG = "LineageTelephonyManager";
|
||||
private static boolean localLOGD = Log.isLoggable(TAG, Log.DEBUG);
|
||||
|
||||
private static ICMTelephonyManager sService;
|
||||
private static CMTelephonyManager sCMTelephonyManagerInstance;
|
||||
private static ILineageTelephonyManager sService;
|
||||
private static LineageTelephonyManager sLineageTelephonyManagerInstance;
|
||||
private Context mContext;
|
||||
|
||||
private CMTelephonyManager(Context context) {
|
||||
private LineageTelephonyManager(Context context) {
|
||||
Context appContext = context.getApplicationContext();
|
||||
if (appContext != null) {
|
||||
mContext = appContext;
|
||||
@@ -58,34 +58,34 @@ public class CMTelephonyManager {
|
||||
}
|
||||
sService = getService();
|
||||
|
||||
if (context.getPackageManager().hasSystemFeature(CMContextConstants.Features.TELEPHONY)
|
||||
if (context.getPackageManager().hasSystemFeature(LineageContextConstants.Features.TELEPHONY)
|
||||
&& sService == null) {
|
||||
Log.wtf(TAG, "Unable to get CMTelephonyManagerService. " +
|
||||
Log.wtf(TAG, "Unable to get LineageTelephonyManagerService. " +
|
||||
"The service either crashed, was not started, or the interface has been " +
|
||||
"called to early in SystemServer init");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get or create an instance of the {@link cyanogenmod.app.CMTelephonyManager}
|
||||
* Get or create an instance of the {@link lineageos.app.LineageTelephonyManager}
|
||||
*
|
||||
* @return {@link cyanogenmod.app.CMTelephonyManager}
|
||||
* @return {@link lineageos.app.LineageTelephonyManager}
|
||||
*/
|
||||
public static CMTelephonyManager getInstance(Context context) {
|
||||
if (sCMTelephonyManagerInstance == null) {
|
||||
sCMTelephonyManagerInstance = new CMTelephonyManager(context);
|
||||
public static LineageTelephonyManager getInstance(Context context) {
|
||||
if (sLineageTelephonyManagerInstance == null) {
|
||||
sLineageTelephonyManagerInstance = new LineageTelephonyManager(context);
|
||||
}
|
||||
return sCMTelephonyManagerInstance;
|
||||
return sLineageTelephonyManagerInstance;
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public ICMTelephonyManager getService() {
|
||||
public ILineageTelephonyManager getService() {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_TELEPHONY_MANAGER_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_TELEPHONY_MANAGER_SERVICE);
|
||||
if (b != null) {
|
||||
sService = ICMTelephonyManager.Stub.asInterface(b);
|
||||
sService = ILineageTelephonyManager.Stub.asInterface(b);
|
||||
return sService;
|
||||
}
|
||||
return null;
|
||||
@@ -100,7 +100,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public List<SubscriptionInfo> getSubInformation() {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -117,7 +117,7 @@ public class CMTelephonyManager {
|
||||
Log.w(TAG, "the subscription list is empty");
|
||||
}
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
|
||||
return subInfoList;
|
||||
@@ -134,7 +134,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public boolean isSubActive(int subId) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -150,7 +150,7 @@ public class CMTelephonyManager {
|
||||
Log.v(TAG, pkg + " getting the SIM state with subscription " + subId + " as active: " + simActive);
|
||||
}
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
|
||||
return simActive;
|
||||
@@ -167,7 +167,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public void setSubState(int subId, boolean state) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -179,7 +179,7 @@ public class CMTelephonyManager {
|
||||
try {
|
||||
sService.setSubState(subId, state);
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -197,7 +197,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public boolean isDataConnectionSelectedOnSub(int subId) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -214,7 +214,7 @@ public class CMTelephonyManager {
|
||||
subId + " as active: " + dataConnectionActiveOnSim);
|
||||
}
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
|
||||
return dataConnectionActiveOnSim;
|
||||
@@ -230,7 +230,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public boolean isDataConnectionEnabled() {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return false;
|
||||
}
|
||||
|
||||
@@ -246,7 +246,7 @@ public class CMTelephonyManager {
|
||||
Log.v(TAG, pkg + " getting if the network data connection is enabled: " + dataConnectionEnabled);
|
||||
}
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
|
||||
return dataConnectionEnabled;
|
||||
@@ -259,7 +259,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public void setDataConnectionState(boolean state) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -271,7 +271,7 @@ public class CMTelephonyManager {
|
||||
try {
|
||||
sService.setDataConnectionState(state);
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -286,7 +286,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public void setDataConnectionSelectedOnSub(int subId) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -298,7 +298,7 @@ public class CMTelephonyManager {
|
||||
try {
|
||||
sService.setDataConnectionSelectedOnSub(subId);
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -313,7 +313,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public void setDefaultPhoneSub(int subId) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -325,7 +325,7 @@ public class CMTelephonyManager {
|
||||
try {
|
||||
sService.setDefaultPhoneSub(subId);
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -340,7 +340,7 @@ public class CMTelephonyManager {
|
||||
*/
|
||||
public void setDefaultSmsSub(int subId) {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMTelephonyManager");
|
||||
Log.w(TAG, "not connected to LineageTelephonyManager");
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -352,7 +352,7 @@ public class CMTelephonyManager {
|
||||
try {
|
||||
sService.setDefaultSmsSub(subId);
|
||||
} catch (RemoteException e) {
|
||||
Slog.w(TAG, "warning: no cm telephony manager service");
|
||||
Slog.w(TAG, "warning: no lineage telephony manager service");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
parcelable LiveLockScreenInfo;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.annotation.NonNull;
|
||||
import android.content.ComponentName;
|
||||
@@ -23,9 +23,9 @@ import android.os.Parcelable;
|
||||
|
||||
import android.text.TextUtils;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
/**
|
||||
* Data structure defining a Live lock screen.
|
||||
@@ -59,7 +59,7 @@ public class LiveLockScreenInfo implements Parcelable {
|
||||
|
||||
/**
|
||||
* The component, which implements
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}, to display for this
|
||||
* {@link lineageos.externalviews.KeyguardExternalViewProviderService}, to display for this
|
||||
* live lock screen.
|
||||
*/
|
||||
public ComponentName component;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.annotation.NonNull;
|
||||
import android.annotation.Nullable;
|
||||
@@ -42,13 +42,13 @@ public class LiveLockScreenManager {
|
||||
*/
|
||||
@SdkConstant(SdkConstant.SdkConstantType.SERVICE_ACTION)
|
||||
public static final String SERVICE_INTERFACE
|
||||
= "cyanogenmod.app.LiveLockScreenManagerService";
|
||||
= "lineageos.app.LiveLockScreenManagerService";
|
||||
|
||||
private LiveLockScreenManager(Context context) {
|
||||
mContext = context;
|
||||
sService = getService();
|
||||
if (context.getPackageManager().hasSystemFeature(
|
||||
CMContextConstants.Features.LIVE_LOCK_SCREEN) && sService == null) {
|
||||
LineageContextConstants.Features.LIVE_LOCK_SCREEN) && sService == null) {
|
||||
Log.wtf(TAG, "Unable to get LiveLockScreenManagerService. " +
|
||||
"The service either crashed, was not started, or the interface has " +
|
||||
"been called to early in SystemServer init");
|
||||
@@ -57,7 +57,7 @@ public class LiveLockScreenManager {
|
||||
|
||||
private ILiveLockScreenManager getService() {
|
||||
if (sService == null) {
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_LIVE_LOCK_SCREEN_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_LIVE_LOCK_SCREEN_SERVICE);
|
||||
if (b != null) {
|
||||
sService = ILiveLockScreenManager.Stub.asInterface(b);
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.IBinder;
|
||||
@@ -63,13 +63,13 @@ public class PartnerInterface {
|
||||
* such as enabling or disabling airplane mode.
|
||||
*/
|
||||
public static final String MODIFY_NETWORK_SETTINGS_PERMISSION =
|
||||
"cyanogenmod.permission.MODIFY_NETWORK_SETTINGS";
|
||||
"lineageos.permission.MODIFY_NETWORK_SETTINGS";
|
||||
|
||||
/**
|
||||
* Allows an application to change system sound settings, such as the zen mode.
|
||||
*/
|
||||
public static final String MODIFY_SOUND_SETTINGS_PERMISSION =
|
||||
"cyanogenmod.permission.MODIFY_SOUND_SETTINGS";
|
||||
"lineageos.permission.MODIFY_SOUND_SETTINGS";
|
||||
|
||||
private static final String TAG = "PartnerInterface";
|
||||
|
||||
@@ -84,7 +84,7 @@ public class PartnerInterface {
|
||||
}
|
||||
sService = getService();
|
||||
if (context.getPackageManager().hasSystemFeature(
|
||||
CMContextConstants.Features.PARTNER) && sService == null) {
|
||||
LineageContextConstants.Features.PARTNER) && sService == null) {
|
||||
throw new RuntimeException("Unable to get PartnerInterfaceService. The service" +
|
||||
" either crashed, was not started, or the interface has been called to early" +
|
||||
" in SystemServer init");
|
||||
@@ -92,7 +92,7 @@ public class PartnerInterface {
|
||||
}
|
||||
|
||||
/**
|
||||
* Get or create an instance of the {@link cyanogenmod.app.PartnerInterface}
|
||||
* Get or create an instance of the {@link lineageos.app.PartnerInterface}
|
||||
* @param context
|
||||
* @return {@link PartnerInterface}
|
||||
*/
|
||||
@@ -108,7 +108,7 @@ public class PartnerInterface {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_PARTNER_INTERFACE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_PARTNER_INTERFACE);
|
||||
if (b != null) {
|
||||
sService = IPartnerInterface.Stub.asInterface(b);
|
||||
return sService;
|
||||
@@ -245,7 +245,7 @@ public class PartnerInterface {
|
||||
|
||||
/**
|
||||
* Retrieves the package name of the application that currently holds the
|
||||
* {@link cyanogenmod.media.MediaRecorder.AudioSource#HOTWORD} input.
|
||||
* {@link lineageos.media.MediaRecorder.AudioSource#HOTWORD} input.
|
||||
* @return The package name or null if no application currently holds the HOTWORD input.
|
||||
*/
|
||||
public String getCurrentHotwordPackageName() {
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
parcelable Profile;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.content.Context;
|
||||
import android.media.AudioManager;
|
||||
@@ -27,16 +27,16 @@ import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
|
||||
import com.android.internal.policy.IKeyguardService;
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.profiles.AirplaneModeSettings;
|
||||
import cyanogenmod.profiles.BrightnessSettings;
|
||||
import cyanogenmod.profiles.ConnectionSettings;
|
||||
import cyanogenmod.profiles.LockSettings;
|
||||
import cyanogenmod.profiles.RingModeSettings;
|
||||
import cyanogenmod.profiles.StreamSettings;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.profiles.AirplaneModeSettings;
|
||||
import lineageos.profiles.BrightnessSettings;
|
||||
import lineageos.profiles.ConnectionSettings;
|
||||
import lineageos.profiles.LockSettings;
|
||||
import lineageos.profiles.RingModeSettings;
|
||||
import lineageos.profiles.StreamSettings;
|
||||
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParser;
|
||||
import org.xmlpull.v1.XmlPullParserException;
|
||||
@@ -236,7 +236,7 @@ public final class Profile implements Parcelable, Comparable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mType = in.readInt();
|
||||
mId = in.readString();
|
||||
mState = in.readInt();
|
||||
@@ -646,7 +646,7 @@ public final class Profile implements Parcelable, Comparable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
if (in.readInt() != 0) {
|
||||
mName = in.readString();
|
||||
}
|
||||
@@ -702,7 +702,7 @@ public final class Profile implements Parcelable, Comparable {
|
||||
mExpandedDesktopMode = in.readInt();
|
||||
mDozeMode = in.readInt();
|
||||
}
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.ELDERBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.ELDERBERRY) {
|
||||
mNotificationLightMode = in.readInt();
|
||||
if (in.readInt() != 0) {
|
||||
for (ConnectionSettings connection :
|
||||
@@ -1127,7 +1127,7 @@ public final class Profile implements Parcelable, Comparable {
|
||||
|
||||
if (value != null) {
|
||||
profileNameResId = context.getResources().getIdentifier(value, "string",
|
||||
"cyanogenmod.platform");
|
||||
"lineageos.platform");
|
||||
if (profileNameResId > 0) {
|
||||
profileName = context.getResources().getString(profileNameResId);
|
||||
}
|
||||
@@ -1206,7 +1206,7 @@ public final class Profile implements Parcelable, Comparable {
|
||||
}
|
||||
if (name.equals("connectionDescriptor")) {
|
||||
ConnectionSettings cs = ConnectionSettings.fromXml(xpp, context);
|
||||
if (Build.CM_VERSION.SDK_INT >= Build.CM_VERSION_CODES.ELDERBERRY
|
||||
if (Build.LINEAGE_VERSION.SDK_INT >= Build.LINEAGE_VERSION_CODES.ELDERBERRY
|
||||
&& cs.getConnectionId() == ConnectionSettings.PROFILE_CONNECTION_2G3G4G) {
|
||||
profile.networkConnectionSubIds.put(cs.getSubId(), cs);
|
||||
} else {
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.app.Notification;
|
||||
import android.app.NotificationGroup;
|
||||
@@ -29,10 +29,10 @@ import android.os.ParcelUuid;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import lineageos.os.Build;
|
||||
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.UUID;
|
||||
@@ -297,7 +297,7 @@ public final class ProfileGroup implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mName = in.readString();
|
||||
mUuid = ParcelUuid.CREATOR.createFromParcel(in).getUuid();
|
||||
mDefaultGroup = in.readInt() != 0;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
@@ -28,10 +28,10 @@ import android.os.RemoteException;
|
||||
import android.os.ServiceManager;
|
||||
import android.util.Log;
|
||||
|
||||
import cyanogenmod.app.IProfileManager;
|
||||
import lineageos.app.IProfileManager;
|
||||
|
||||
import com.android.internal.R;
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
|
||||
/**
|
||||
@@ -57,8 +57,8 @@ import cyanogenmod.providers.CMSettings;
|
||||
* <p>
|
||||
* This manager requires the MODIFY_PROFILES permission.
|
||||
*
|
||||
* @see cyanogenmod.app.Profile
|
||||
* @see cyanogenmod.app.ProfileGroup
|
||||
* @see lineageos.app.Profile
|
||||
* @see lineageos.app.ProfileGroup
|
||||
*/
|
||||
public class ProfileManager {
|
||||
|
||||
@@ -73,7 +73,7 @@ public class ProfileManager {
|
||||
* or by calls to the ProfileManagerService / Profile.</p>
|
||||
*/
|
||||
public static final String INTENT_ACTION_PROFILE_SELECTED =
|
||||
"cyanogenmod.platform.intent.action.PROFILE_SELECTED";
|
||||
"lineageos.platform.intent.action.PROFILE_SELECTED";
|
||||
|
||||
/**
|
||||
* <p>Broadcast Action: Current profile has been updated. This is triggered every time the
|
||||
@@ -82,14 +82,14 @@ public class ProfileManager {
|
||||
* trigger a profile selection, but causes its name to change.</p>
|
||||
*/
|
||||
public static final String INTENT_ACTION_PROFILE_UPDATED =
|
||||
"cyanogenmod.platform.intent.action.PROFILE_UPDATED";
|
||||
"lineageos.platform.intent.action.PROFILE_UPDATED";
|
||||
|
||||
|
||||
/**
|
||||
* @hide
|
||||
*/
|
||||
public static final String INTENT_ACTION_PROFILE_TRIGGER_STATE_CHANGED =
|
||||
"cyanogenmod.platform.intent.action.INTENT_ACTION_PROFILE_TRIGGER_STATE_CHANGED";
|
||||
"lineageos.platform.intent.action.INTENT_ACTION_PROFILE_TRIGGER_STATE_CHANGED";
|
||||
|
||||
/**
|
||||
* @hide
|
||||
@@ -141,7 +141,7 @@ public class ProfileManager {
|
||||
*/
|
||||
@SdkConstant(SdkConstantType.ACTIVITY_INTENT_ACTION)
|
||||
public static final String ACTION_PROFILE_PICKER =
|
||||
"cyanogenmod.platform.intent.action.PROFILE_PICKER";
|
||||
"lineageos.platform.intent.action.PROFILE_PICKER";
|
||||
|
||||
/**
|
||||
* Constant for NO_PROFILE
|
||||
@@ -157,7 +157,7 @@ public class ProfileManager {
|
||||
* @see #ACTION_PROFILE_PICKER
|
||||
*/
|
||||
public static final String EXTRA_PROFILE_SHOW_NONE =
|
||||
"cyanogenmod.platform.intent.extra.profile.SHOW_NONE";
|
||||
"lineageos.platform.intent.extra.profile.SHOW_NONE";
|
||||
|
||||
/**
|
||||
* Given to the profile picker as a {@link UUID} string representation. The {@link UUID}
|
||||
@@ -169,7 +169,7 @@ public class ProfileManager {
|
||||
* @see #ACTION_PROFILE_PICKER
|
||||
*/
|
||||
public static final String EXTRA_PROFILE_EXISTING_UUID =
|
||||
"cyanogenmod.platform.extra.profile.EXISTING_UUID";
|
||||
"lineageos.platform.extra.profile.EXISTING_UUID";
|
||||
|
||||
/**
|
||||
* Given to the profile picker as a {@link CharSequence}. The title to
|
||||
@@ -179,7 +179,7 @@ public class ProfileManager {
|
||||
* @see #ACTION_PROFILE_PICKER
|
||||
*/
|
||||
public static final String EXTRA_PROFILE_TITLE =
|
||||
"cyanogenmod.platform.intent.extra.profile.TITLE";
|
||||
"lineageos.platform.intent.extra.profile.TITLE";
|
||||
|
||||
/**
|
||||
* Returned from the profile picker as a {@link UUID} string representation.
|
||||
@@ -191,7 +191,7 @@ public class ProfileManager {
|
||||
* @see #ACTION_PROFILE_PICKER
|
||||
*/
|
||||
public static final String EXTRA_PROFILE_PICKED_UUID =
|
||||
"cyanogenmod.platform.intent.extra.profile.PICKED_UUID";
|
||||
"lineageos.platform.intent.extra.profile.PICKED_UUID";
|
||||
|
||||
/**
|
||||
* Broadcast intent action indicating that Profiles has been enabled or disabled.
|
||||
@@ -201,7 +201,7 @@ public class ProfileManager {
|
||||
*/
|
||||
@SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
|
||||
public static final String PROFILES_STATE_CHANGED_ACTION =
|
||||
"cyanogenmod.platform.app.profiles.PROFILES_STATE_CHANGED";
|
||||
"lineageos.platform.app.profiles.PROFILES_STATE_CHANGED";
|
||||
|
||||
/**
|
||||
* The lookup key for an int that indicates whether Profiles are enabled or
|
||||
@@ -219,7 +219,7 @@ public class ProfileManager {
|
||||
* @see #ACTION_PROFILE_PICKER
|
||||
*/
|
||||
public static final String EXTRA_PROFILE_DIALOG_THEME =
|
||||
"cyanogenmod.platform.intent.extra.profile.DIALOG_THEME";
|
||||
"lineageos.platform.intent.extra.profile.DIALOG_THEME";
|
||||
|
||||
/**
|
||||
* Profiles are disabled.
|
||||
@@ -246,7 +246,7 @@ public class ProfileManager {
|
||||
sService = getService();
|
||||
|
||||
if (context.getPackageManager().hasSystemFeature(
|
||||
cyanogenmod.app.CMContextConstants.Features.PROFILES) && sService == null) {
|
||||
lineageos.app.LineageContextConstants.Features.PROFILES) && sService == null) {
|
||||
Log.wtf(TAG, "Unable to get ProfileManagerService. The service either" +
|
||||
" crashed, was not started, or the interface has been called to early in" +
|
||||
" SystemServer init");
|
||||
@@ -254,7 +254,7 @@ public class ProfileManager {
|
||||
}
|
||||
|
||||
/**
|
||||
* Get or create an instance of the {@link cyanogenmod.app.ProfileManager}
|
||||
* Get or create an instance of the {@link lineageos.app.ProfileManager}
|
||||
* @param context
|
||||
* @return {@link ProfileManager}
|
||||
*/
|
||||
@@ -270,7 +270,7 @@ public class ProfileManager {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_PROFILE_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_PROFILE_SERVICE);
|
||||
sService = IProfileManager.Stub.asInterface(b);
|
||||
return sService;
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
parcelable StatusBarPanelCustomTile;
|
||||
|
||||
|
||||
@@ -14,20 +14,20 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
import android.os.UserHandle;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import lineageos.os.Build;
|
||||
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
/**
|
||||
* Class encapsulating a Custom Tile. Sent by the StatusBarManagerService to clients including
|
||||
* the status bar panel and any {@link cyanogenmod.app.CustomTileListenerService} clients.
|
||||
* the status bar panel and any {@link lineageos.app.CustomTileListenerService} clients.
|
||||
*/
|
||||
public class StatusBarPanelCustomTile implements Parcelable {
|
||||
|
||||
@@ -90,7 +90,7 @@ public class StatusBarPanelCustomTile implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.APRICOT) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.APRICOT) {
|
||||
// default
|
||||
tmpPkg = in.readString();
|
||||
tmpOpPkg = in.readString();
|
||||
@@ -107,7 +107,7 @@ public class StatusBarPanelCustomTile implements Parcelable {
|
||||
tmpPostTime = in.readLong();
|
||||
}
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
tmpResPkg = in.readString();
|
||||
}
|
||||
|
||||
@@ -151,8 +151,8 @@ public class StatusBarPanelCustomTile implements Parcelable {
|
||||
}
|
||||
};
|
||||
|
||||
/** The {@link cyanogenmod.app.CustomTile} supplied to
|
||||
* {@link cyanogenmod.app.CMStatusBarManager#publishTile(int, cyanogenmod.app.CustomTile)}.
|
||||
/** The {@link lineageos.app.CustomTile} supplied to
|
||||
* {@link lineageos.app.LineageStatusBarManager#publishTile(int, lineageos.app.CustomTile)}.
|
||||
*/
|
||||
public CustomTile getCustomTile() {
|
||||
return customTile;
|
||||
@@ -210,12 +210,12 @@ public class StatusBarPanelCustomTile implements Parcelable {
|
||||
return pkg;
|
||||
}
|
||||
|
||||
/** The id supplied to CMStatusBarManager */
|
||||
/** The id supplied to LineageStatusBarManager */
|
||||
public int getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
/** The tag supplied to CMStatusBarManager or null if no tag was specified. */
|
||||
/** The tag supplied to LineageStatusBarManager or null if no tag was specified. */
|
||||
public String getTag() {
|
||||
return tag;
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
/**
|
||||
* The id value here matches the framework. Unknown is given a -1 value since future
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.app;
|
||||
package lineageos.app;
|
||||
|
||||
import android.os.Build;
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app.suggest;
|
||||
package lineageos.app.suggest;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
@@ -31,12 +31,12 @@ import java.io.InputStream;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import cyanogenmod.app.CMContextConstants;
|
||||
import cyanogenmod.app.suggest.ApplicationSuggestion;
|
||||
import lineageos.app.LineageContextConstants;
|
||||
import lineageos.app.suggest.ApplicationSuggestion;
|
||||
|
||||
/**
|
||||
* Provides an interface to get information about suggested apps for an intent which may include
|
||||
* applications not installed on the device. This is used by the CMResolver in order to provide
|
||||
* applications not installed on the device. This is used by the LineageResolver in order to provide
|
||||
* suggestions when an intent is fired but no application exists for the given intent.
|
||||
*
|
||||
* @hide
|
||||
@@ -68,7 +68,7 @@ public class AppSuggestManager {
|
||||
|
||||
sInstance = new AppSuggestManager(context);
|
||||
|
||||
if (context.getPackageManager().hasSystemFeature(CMContextConstants.Features.APP_SUGGEST)
|
||||
if (context.getPackageManager().hasSystemFeature(LineageContextConstants.Features.APP_SUGGEST)
|
||||
&& sImpl == null) {
|
||||
throw new RuntimeException("Unable to get AppSuggestManagerService. " +
|
||||
"The service either crashed, was not started, or the interface has been" +
|
||||
@@ -86,7 +86,7 @@ public class AppSuggestManager {
|
||||
/** @hide */
|
||||
public static synchronized IAppSuggestManager getService() {
|
||||
if (sImpl == null) {
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_APP_SUGGEST_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_APP_SUGGEST_SERVICE);
|
||||
if (b != null) {
|
||||
sImpl = IAppSuggestManager.Stub.asInterface(b);
|
||||
} else {
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app.suggest;
|
||||
package lineageos.app.suggest;
|
||||
|
||||
/**
|
||||
* @hide
|
||||
|
||||
@@ -14,16 +14,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app.suggest;
|
||||
package lineageos.app.suggest;
|
||||
|
||||
import android.annotation.NonNull;
|
||||
import android.net.Uri;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
/**
|
||||
* @hide
|
||||
@@ -62,7 +62,7 @@ public class ApplicationSuggestion implements Parcelable {
|
||||
ParcelInfo parcelInfo = Concierge.receiveParcel(in);
|
||||
int parcelableVersion = parcelInfo.getParcelVersion();
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.APRICOT) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.APRICOT) {
|
||||
mName = in.readString();
|
||||
mPackage = in.readString();
|
||||
mDownloadUri = in.readParcelable(Uri.class.getClassLoader());
|
||||
|
||||
@@ -14,11 +14,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app.suggest;
|
||||
package lineageos.app.suggest;
|
||||
|
||||
import android.content.Intent;
|
||||
|
||||
import cyanogenmod.app.suggest.ApplicationSuggestion;
|
||||
import lineageos.app.suggest.ApplicationSuggestion;
|
||||
|
||||
/**
|
||||
* @hide
|
||||
|
||||
@@ -14,11 +14,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.app.suggest;
|
||||
package lineageos.app.suggest;
|
||||
|
||||
import android.content.Intent;
|
||||
|
||||
import cyanogenmod.app.suggest.ApplicationSuggestion;
|
||||
import lineageos.app.suggest.ApplicationSuggestion;
|
||||
|
||||
/**
|
||||
* @hide
|
||||
|
||||
@@ -15,12 +15,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.content;
|
||||
package lineageos.content;
|
||||
|
||||
import android.Manifest;
|
||||
|
||||
/**
|
||||
* CyanogenMod specific intent definition class.
|
||||
* LineageOS specific intent definition class.
|
||||
*/
|
||||
public class Intent {
|
||||
|
||||
@@ -32,7 +32,7 @@ public class Intent {
|
||||
* @hide
|
||||
*/
|
||||
public static final String ACTION_RECENTS_LONG_PRESS =
|
||||
"cyanogenmod.intent.action.RECENTS_LONG_PRESS";
|
||||
"lineageos.intent.action.RECENTS_LONG_PRESS";
|
||||
|
||||
/**
|
||||
* This field is part of the intent {@link #ACTION_RECENTS_LONG_PRESS}.
|
||||
@@ -41,32 +41,32 @@ public class Intent {
|
||||
* @hide
|
||||
*/
|
||||
public static final String EXTRA_RECENTS_LONG_PRESS_RELEASE =
|
||||
"cyanogenmod.intent.extra.RECENTS_LONG_PRESS_RELEASE";
|
||||
"lineageos.intent.extra.RECENTS_LONG_PRESS_RELEASE";
|
||||
|
||||
/**
|
||||
* Intent filter to update protected app component's settings
|
||||
*/
|
||||
public static final String ACTION_PROTECTED = "cyanogenmod.intent.action.PACKAGE_PROTECTED";
|
||||
public static final String ACTION_PROTECTED = "lineageos.intent.action.PACKAGE_PROTECTED";
|
||||
|
||||
/**
|
||||
* Intent filter to notify change in state of protected application.
|
||||
*/
|
||||
public static final String ACTION_PROTECTED_CHANGED =
|
||||
"cyanogenmod.intent.action.PROTECTED_COMPONENT_UPDATE";
|
||||
"lineageos.intent.action.PROTECTED_COMPONENT_UPDATE";
|
||||
|
||||
/**
|
||||
* This field is part of the intent {@link #ACTION_PROTECTED_CHANGED}.
|
||||
* Intent extra field for the state of protected application
|
||||
*/
|
||||
public static final String EXTRA_PROTECTED_STATE =
|
||||
"cyanogenmod.intent.extra.PACKAGE_PROTECTED_STATE";
|
||||
"lineageos.intent.extra.PACKAGE_PROTECTED_STATE";
|
||||
|
||||
/**
|
||||
* This field is part of the intent {@link #ACTION_PROTECTED_CHANGED}.
|
||||
* Intent extra field to indicate protected component value
|
||||
*/
|
||||
public static final String EXTRA_PROTECTED_COMPONENTS =
|
||||
"cyanogenmod.intent.extra.PACKAGE_PROTECTED_COMPONENTS";
|
||||
"lineageos.intent.extra.PACKAGE_PROTECTED_COMPONENTS";
|
||||
|
||||
/**
|
||||
* Broadcast action: notify the system that the user has performed a gesture on the screen
|
||||
@@ -75,57 +75,57 @@ public class Intent {
|
||||
* @hide
|
||||
*/
|
||||
public static final String ACTION_SCREEN_CAMERA_GESTURE =
|
||||
"cyanogenmod.intent.action.SCREEN_CAMERA_GESTURE";
|
||||
"lineageos.intent.action.SCREEN_CAMERA_GESTURE";
|
||||
|
||||
/**
|
||||
* Broadcast action: perform any initialization required for CMHW services.
|
||||
* Broadcast action: perform any initialization required for LineageHW services.
|
||||
* Runs when the service receives the signal the device has booted, but
|
||||
* should happen before {@link android.content.Intent#ACTION_BOOT_COMPLETED}.
|
||||
*
|
||||
* Requires {@link cyanogenmod.platform.Manifest.permission#HARDWARE_ABSTRACTION_ACCESS}.
|
||||
* Requires {@link lineageos.platform.Manifest.permission#HARDWARE_ABSTRACTION_ACCESS}.
|
||||
* @hide
|
||||
*/
|
||||
public static final String ACTION_INITIALIZE_CM_HARDWARE =
|
||||
"cyanogenmod.intent.action.INITIALIZE_CM_HARDWARE";
|
||||
public static final String ACTION_INITIALIZE_LINEAGE_HARDWARE =
|
||||
"lineageos.intent.action.INITIALIZE_LINEAGE_HARDWARE";
|
||||
|
||||
/**
|
||||
* Broadcast Action: Indicate that an unrecoverable error happened during app launch.
|
||||
* Could indicate that curently applied theme is malicious.
|
||||
* @hide
|
||||
*/
|
||||
public static final String ACTION_APP_FAILURE = "cyanogenmod.intent.action.APP_FAILURE";
|
||||
public static final String ACTION_APP_FAILURE = "lineageos.intent.action.APP_FAILURE";
|
||||
|
||||
/**
|
||||
* Used to indicate that a theme package has been installed or un-installed.
|
||||
*/
|
||||
public static final String CATEGORY_THEME_PACKAGE_INSTALLED_STATE_CHANGE =
|
||||
"cyanogenmod.intent.category.THEME_PACKAGE_INSTALL_STATE_CHANGE";
|
||||
"lineageos.intent.category.THEME_PACKAGE_INSTALL_STATE_CHANGE";
|
||||
|
||||
/**
|
||||
* Action sent from the provider when a theme has been fully installed. Fully installed
|
||||
* means that the apk was installed by PackageManager and the theme resources were
|
||||
* processed and cached by {@link org.cyanogenmod.platform.internal.ThemeManagerService}
|
||||
* Requires the {@link cyanogenmod.platform.Manifest.permission#READ_THEMES} permission to
|
||||
* processed and cached by {@link org.lineageos.platform.internal.ThemeManagerService}
|
||||
* Requires the {@link lineageos.platform.Manifest.permission#READ_THEMES} permission to
|
||||
* receive this broadcast.
|
||||
*/
|
||||
public static final String ACTION_THEME_INSTALLED =
|
||||
"cyanogenmod.intent.action.THEME_INSTALLED";
|
||||
"lineageos.intent.action.THEME_INSTALLED";
|
||||
|
||||
/**
|
||||
* Action sent from the provider when a theme has been updated.
|
||||
* Requires the {@link cyanogenmod.platform.Manifest.permission#READ_THEMES} permission to
|
||||
* Requires the {@link lineageos.platform.Manifest.permission#READ_THEMES} permission to
|
||||
* receive this broadcast.
|
||||
*/
|
||||
public static final String ACTION_THEME_UPDATED =
|
||||
"cyanogenmod.intent.action.THEME_UPDATED";
|
||||
"lineageos.intent.action.THEME_UPDATED";
|
||||
|
||||
/**
|
||||
* Action sent from the provider when a theme has been removed.
|
||||
* Requires the {@link cyanogenmod.platform.Manifest.permission#READ_THEMES} permission to
|
||||
* Requires the {@link lineageos.platform.Manifest.permission#READ_THEMES} permission to
|
||||
* receive this broadcast.
|
||||
*/
|
||||
public static final String ACTION_THEME_REMOVED =
|
||||
"cyanogenmod.intent.action.THEME_REMOVED";
|
||||
"lineageos.intent.action.THEME_REMOVED";
|
||||
|
||||
/**
|
||||
* Uri scheme used to broadcast the theme's package name when broadcasting
|
||||
@@ -139,14 +139,14 @@ public class Intent {
|
||||
* @hide
|
||||
*/
|
||||
public static final String ACTION_OPEN_LIVE_LOCKSCREEN_SETTINGS =
|
||||
"cyanogenmod.intent.action.OPEN_LIVE_LOCKSCREEN_SETTINGS";
|
||||
"lineageos.intent.action.OPEN_LIVE_LOCKSCREEN_SETTINGS";
|
||||
|
||||
/**
|
||||
* Broadcast action: lid state changed
|
||||
* @hide
|
||||
*/
|
||||
public static final String ACTION_LID_STATE_CHANGED =
|
||||
"cyanogenmod.intent.action.LID_STATE_CHANGED";
|
||||
"lineageos.intent.action.LID_STATE_CHANGED";
|
||||
|
||||
/**
|
||||
* This field is part of the intent {@link #ACTION_LID_STATE_CHANGED}.
|
||||
@@ -154,5 +154,5 @@ public class Intent {
|
||||
* @hide
|
||||
*/
|
||||
public static final String EXTRA_LID_STATE =
|
||||
"cyanogenmod.intent.extra.LID_STATE";
|
||||
"lineageos.intent.extra.LID_STATE";
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.Application;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.Application;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.app.Service;
|
||||
import android.content.Context;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.graphics.Rect;
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.os.Bundle;
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.content.Intent;
|
||||
|
||||
|
||||
@@ -14,11 +14,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.graphics.Rect;
|
||||
|
||||
import cyanogenmod.externalviews.IKeyguardExternalViewCallbacks;
|
||||
import lineageos.externalviews.IKeyguardExternalViewCallbacks;
|
||||
|
||||
/** @hide */
|
||||
interface IKeyguardExternalViewProvider
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.app.Application;
|
||||
@@ -37,7 +37,7 @@ import java.util.LinkedList;
|
||||
|
||||
/**
|
||||
* This class provides a placeholder view for hosting an external view, provided by a
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}, within the lock screen.
|
||||
* {@link lineageos.externalviews.KeyguardExternalViewProviderService}, within the lock screen.
|
||||
*
|
||||
* <p>This class is intended to only be used within the SystemUi process.</p>
|
||||
* @hide
|
||||
@@ -54,13 +54,13 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
|
||||
/**
|
||||
* Category defining an activity to call to request permissions that a
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService} will need. Apps that
|
||||
* provide a {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService} should
|
||||
* {@link lineageos.externalviews.KeyguardExternalViewProviderService} will need. Apps that
|
||||
* provide a {@link lineageos.externalviews.KeyguardExternalViewProviderService} should
|
||||
* check that they have the required permission before making any method calls that would
|
||||
* require a dangerous permission to be granted.
|
||||
*/
|
||||
public static final String CATEGORY_KEYGUARD_GRANT_PERMISSION
|
||||
= "org.cyanogenmod.intent.category.KEYGUARD_GRANT_PERMISSION";
|
||||
= "org.lineageos.intent.category.KEYGUARD_GRANT_PERMISSION";
|
||||
|
||||
private LinkedList<Runnable> mQueue = new LinkedList<Runnable>();
|
||||
|
||||
@@ -91,7 +91,7 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
* @param context
|
||||
* @param attributeSet
|
||||
* @param componentName The component name for the
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}
|
||||
* {@link lineageos.externalviews.KeyguardExternalViewProviderService}
|
||||
* that will be bound to create the external view.
|
||||
*/
|
||||
public KeyguardExternalView(Context context, AttributeSet attributeSet, ComponentName componentName) {
|
||||
@@ -284,10 +284,10 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the component of the {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}
|
||||
* Sets the component of the {@link lineageos.externalviews.KeyguardExternalViewProviderService}
|
||||
* to be used for this ExternalView. If a provider is already connected to this view, it is
|
||||
* first unbound before binding to the new provider.
|
||||
* @param componentName The {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}
|
||||
* @param componentName The {@link lineageos.externalviews.KeyguardExternalViewProviderService}
|
||||
* to bind to.
|
||||
*/
|
||||
public void setProviderComponent(ComponentName componentName) {
|
||||
@@ -401,7 +401,7 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
|
||||
/**
|
||||
* External views provided by a
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService} can be either
|
||||
* {@link lineageos.externalviews.KeyguardExternalViewProviderService} can be either
|
||||
* interactive or non-interactive.
|
||||
*
|
||||
* <p>A non-interactive component does not receive any input events and functions similar to a
|
||||
@@ -417,9 +417,9 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers a {@link cyanogenmod.externalviews.KeyguardExternalView.KeyguardExternalViewCallbacks}
|
||||
* Registers a {@link lineageos.externalviews.KeyguardExternalView.KeyguardExternalViewCallbacks}
|
||||
* for receiving events from the
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}
|
||||
* {@link lineageos.externalviews.KeyguardExternalViewProviderService}
|
||||
* @param callback The callback to register
|
||||
*/
|
||||
public void registerKeyguardExternalViewCallback(KeyguardExternalViewCallbacks callback) {
|
||||
@@ -428,7 +428,7 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
|
||||
/**
|
||||
* Unregister a previously registered
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalView.KeyguardExternalViewCallbacks}
|
||||
* {@link lineageos.externalviews.KeyguardExternalView.KeyguardExternalViewCallbacks}
|
||||
* @param callback The callback to unregister
|
||||
*/
|
||||
public void unregisterKeyguardExternalViewCallback(KeyguardExternalViewCallbacks callback) {
|
||||
@@ -439,9 +439,9 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
}
|
||||
|
||||
/**
|
||||
* Registers a {@link cyanogenmod.externalviews.KeyguardExternalView.OnWindowAttachmentChangedListener}
|
||||
* Registers a {@link lineageos.externalviews.KeyguardExternalView.OnWindowAttachmentChangedListener}
|
||||
* for receiving events from the
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}
|
||||
* {@link lineageos.externalviews.KeyguardExternalViewProviderService}
|
||||
* @param listener The callback to register
|
||||
*
|
||||
* @hide
|
||||
@@ -453,7 +453,7 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
|
||||
/**
|
||||
* Unregister a previously registered
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalView.OnWindowAttachmentChangedListener}
|
||||
* {@link lineageos.externalviews.KeyguardExternalView.OnWindowAttachmentChangedListener}
|
||||
* @param listener The callback to unregister
|
||||
*
|
||||
* @hide
|
||||
@@ -467,9 +467,9 @@ public class KeyguardExternalView extends View implements ViewTreeObserver.OnPre
|
||||
}
|
||||
|
||||
/**
|
||||
* Callback interface for a {@link cyanogenmod.externalviews.KeyguardExternalViewProviderService}
|
||||
* Callback interface for a {@link lineageos.externalviews.KeyguardExternalViewProviderService}
|
||||
* to send events to the host's registered
|
||||
* {@link cyanogenmod.externalviews.KeyguardExternalView.KeyguardExternalViewCallbacks}
|
||||
* {@link lineageos.externalviews.KeyguardExternalView.KeyguardExternalViewCallbacks}
|
||||
*/
|
||||
public interface KeyguardExternalViewCallbacks {
|
||||
boolean requestDismiss();
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.externalviews;
|
||||
package lineageos.externalviews;
|
||||
|
||||
import android.app.Service;
|
||||
import android.content.Context;
|
||||
@@ -50,7 +50,7 @@ import java.util.concurrent.FutureTask;
|
||||
* wish to provide a view to be displayed within the lock screen should extend this service.
|
||||
*
|
||||
* <p>Applications extending this class should include the
|
||||
* {@link cyanogenmod.platform.Manifest.permission#THIRD_PARTY_KEYGUARD} permission in their
|
||||
* {@link lineageos.platform.Manifest.permission#THIRD_PARTY_KEYGUARD} permission in their
|
||||
* manifest</p>
|
||||
|
||||
* <p>Applications extending this class should also extend
|
||||
@@ -68,12 +68,12 @@ public abstract class KeyguardExternalViewProviderService extends Service {
|
||||
*
|
||||
* <p>{@code
|
||||
* <intent-filter>
|
||||
* <action android:name="cyanogenmod.externalviews.KeyguardExternalViewProviderService"/>
|
||||
* <action android:name="lineageos.externalviews.KeyguardExternalViewProviderService"/>
|
||||
* </intent-filter>
|
||||
*}</p>
|
||||
*/
|
||||
public static final String SERVICE_INTERFACE =
|
||||
"cyanogenmod.externalviews.KeyguardExternalViewProviderService";
|
||||
"lineageos.externalviews.KeyguardExternalViewProviderService";
|
||||
|
||||
/**
|
||||
* Name under which an external keyguard view publishes information about itself.
|
||||
@@ -81,7 +81,7 @@ public abstract class KeyguardExternalViewProviderService extends Service {
|
||||
* a <code><lockscreen></code>
|
||||
* tag.
|
||||
*/
|
||||
public static final String META_DATA = "cyanogenmod.externalviews.keyguard";
|
||||
public static final String META_DATA = "lineageos.externalviews.keyguard";
|
||||
|
||||
private WindowManager mWindowManager;
|
||||
private final Handler mHandler = new Handler();
|
||||
@@ -595,7 +595,7 @@ public abstract class KeyguardExternalViewProviderService extends Service {
|
||||
* attention. The user will still be able to bring the notifications back into view by
|
||||
* sliding down from the status bar.
|
||||
* Calling this method has no effect for non-interactive components.</p>
|
||||
* @deprecated As of SDK version {@link cyanogenmod.os.Build.CM_VERSION_CODES#ELDERBERRY}
|
||||
* @deprecated As of SDK version {@link lineageos.os.Build.LINEAGE_VERSION_CODES#ELDERBERRY}
|
||||
* this does nothing.
|
||||
*/
|
||||
@Deprecated
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
parcelable DisplayMode;
|
||||
|
||||
@@ -14,14 +14,14 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
/**
|
||||
* Display Modes API
|
||||
@@ -55,7 +55,7 @@ public class DisplayMode implements Parcelable {
|
||||
int tmpId = -1;
|
||||
String tmpName = null;
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
tmpId = parcel.readInt();
|
||||
if (parcel.readInt() != 0) {
|
||||
tmpName = parcel.readString();
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
parcelable HSIC;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import android.graphics.Color;
|
||||
import android.os.Parcel;
|
||||
|
||||
@@ -15,15 +15,15 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import cyanogenmod.hardware.DisplayMode;
|
||||
import cyanogenmod.hardware.HSIC;
|
||||
import cyanogenmod.hardware.IThermalListenerCallback;
|
||||
import cyanogenmod.hardware.TouchscreenGesture;
|
||||
import lineageos.hardware.DisplayMode;
|
||||
import lineageos.hardware.HSIC;
|
||||
import lineageos.hardware.IThermalListenerCallback;
|
||||
import lineageos.hardware.TouchscreenGesture;
|
||||
|
||||
/** @hide */
|
||||
interface ICMHardwareService {
|
||||
interface ILineageHardwareService {
|
||||
|
||||
int getSupportedFeatures();
|
||||
boolean get(int feature);
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import cyanogenmod.hardware.HSIC;
|
||||
import cyanogenmod.hardware.LiveDisplayConfig;
|
||||
import lineageos.hardware.HSIC;
|
||||
import lineageos.hardware.LiveDisplayConfig;
|
||||
|
||||
/** @hide */
|
||||
interface ILiveDisplayService {
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
interface IThermalListenerCallback {
|
||||
void onThermalChanged(int state);
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.IBinder;
|
||||
@@ -25,8 +25,8 @@ import android.util.Range;
|
||||
|
||||
import com.android.internal.annotations.VisibleForTesting;
|
||||
|
||||
import cyanogenmod.app.CMContextConstants;
|
||||
import cyanogenmod.hardware.HSIC;
|
||||
import lineageos.app.LineageContextConstants;
|
||||
import lineageos.hardware.HSIC;
|
||||
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.lang.IllegalArgumentException;
|
||||
@@ -36,17 +36,17 @@ import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Manages access to CyanogenMod hardware extensions
|
||||
* Manages access to LineageOS hardware extensions
|
||||
*
|
||||
* <p>
|
||||
* This manager requires the HARDWARE_ABSTRACTION_ACCESS permission.
|
||||
* <p>
|
||||
* To get the instance of this class, utilize CMHardwareManager#getInstance(Context context)
|
||||
* To get the instance of this class, utilize LineageHardwareManager#getInstance(Context context)
|
||||
*/
|
||||
public final class CMHardwareManager {
|
||||
private static final String TAG = "CMHardwareManager";
|
||||
public final class LineageHardwareManager {
|
||||
private static final String TAG = "LineageHardwareManager";
|
||||
|
||||
private static ICMHardwareService sService;
|
||||
private static ILineageHardwareService sService;
|
||||
|
||||
private Context mContext;
|
||||
|
||||
@@ -113,7 +113,7 @@ public final class CMHardwareManager {
|
||||
/**
|
||||
* Double-tap the touch panel to wake up the device
|
||||
*
|
||||
* @deprecated This functionality is replaced by AOSP's implementation as of CM 13.0.
|
||||
* @deprecated This functionality is replaced by AOSP's implementation as of Lineage 13.0.
|
||||
*/
|
||||
@Deprecated
|
||||
@VisibleForTesting
|
||||
@@ -190,12 +190,12 @@ public final class CMHardwareManager {
|
||||
FEATURE_THERMAL_MONITOR
|
||||
);
|
||||
|
||||
private static CMHardwareManager sCMHardwareManagerInstance;
|
||||
private static LineageHardwareManager sLineageHardwareManagerInstance;
|
||||
|
||||
/**
|
||||
* @hide to prevent subclassing from outside of the framework
|
||||
*/
|
||||
private CMHardwareManager(Context context) {
|
||||
private LineageHardwareManager(Context context) {
|
||||
Context appContext = context.getApplicationContext();
|
||||
if (appContext != null) {
|
||||
mContext = appContext;
|
||||
@@ -205,33 +205,33 @@ public final class CMHardwareManager {
|
||||
sService = getService();
|
||||
|
||||
if (context.getPackageManager().hasSystemFeature(
|
||||
CMContextConstants.Features.HARDWARE_ABSTRACTION) && !checkService()) {
|
||||
Log.wtf(TAG, "Unable to get CMHardwareService. The service either" +
|
||||
LineageContextConstants.Features.HARDWARE_ABSTRACTION) && !checkService()) {
|
||||
Log.wtf(TAG, "Unable to get LineageHardwareService. The service either" +
|
||||
" crashed, was not started, or the interface has been called to early in" +
|
||||
" SystemServer init");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get or create an instance of the {@link cyanogenmod.hardware.CMHardwareManager}
|
||||
* Get or create an instance of the {@link lineageos.hardware.LineageHardwareManager}
|
||||
* @param context
|
||||
* @return {@link CMHardwareManager}
|
||||
* @return {@link LineageHardwareManager}
|
||||
*/
|
||||
public static CMHardwareManager getInstance(Context context) {
|
||||
if (sCMHardwareManagerInstance == null) {
|
||||
sCMHardwareManagerInstance = new CMHardwareManager(context);
|
||||
public static LineageHardwareManager getInstance(Context context) {
|
||||
if (sLineageHardwareManagerInstance == null) {
|
||||
sLineageHardwareManagerInstance = new LineageHardwareManager(context);
|
||||
}
|
||||
return sCMHardwareManagerInstance;
|
||||
return sLineageHardwareManagerInstance;
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static ICMHardwareService getService() {
|
||||
public static ILineageHardwareService getService() {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_HARDWARE_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_HARDWARE_SERVICE);
|
||||
if (b != null) {
|
||||
sService = ICMHardwareService.Stub.asInterface(b);
|
||||
sService = ILineageHardwareService.Stub.asInterface(b);
|
||||
return sService;
|
||||
}
|
||||
return null;
|
||||
@@ -251,9 +251,9 @@ public final class CMHardwareManager {
|
||||
}
|
||||
|
||||
/**
|
||||
* Determine if a CM Hardware feature is supported on this device
|
||||
* Determine if a Lineage Hardware feature is supported on this device
|
||||
*
|
||||
* @param feature The CM Hardware feature to query
|
||||
* @param feature The Lineage Hardware feature to query
|
||||
*
|
||||
* @return true if the feature is supported, false otherwise.
|
||||
*/
|
||||
@@ -286,7 +286,7 @@ public final class CMHardwareManager {
|
||||
*
|
||||
* Only used for features which have simple enable/disable controls.
|
||||
*
|
||||
* @param feature the CM Hardware feature to query
|
||||
* @param feature the Lineage Hardware feature to query
|
||||
*
|
||||
* @return true if the feature is enabled, false otherwise.
|
||||
*/
|
||||
@@ -309,7 +309,7 @@ public final class CMHardwareManager {
|
||||
*
|
||||
* Only used for features which have simple enable/disable controls.
|
||||
*
|
||||
* @param feature the CM Hardware feature to set
|
||||
* @param feature the Lineage Hardware feature to set
|
||||
* @param enable true to enable, false to disale
|
||||
*
|
||||
* @return true if the feature is enabled, false otherwise.
|
||||
@@ -1003,14 +1003,14 @@ public final class CMHardwareManager {
|
||||
*/
|
||||
private boolean checkService() {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMHardwareManagerService");
|
||||
Log.w(TAG, "not connected to LineageHardwareManagerService");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return current thermal {@link cyanogenmod.hardware.ThermalListenerCallback.State}
|
||||
* @return current thermal {@link lineageos.hardware.ThermalListenerCallback.State}
|
||||
*/
|
||||
public int getThermalState() {
|
||||
try {
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
parcelable LiveDisplayConfig;
|
||||
|
||||
@@ -13,14 +13,14 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import static cyanogenmod.hardware.LiveDisplayManager.FEATURE_COLOR_BALANCE;
|
||||
import static cyanogenmod.hardware.LiveDisplayManager.FEATURE_FIRST;
|
||||
import static cyanogenmod.hardware.LiveDisplayManager.FEATURE_LAST;
|
||||
import static cyanogenmod.hardware.LiveDisplayManager.MODE_FIRST;
|
||||
import static cyanogenmod.hardware.LiveDisplayManager.MODE_LAST;
|
||||
import static cyanogenmod.hardware.LiveDisplayManager.MODE_OFF;
|
||||
import static lineageos.hardware.LiveDisplayManager.FEATURE_COLOR_BALANCE;
|
||||
import static lineageos.hardware.LiveDisplayManager.FEATURE_FIRST;
|
||||
import static lineageos.hardware.LiveDisplayManager.FEATURE_LAST;
|
||||
import static lineageos.hardware.LiveDisplayManager.MODE_FIRST;
|
||||
import static lineageos.hardware.LiveDisplayManager.MODE_LAST;
|
||||
import static lineageos.hardware.LiveDisplayManager.MODE_OFF;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
@@ -30,9 +30,9 @@ import java.util.Arrays;
|
||||
import java.util.BitSet;
|
||||
import java.util.List;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
/**
|
||||
* Holder class for LiveDisplay static configuration.
|
||||
@@ -112,7 +112,7 @@ public class LiveDisplayConfig implements Parcelable {
|
||||
int maxColorBalance = 0;
|
||||
float[] paRanges = new float[10];
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.FIG) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.FIG) {
|
||||
capabilities = parcel.readLong();
|
||||
defaultMode = parcel.readInt();
|
||||
defaultDayTemperature = parcel.readInt();
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.IBinder;
|
||||
@@ -26,7 +26,7 @@ import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import cyanogenmod.app.CMContextConstants;
|
||||
import lineageos.app.LineageContextConstants;
|
||||
|
||||
/**
|
||||
* LiveDisplay is an advanced set of features for improving
|
||||
@@ -34,7 +34,7 @@ import cyanogenmod.app.CMContextConstants;
|
||||
*
|
||||
* The backend service is constructed with a set of LiveDisplayFeatures
|
||||
* which provide capabilities such as outdoor mode, night mode,
|
||||
* and calibration. It interacts with CMHardwareService to relay
|
||||
* and calibration. It interacts with LineageHardwareService to relay
|
||||
* changes down to the lower layers.
|
||||
*
|
||||
* Multiple adaptive modes are supported, and various hardware
|
||||
@@ -151,7 +151,7 @@ public class LiveDisplayManager {
|
||||
sService = getService();
|
||||
|
||||
if (!context.getPackageManager().hasSystemFeature(
|
||||
CMContextConstants.Features.LIVEDISPLAY) || !checkService()) {
|
||||
LineageContextConstants.Features.LIVEDISPLAY) || !checkService()) {
|
||||
Log.wtf(TAG, "Unable to get LiveDisplayService. The service either" +
|
||||
" crashed, was not started, or the interface has been called to early in" +
|
||||
" SystemServer init");
|
||||
@@ -168,7 +168,7 @@ public class LiveDisplayManager {
|
||||
}
|
||||
|
||||
/**
|
||||
* Get or create an instance of the {@link cyanogenmod.hardware.LiveDisplayManager}
|
||||
* Get or create an instance of the {@link lineageos.hardware.LiveDisplayManager}
|
||||
* @param context
|
||||
* @return {@link LiveDisplayManager}
|
||||
*/
|
||||
@@ -184,7 +184,7 @@ public class LiveDisplayManager {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_LIVEDISPLAY_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_LIVEDISPLAY_SERVICE);
|
||||
if (b != null) {
|
||||
sService = ILiveDisplayService.Stub.asInterface(b);
|
||||
return sService;
|
||||
@@ -197,7 +197,7 @@ public class LiveDisplayManager {
|
||||
*/
|
||||
private boolean checkService() {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMHardwareManagerService");
|
||||
Log.w(TAG, "not connected to LineageHardwareManagerService");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
/**
|
||||
* Callback class to register for thermal state changes
|
||||
|
||||
@@ -15,6 +15,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
parcelable TouchscreenGesture;
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.hardware;
|
||||
package lineageos.hardware;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.media;
|
||||
package lineageos.media;
|
||||
|
||||
parcelable AudioSessionInfo;
|
||||
|
||||
@@ -14,16 +14,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.media;
|
||||
package lineageos.media;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
/**
|
||||
* AudioSessionInfo represents a single instance of an audio session.
|
||||
@@ -33,8 +33,8 @@ import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
* an application may create audio effects on the output stream.
|
||||
*
|
||||
* A list of global audio sessions can be obtained by calling
|
||||
* listAudioSessions() via {@link CMAudioManager}, or a component can listen
|
||||
* for the {@link CMAudioManager#ACTION_AUDIO_SESSIONS_CHANGED} broadcast.
|
||||
* listAudioSessions() via {@link LineageAudioManager}, or a component can listen
|
||||
* for the {@link LineageAudioManager#ACTION_AUDIO_SESSIONS_CHANGED} broadcast.
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
@@ -81,7 +81,7 @@ public final class AudioSessionInfo implements Parcelable {
|
||||
mChannelMask = in.readInt();
|
||||
mUid = in.readInt();
|
||||
|
||||
if (parcelableVersion > Build.CM_VERSION_CODES.FIG) {
|
||||
if (parcelableVersion > Build.LINEAGE_VERSION_CODES.FIG) {
|
||||
// next-gen mind-altering shit goes here
|
||||
}
|
||||
|
||||
|
||||
@@ -14,12 +14,12 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.media;
|
||||
package lineageos.media;
|
||||
|
||||
import cyanogenmod.media.AudioSessionInfo;
|
||||
import lineageos.media.AudioSessionInfo;
|
||||
|
||||
/** @hide */
|
||||
interface ICMAudioService {
|
||||
interface ILineageAudioService {
|
||||
|
||||
List<AudioSessionInfo> listAudioSessions(int streamType);
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.media;
|
||||
package lineageos.media;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.IBinder;
|
||||
@@ -25,11 +25,11 @@ import android.util.Log;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
import cyanogenmod.app.CMContextConstants;
|
||||
import lineageos.app.LineageContextConstants;
|
||||
|
||||
/**
|
||||
* Manager for extended audio system capabilities provided by
|
||||
* CyanogenMod.
|
||||
* LineageOS.
|
||||
*
|
||||
* Currently, this API provides an application the ability to
|
||||
* query active global audio sessions, and receive broadcasts
|
||||
@@ -38,7 +38,7 @@ import cyanogenmod.app.CMContextConstants;
|
||||
* Applications wishing to receive audio session information
|
||||
* should register for the {@link ACTION_AUDIO_SESSIONS_CHANGED}
|
||||
* broadcast. This broadcast requires an application to hold the
|
||||
* {@link cyanogenmod.permission.OBSERVE_AUDIO_SESSIONS}
|
||||
* {@link lineageos.permission.OBSERVE_AUDIO_SESSIONS}
|
||||
* permission. When receiving the broadcast, {@link EXTRA_SESSION_INFO}
|
||||
* will hold the {@link AudioSessionInfo} object associated
|
||||
* with the session. {@link EXTRA_SESSION_ADDED} will hold
|
||||
@@ -55,15 +55,15 @@ import cyanogenmod.app.CMContextConstants;
|
||||
*
|
||||
* @hide
|
||||
*/
|
||||
public final class CMAudioManager {
|
||||
public final class LineageAudioManager {
|
||||
|
||||
private static final String TAG = "CMAudioManager";
|
||||
private static final String TAG = "LineageAudioManager";
|
||||
|
||||
/**
|
||||
* Broadcast sent when audio session are added and removed.
|
||||
*/
|
||||
public static final String ACTION_AUDIO_SESSIONS_CHANGED =
|
||||
"cyanogenmod.intent.action.ACTION_AUDIO_SESSIONS_CHANGED";
|
||||
"lineageos.intent.action.ACTION_AUDIO_SESSIONS_CHANGED";
|
||||
|
||||
/**
|
||||
* Extra containing {@link AudioSessionInfo}
|
||||
@@ -77,13 +77,13 @@ public final class CMAudioManager {
|
||||
|
||||
private Context mContext;
|
||||
|
||||
private static CMAudioManager sInstance;
|
||||
private static ICMAudioService sService;
|
||||
private static LineageAudioManager sInstance;
|
||||
private static ILineageAudioService sService;
|
||||
|
||||
/**
|
||||
* @hide to prevent subclassing from outside of the framework
|
||||
*/
|
||||
private CMAudioManager(Context context) {
|
||||
private LineageAudioManager(Context context) {
|
||||
Context appContext = context.getApplicationContext();
|
||||
if (appContext != null) {
|
||||
mContext = appContext;
|
||||
@@ -94,33 +94,33 @@ public final class CMAudioManager {
|
||||
sService = getService();
|
||||
|
||||
if (!context.getPackageManager().hasSystemFeature(
|
||||
CMContextConstants.Features.AUDIO) || !checkService()) {
|
||||
Log.wtf(TAG, "Unable to get CMAudioService. The service either" +
|
||||
LineageContextConstants.Features.AUDIO) || !checkService()) {
|
||||
Log.wtf(TAG, "Unable to get LineageAudioService. The service either" +
|
||||
" crashed, was not started, or the interface has been called to early in" +
|
||||
" SystemServer init");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Get or create an instance of the {@link cyanogenmod.media.CMAudioManager}
|
||||
* Get or create an instance of the {@link lineageos.media.LineageAudioManager}
|
||||
* @param context
|
||||
* @return {@link CMAudioManager}
|
||||
* @return {@link LineageAudioManager}
|
||||
*/
|
||||
public synchronized static CMAudioManager getInstance(Context context) {
|
||||
public synchronized static LineageAudioManager getInstance(Context context) {
|
||||
if (sInstance == null) {
|
||||
sInstance = new CMAudioManager(context);
|
||||
sInstance = new LineageAudioManager(context);
|
||||
}
|
||||
return sInstance;
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static ICMAudioService getService() {
|
||||
public static ILineageAudioService getService() {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_AUDIO_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_AUDIO_SERVICE);
|
||||
if (b != null) {
|
||||
sService = ICMAudioService.Stub.asInterface(b);
|
||||
sService = ILineageAudioService.Stub.asInterface(b);
|
||||
return sService;
|
||||
}
|
||||
return null;
|
||||
@@ -131,7 +131,7 @@ public final class CMAudioManager {
|
||||
*/
|
||||
private boolean checkService() {
|
||||
if (sService == null) {
|
||||
Log.w(TAG, "not connected to CMAudioService");
|
||||
Log.w(TAG, "not connected to LineageAudioService");
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.media;
|
||||
package lineageos.media;
|
||||
|
||||
public class MediaRecorder {
|
||||
/**
|
||||
@@ -47,7 +47,7 @@ public class MediaRecorder {
|
||||
*/
|
||||
//@SdkConstant(SdkConstantType.BROADCAST_INTENT_ACTION)
|
||||
public static final String ACTION_HOTWORD_INPUT_CHANGED
|
||||
= "com.cyanogenmod.intent.action.HOTWORD_INPUT_CHANGED";
|
||||
= "org.lineageos.intent.action.HOTWORD_INPUT_CHANGED";
|
||||
|
||||
/**
|
||||
* Extra for {@link #ACTION_HOTWORD_INPUT_CHANGED} that provides the package name of the
|
||||
@@ -55,7 +55,7 @@ public class MediaRecorder {
|
||||
* purposes.
|
||||
*/
|
||||
public static final String EXTRA_CURRENT_PACKAGE_NAME =
|
||||
"com.cyanogenmod.intent.extra.CURRENT_PACKAGE_NAME";
|
||||
"org.lineageos.intent.extra.CURRENT_PACKAGE_NAME";
|
||||
|
||||
/**
|
||||
* Extra for {@link #ACTION_HOTWORD_INPUT_CHANGED} that provides the state of
|
||||
@@ -63,7 +63,7 @@ public class MediaRecorder {
|
||||
* @hide
|
||||
*/
|
||||
public static final String EXTRA_HOTWORD_INPUT_STATE =
|
||||
"com.cyanogenmod.intent.extra.HOTWORD_INPUT_STATE";
|
||||
"org.lineageos.intent.extra.HOTWORD_INPUT_STATE";
|
||||
|
||||
|
||||
public static class AudioSource {
|
||||
@@ -76,7 +76,7 @@ public class MediaRecorder {
|
||||
* always-on software hotword detection, while gracefully giving in to any other application
|
||||
* that might want to read from the microphone.
|
||||
* </p>
|
||||
* You must hold {@link cyanogenmod.media.MediaRecorder#CAPTURE_AUDIO_HOTWORD_PERMISSION}
|
||||
* You must hold {@link lineageos.media.MediaRecorder#CAPTURE_AUDIO_HOTWORD_PERMISSION}
|
||||
* to use this audio source.
|
||||
*/
|
||||
public static final int HOTWORD = 1999;
|
||||
|
||||
@@ -14,53 +14,53 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.os;
|
||||
package lineageos.os;
|
||||
|
||||
import android.os.SystemProperties;
|
||||
import android.text.TextUtils;
|
||||
import android.util.SparseArray;
|
||||
|
||||
/**
|
||||
* Information about the current CyanogenMod build, extracted from system properties.
|
||||
* Information about the current LineageOS build, extracted from system properties.
|
||||
*/
|
||||
public class Build {
|
||||
/** Value used for when a build property is unknown. */
|
||||
public static final String UNKNOWN = "unknown";
|
||||
|
||||
/** A build ID utilized to distinguish cyanogenmod versions */
|
||||
public static final String CYANOGENMOD_VERSION = getString("ro.cm.version");
|
||||
/** A build ID utilized to distinguish lineageos versions */
|
||||
public static final String LINEAGEOS_VERSION = getString("ro.lineage.version");
|
||||
|
||||
/** A build ID string meant for displaying to the user */
|
||||
public static final String CYANOGENMOD_DISPLAY_VERSION = getString("ro.cm.display.version");
|
||||
public static final String LINEAGEOS_DISPLAY_VERSION = getString("ro.lineage.display.version");
|
||||
|
||||
private static final SparseArray<String> sdkMap;
|
||||
static
|
||||
{
|
||||
sdkMap = new SparseArray<String>();
|
||||
sdkMap.put(CM_VERSION_CODES.APRICOT, "Apricot");
|
||||
sdkMap.put(CM_VERSION_CODES.BOYSENBERRY, "Boysenberry");
|
||||
sdkMap.put(CM_VERSION_CODES.CANTALOUPE, "Cantaloupe");
|
||||
sdkMap.put(CM_VERSION_CODES.DRAGON_FRUIT, "Dragon Fruit");
|
||||
sdkMap.put(CM_VERSION_CODES.ELDERBERRY, "Elderberry");
|
||||
sdkMap.put(CM_VERSION_CODES.FIG, "Fig");
|
||||
sdkMap.put(CM_VERSION_CODES.GUAVA, "Guava");
|
||||
sdkMap.put(LINEAGE_VERSION_CODES.APRICOT, "Apricot");
|
||||
sdkMap.put(LINEAGE_VERSION_CODES.BOYSENBERRY, "Boysenberry");
|
||||
sdkMap.put(LINEAGE_VERSION_CODES.CANTALOUPE, "Cantaloupe");
|
||||
sdkMap.put(LINEAGE_VERSION_CODES.DRAGON_FRUIT, "Dragon Fruit");
|
||||
sdkMap.put(LINEAGE_VERSION_CODES.ELDERBERRY, "Elderberry");
|
||||
sdkMap.put(LINEAGE_VERSION_CODES.FIG, "Fig");
|
||||
sdkMap.put(LINEAGE_VERSION_CODES.GUAVA, "Guava");
|
||||
}
|
||||
|
||||
/** Various version strings. */
|
||||
public static class CM_VERSION {
|
||||
public static class LINEAGE_VERSION {
|
||||
/**
|
||||
* The user-visible SDK version of the framework; its possible
|
||||
* values are defined in {@link Build.CM_VERSION_CODES}.
|
||||
* values are defined in {@link Build.LINEAGE_VERSION_CODES}.
|
||||
*
|
||||
* Will return 0 if the device does not support the CM SDK.
|
||||
* Will return 0 if the device does not support the Lineage SDK.
|
||||
*/
|
||||
public static final int SDK_INT = SystemProperties.getInt(
|
||||
"ro.cm.build.version.plat.sdk", 0);
|
||||
"ro.lineage.build.version.plat.sdk", 0);
|
||||
}
|
||||
|
||||
/**
|
||||
* Enumeration of the currently known SDK version codes. These are the
|
||||
* values that can be found in {@link CM_VERSION#SDK_INT}. Version numbers
|
||||
* values that can be found in {@link LINEAGE_VERSION#SDK_INT}. Version numbers
|
||||
* increment monotonically with each official platform release.
|
||||
*
|
||||
* To programmatically validate that a given API is available for use on the device,
|
||||
@@ -71,7 +71,7 @@ public class Build {
|
||||
* <pre class="prettyprint">
|
||||
* private void removeActiveProfile() {
|
||||
* Make sure we're running on BoysenBerry or higher to use Profiles API
|
||||
* if (Build.CM_VERSION.SDK_INT >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
* if (Build.LINEAGE_VERSION.SDK_INT >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
* ProfileManager profileManager = ProfileManager.getInstance(this);
|
||||
* Profile activeProfile = profileManager.getActiveProfile();
|
||||
* if (activeProfile != null) {
|
||||
@@ -81,7 +81,7 @@ public class Build {
|
||||
* }
|
||||
* </pre>
|
||||
*/
|
||||
public static class CM_VERSION_CODES {
|
||||
public static class LINEAGE_VERSION_CODES {
|
||||
/**
|
||||
* June 2015: The first version of the platform sdk for CyanogenMod
|
||||
*/
|
||||
@@ -93,15 +93,15 @@ public class Build {
|
||||
* <p>Applications targeting this or a later release will get these
|
||||
* new features:</p>
|
||||
* <ul>
|
||||
* <li>Profiles API via {@link cyanogenmod.app.ProfileManager}
|
||||
* <li>Profiles API via {@link lineageos.app.ProfileManager}
|
||||
* <li>New Expanded Styles for Custom Tiles via
|
||||
* {@link cyanogenmod.app.CustomTile.RemoteExpandedStyle}
|
||||
* {@link lineageos.app.CustomTile.RemoteExpandedStyle}
|
||||
* <li>Hardware Abstraction Framework Access via
|
||||
* {@link cyanogenmod.hardware.CMHardwareManager} (Not for use by 3rd parties)
|
||||
* <li>MSIM API via {@link cyanogenmod.app.CMTelephonyManager}
|
||||
* <li>Interface for partners via {@link cyanogenmod.app.PartnerInterface}
|
||||
* <li>Introductory Settings Provider {@link cyanogenmod.providers.CMSettings}
|
||||
* <li>AlarmClock API via {@link cyanogenmod.alarmclock.CyanogenModAlarmClock}
|
||||
* {@link lineageos.hardware.LineageHardwareManager} (Not for use by 3rd parties)
|
||||
* <li>MSIM API via {@link lineageos.app.LineageTelephonyManager}
|
||||
* <li>Interface for partners via {@link lineageos.app.PartnerInterface}
|
||||
* <li>Introductory Settings Provider {@link lineageos.providers.LineageSettings}
|
||||
* <li>AlarmClock API via {@link lineageos.alarmclock.LineageOSAlarmClock}
|
||||
* </ul>
|
||||
*/
|
||||
public static final int BOYSENBERRY = 2;
|
||||
@@ -119,12 +119,12 @@ public class Build {
|
||||
* new features:</p>
|
||||
* <ul>
|
||||
* <li>External views api, and specifically Keyguard interfaces for making
|
||||
* live lockscreens via {@link cyanogenmod.externalviews.KeyguardExternalView}</li>
|
||||
* live lockscreens via {@link lineageos.externalviews.KeyguardExternalView}</li>
|
||||
* <li>Inclusion of the PerformanceManager interfaces, allowing an application to specify
|
||||
* the type of mode to have the device be placed in via
|
||||
* {@link cyanogenmod.power.PerformanceManager}</li>
|
||||
* {@link lineageos.power.PerformanceManager}</li>
|
||||
* <li>Numerous new "System" settings exposed via the
|
||||
* {@link cyanogenmod.providers.CMSettings.System} interface</li>
|
||||
* {@link lineageos.providers.LineageSettings.System} interface</li>
|
||||
* </ul>
|
||||
*/
|
||||
public static final int DRAGON_FRUIT = 4;
|
||||
@@ -136,17 +136,17 @@ public class Build {
|
||||
* new features!</p>
|
||||
* <ul>
|
||||
* <li>Weather request api to fetch weather data from providers on the device
|
||||
* {@link cyanogenmod.weather.CMWeatherManager}</li>
|
||||
* {@link lineageos.weather.LineageWeatherManager}</li>
|
||||
* <li>Weather provider api to provide weather data to any listener on the device
|
||||
* {@link cyanogenmod.weatherservice.WeatherProviderService}</li>
|
||||
* <li>Extended capabilities of the {@link cyanogenmod.externalviews.KeyguardExternalView}
|
||||
* {@link lineageos.weatherservice.WeatherProviderService}</li>
|
||||
* <li>Extended capabilities of the {@link lineageos.externalviews.KeyguardExternalView}
|
||||
* interfaces to provide immersive and interactive experiences on the lockscreen.</li>
|
||||
* <li>Themes interfaces have found a new home in the cmsdk, thus we allow access
|
||||
* <li>Themes interfaces have found a new home in the lineage sdk, thus we allow access
|
||||
* to 3rd parties requesting theme changes on the platform via
|
||||
* {@link cyanogenmod.themes.ThemeManager} and
|
||||
* {@link cyanogenmod.themes.ThemeChangeRequest}</li>
|
||||
* <li>Full access to the {@link cyanogenmod.providers.ThemesContract} and provider</li>
|
||||
* <li>Parceling helper class {@link cyanogenmod.os.Concierge} to help with parcel
|
||||
* {@link lineageos.themes.ThemeManager} and
|
||||
* {@link lineageos.themes.ThemeChangeRequest}</li>
|
||||
* <li>Full access to the {@link lineageos.providers.ThemesContract} and provider</li>
|
||||
* <li>Parceling helper class {@link lineageos.os.Concierge} to help with parcel
|
||||
* headers and protocol revisions</li>
|
||||
* </ul>
|
||||
*/
|
||||
@@ -159,12 +159,12 @@ public class Build {
|
||||
* new features!</p>
|
||||
* <ul>
|
||||
* <li>Ability to query and color balance ranges from the
|
||||
* {@link cyanogenmod.hardware.CMHardwareManager}, as well as do picture adjustment</li>
|
||||
* {@link lineageos.hardware.LineageHardwareManager}, as well as do picture adjustment</li>
|
||||
* <li>Extended capabilities of the LiveDisplay interfaces, now providing
|
||||
* {@link cyanogenmod.hardware.LiveDisplayConfig} and a dedicated
|
||||
* {@link cyanogenmod.hardware.LiveDisplayManager}</li>
|
||||
* {@link lineageos.hardware.LiveDisplayConfig} and a dedicated
|
||||
* {@link lineageos.hardware.LiveDisplayManager}</li>
|
||||
* <li>Added new settings, such as LOCKSCREEN_ROTATION and DISPLAY_LOW_POWER
|
||||
* to {@link cyanogenmod.providers.CMSettings}</li>
|
||||
* to {@link lineageos.providers.LineageSettings}</li>
|
||||
* </ul>
|
||||
*
|
||||
* Signing out, Adnan \u270C
|
||||
|
||||
@@ -14,11 +14,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.os;
|
||||
package lineageos.os;
|
||||
|
||||
import android.os.Parcel;
|
||||
|
||||
import cyanogenmod.os.Build.CM_VERSION_CODES;
|
||||
import lineageos.os.Build.LINEAGE_VERSION_CODES;
|
||||
|
||||
/**
|
||||
* Simply, Concierge handles your parcels and makes sure they get marshalled and unmarshalled
|
||||
@@ -56,15 +56,15 @@ public final class Concierge {
|
||||
}
|
||||
|
||||
/**
|
||||
* Since there might be a case where new versions of the cm framework use applications running
|
||||
* Since there might be a case where new versions of the lineage framework use applications running
|
||||
* old versions of the protocol (and thus old versions of this class), we need a versioning
|
||||
* system for the parcels sent between the core framework and its sdk users.
|
||||
*
|
||||
* This parcelable version should be the latest version API version listed in
|
||||
* {@link CM_VERSION_CODES}
|
||||
* {@link LINEAGE_VERSION_CODES}
|
||||
* @hide
|
||||
*/
|
||||
public static final int PARCELABLE_VERSION = CM_VERSION_CODES.GUAVA;
|
||||
public static final int PARCELABLE_VERSION = LINEAGE_VERSION_CODES.GUAVA;
|
||||
|
||||
/**
|
||||
* Tell the concierge to receive our parcel, so we can get information from it.
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.power;
|
||||
package lineageos.power;
|
||||
|
||||
import cyanogenmod.power.PerformanceProfile;
|
||||
import lineageos.power.PerformanceProfile;
|
||||
|
||||
/** @hide */
|
||||
interface IPerformanceManager {
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.power;
|
||||
package lineageos.power;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.IBinder;
|
||||
@@ -26,7 +26,7 @@ import java.util.Collections;
|
||||
import java.util.SortedSet;
|
||||
import java.util.TreeSet;
|
||||
|
||||
import cyanogenmod.app.CMContextConstants;
|
||||
import lineageos.app.LineageContextConstants;
|
||||
|
||||
/**
|
||||
*
|
||||
@@ -87,7 +87,7 @@ public class PerformanceManager {
|
||||
/**
|
||||
* Broadcast sent when profile is changed
|
||||
*/
|
||||
public static final String POWER_PROFILE_CHANGED = "cyanogenmod.power.PROFILE_CHANGED";
|
||||
public static final String POWER_PROFILE_CHANGED = "lineageos.power.PROFILE_CHANGED";
|
||||
|
||||
private static IPerformanceManager sService;
|
||||
private static PerformanceManager sInstance;
|
||||
@@ -95,7 +95,7 @@ public class PerformanceManager {
|
||||
private PerformanceManager(Context context) {
|
||||
sService = getService();
|
||||
if (context.getPackageManager().hasSystemFeature(
|
||||
CMContextConstants.Features.PERFORMANCE) && sService == null) {
|
||||
LineageContextConstants.Features.PERFORMANCE) && sService == null) {
|
||||
Log.wtf(TAG, "Unable to get PerformanceManagerService. The service" +
|
||||
" either crashed, was not started, or the interface has been called to early" +
|
||||
" in SystemServer init");
|
||||
@@ -120,7 +120,7 @@ public class PerformanceManager {
|
||||
if (sService != null) {
|
||||
return sService;
|
||||
}
|
||||
IBinder b = ServiceManager.getService(CMContextConstants.CM_PERFORMANCE_SERVICE);
|
||||
IBinder b = ServiceManager.getService(LineageContextConstants.LINEAGE_PERFORMANCE_SERVICE);
|
||||
if (b != null) {
|
||||
sService = IPerformanceManager.Stub.asInterface(b);
|
||||
return sService;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.power;
|
||||
package lineageos.power;
|
||||
|
||||
import android.content.Intent;
|
||||
|
||||
|
||||
@@ -14,6 +14,6 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.power;
|
||||
package lineageos.power;
|
||||
|
||||
parcelable PerformanceProfile;
|
||||
|
||||
@@ -13,15 +13,15 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.power;
|
||||
package lineageos.power;
|
||||
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
|
||||
/**
|
||||
* Encapsulates information about an available system power/peformance profile, managed
|
||||
@@ -58,7 +58,7 @@ public class PerformanceProfile implements Parcelable, Comparable<PerformancePro
|
||||
mDescription = in.readString();
|
||||
mBoostEnabled = in.readInt() == 1;
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.GUAVA) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.GUAVA) {
|
||||
// nothing yet
|
||||
}
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
@@ -39,8 +39,8 @@ import java.util.List;
|
||||
import java.util.Objects;
|
||||
import java.util.Set;
|
||||
|
||||
import cyanogenmod.hardware.CMHardwareManager;
|
||||
import cyanogenmod.platform.R;
|
||||
import lineageos.hardware.LineageHardwareManager;
|
||||
import lineageos.platform.R;
|
||||
|
||||
|
||||
/**
|
||||
@@ -74,9 +74,9 @@ public class ConstraintsHelper {
|
||||
mPref = pref;
|
||||
|
||||
TypedArray a = context.getResources().obtainAttributes(attrs,
|
||||
R.styleable.cm_SelfRemovingPreference);
|
||||
mSummaryMinLines = a.getInteger(R.styleable.cm_SelfRemovingPreference_minSummaryLines, -1);
|
||||
mReplacesKey = a.getString(R.styleable.cm_SelfRemovingPreference_replacesKey);
|
||||
R.styleable.lineage_SelfRemovingPreference);
|
||||
mSummaryMinLines = a.getInteger(R.styleable.lineage_SelfRemovingPreference_minSummaryLines, -1);
|
||||
mReplacesKey = a.getString(R.styleable.lineage_SelfRemovingPreference_replacesKey);
|
||||
setAvailable(checkConstraints());
|
||||
|
||||
Log.d(TAG, "construct key=" + mPref.getKey() + " available=" + mAvailable);
|
||||
@@ -135,18 +135,18 @@ public class ConstraintsHelper {
|
||||
}
|
||||
|
||||
TypedArray a = mContext.getResources().obtainAttributes(mAttrs,
|
||||
R.styleable.cm_SelfRemovingPreference);
|
||||
R.styleable.lineage_SelfRemovingPreference);
|
||||
|
||||
try {
|
||||
|
||||
// Check if the current user is an owner
|
||||
boolean rOwner = a.getBoolean(R.styleable.cm_SelfRemovingPreference_requiresOwner, false);
|
||||
boolean rOwner = a.getBoolean(R.styleable.lineage_SelfRemovingPreference_requiresOwner, false);
|
||||
if (rOwner && UserHandle.myUserId() != UserHandle.USER_OWNER) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// Check if a specific package is installed
|
||||
String rPackage = a.getString(R.styleable.cm_SelfRemovingPreference_requiresPackage);
|
||||
String rPackage = a.getString(R.styleable.lineage_SelfRemovingPreference_requiresPackage);
|
||||
if (rPackage != null) {
|
||||
boolean negated = isNegated(rPackage);
|
||||
if (negated) {
|
||||
@@ -159,7 +159,7 @@ public class ConstraintsHelper {
|
||||
}
|
||||
|
||||
// Check if an intent can be resolved to handle the given action
|
||||
String rAction = a.getString(R.styleable.cm_SelfRemovingPreference_requiresAction);
|
||||
String rAction = a.getString(R.styleable.lineage_SelfRemovingPreference_requiresAction);
|
||||
if (rAction != null) {
|
||||
boolean negated = isNegated(rAction);
|
||||
if (negated) {
|
||||
@@ -172,15 +172,15 @@ public class ConstraintsHelper {
|
||||
}
|
||||
|
||||
// Check if a system feature is available
|
||||
String rFeature = a.getString(R.styleable.cm_SelfRemovingPreference_requiresFeature);
|
||||
String rFeature = a.getString(R.styleable.lineage_SelfRemovingPreference_requiresFeature);
|
||||
if (rFeature != null) {
|
||||
boolean negated = isNegated(rFeature);
|
||||
if (negated) {
|
||||
rFeature = rFeature.substring(1);
|
||||
}
|
||||
boolean available = rFeature.startsWith("cmhardware:") ?
|
||||
CMHardwareManager.getInstance(mContext).isSupported(
|
||||
rFeature.substring("cmhardware:".length())) :
|
||||
boolean available = rFeature.startsWith("lineagehardware:") ?
|
||||
LineageHardwareManager.getInstance(mContext).isSupported(
|
||||
rFeature.substring("lineagehardware:".length())) :
|
||||
hasSystemFeature(mContext, rFeature);
|
||||
if (available == negated) {
|
||||
return false;
|
||||
@@ -188,7 +188,7 @@ public class ConstraintsHelper {
|
||||
}
|
||||
|
||||
// Check a boolean system property
|
||||
String rProperty = a.getString(R.styleable.cm_SelfRemovingPreference_requiresProperty);
|
||||
String rProperty = a.getString(R.styleable.lineage_SelfRemovingPreference_requiresProperty);
|
||||
if (rProperty != null) {
|
||||
boolean negated = isNegated(rProperty);
|
||||
if (negated) {
|
||||
@@ -203,7 +203,7 @@ public class ConstraintsHelper {
|
||||
|
||||
// Check a config resource. This can be a bool or a string. A null string
|
||||
// fails the constraint.
|
||||
TypedValue tv = a.peekValue(R.styleable.cm_SelfRemovingPreference_requiresConfig);
|
||||
TypedValue tv = a.peekValue(R.styleable.lineage_SelfRemovingPreference_requiresConfig);
|
||||
if (tv != null) {
|
||||
if (tv.type == TypedValue.TYPE_STRING) {
|
||||
if (tv.resourceId != 0) {
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.provider.Settings;
|
||||
|
||||
@@ -14,24 +14,24 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
public class CMGlobalSettingSwitchPreference extends SelfRemovingSwitchPreference {
|
||||
public class LineageGlobalSettingSwitchPreference extends SelfRemovingSwitchPreference {
|
||||
|
||||
public CMGlobalSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
public LineageGlobalSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
}
|
||||
|
||||
public CMGlobalSettingSwitchPreference(Context context, AttributeSet attrs) {
|
||||
public LineageGlobalSettingSwitchPreference(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
public CMGlobalSettingSwitchPreference(Context context) {
|
||||
public LineageGlobalSettingSwitchPreference(Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ public class CMGlobalSettingSwitchPreference extends SelfRemovingSwitchPreferenc
|
||||
// It's already there, so the same as persisting
|
||||
return true;
|
||||
}
|
||||
CMSettings.Global.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
|
||||
LineageSettings.Global.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -53,12 +53,12 @@ public class CMGlobalSettingSwitchPreference extends SelfRemovingSwitchPreferenc
|
||||
if (!shouldPersist()) {
|
||||
return defaultReturnValue;
|
||||
}
|
||||
return CMSettings.Global.getInt(getContext().getContentResolver(),
|
||||
return LineageSettings.Global.getInt(getContext().getContentResolver(),
|
||||
getKey(), defaultReturnValue ? 1 : 0) != 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isPersisted() {
|
||||
return CMSettings.Global.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
return LineageSettings.Global.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,21 +13,21 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
|
||||
public class CMSecureSettingListPreference extends SelfRemovingListPreference {
|
||||
public class LineageSecureSettingListPreference extends SelfRemovingListPreference {
|
||||
|
||||
public CMSecureSettingListPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
public LineageSecureSettingListPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
}
|
||||
|
||||
public CMSecureSettingListPreference(Context context, AttributeSet attrs) {
|
||||
public LineageSecureSettingListPreference(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
@@ -38,7 +38,7 @@ public class CMSecureSettingListPreference extends SelfRemovingListPreference {
|
||||
// It's already there, so the same as persisting
|
||||
return true;
|
||||
}
|
||||
CMSettings.Secure.putString(getContext().getContentResolver(), getKey(), value);
|
||||
LineageSettings.Secure.putString(getContext().getContentResolver(), getKey(), value);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -49,13 +49,13 @@ public class CMSecureSettingListPreference extends SelfRemovingListPreference {
|
||||
if (!shouldPersist()) {
|
||||
return defaultReturnValue;
|
||||
}
|
||||
String value = CMSettings.Secure.getString(getContext().getContentResolver(), getKey());
|
||||
String value = LineageSettings.Secure.getString(getContext().getContentResolver(), getKey());
|
||||
return value == null ? defaultReturnValue : value;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isPersisted() {
|
||||
return CMSettings.Secure.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
return LineageSettings.Secure.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
}
|
||||
|
||||
public int getIntValue(int defValue) {
|
||||
|
||||
@@ -14,24 +14,24 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
public class CMSecureSettingSwitchPreference extends SelfRemovingSwitchPreference {
|
||||
public class LineageSecureSettingSwitchPreference extends SelfRemovingSwitchPreference {
|
||||
|
||||
public CMSecureSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
public LineageSecureSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
}
|
||||
|
||||
public CMSecureSettingSwitchPreference(Context context, AttributeSet attrs) {
|
||||
public LineageSecureSettingSwitchPreference(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
public CMSecureSettingSwitchPreference(Context context) {
|
||||
public LineageSecureSettingSwitchPreference(Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ public class CMSecureSettingSwitchPreference extends SelfRemovingSwitchPreferenc
|
||||
// It's already there, so the same as persisting
|
||||
return true;
|
||||
}
|
||||
CMSettings.Secure.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
|
||||
LineageSettings.Secure.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -53,12 +53,12 @@ public class CMSecureSettingSwitchPreference extends SelfRemovingSwitchPreferenc
|
||||
if (!shouldPersist()) {
|
||||
return defaultReturnValue;
|
||||
}
|
||||
return CMSettings.Secure.getInt(getContext().getContentResolver(),
|
||||
return LineageSettings.Secure.getInt(getContext().getContentResolver(),
|
||||
getKey(), defaultReturnValue ? 1 : 0) != 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isPersisted() {
|
||||
return CMSettings.Secure.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
return LineageSettings.Secure.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,20 +13,20 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
|
||||
public class CMSystemSettingDropDownPreference extends SelfRemovingDropDownPreference {
|
||||
public CMSystemSettingDropDownPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
public class LineageSystemSettingDropDownPreference extends SelfRemovingDropDownPreference {
|
||||
public LineageSystemSettingDropDownPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
}
|
||||
|
||||
public CMSystemSettingDropDownPreference(Context context, AttributeSet attrs) {
|
||||
public LineageSystemSettingDropDownPreference(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ public class CMSystemSettingDropDownPreference extends SelfRemovingDropDownPrefe
|
||||
// It's already there, so the same as persisting
|
||||
return true;
|
||||
}
|
||||
CMSettings.System.putString(getContext().getContentResolver(), getKey(), value);
|
||||
LineageSettings.System.putString(getContext().getContentResolver(), getKey(), value);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -48,13 +48,13 @@ public class CMSystemSettingDropDownPreference extends SelfRemovingDropDownPrefe
|
||||
if (!shouldPersist()) {
|
||||
return defaultReturnValue;
|
||||
}
|
||||
String value = CMSettings.System.getString(getContext().getContentResolver(), getKey());
|
||||
String value = LineageSettings.System.getString(getContext().getContentResolver(), getKey());
|
||||
return value == null ? defaultReturnValue : value;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isPersisted() {
|
||||
return CMSettings.System.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
return LineageSettings.System.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
}
|
||||
|
||||
public int getIntValue(int defValue) {
|
||||
|
||||
@@ -13,20 +13,20 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
|
||||
public class CMSystemSettingListPreference extends SelfRemovingListPreference {
|
||||
public CMSystemSettingListPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
public class LineageSystemSettingListPreference extends SelfRemovingListPreference {
|
||||
public LineageSystemSettingListPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
}
|
||||
|
||||
public CMSystemSettingListPreference(Context context, AttributeSet attrs) {
|
||||
public LineageSystemSettingListPreference(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
@@ -37,7 +37,7 @@ public class CMSystemSettingListPreference extends SelfRemovingListPreference {
|
||||
// It's already there, so the same as persisting
|
||||
return true;
|
||||
}
|
||||
CMSettings.System.putString(getContext().getContentResolver(), getKey(), value);
|
||||
LineageSettings.System.putString(getContext().getContentResolver(), getKey(), value);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -48,13 +48,13 @@ public class CMSystemSettingListPreference extends SelfRemovingListPreference {
|
||||
if (!shouldPersist()) {
|
||||
return defaultReturnValue;
|
||||
}
|
||||
String value = CMSettings.System.getString(getContext().getContentResolver(), getKey());
|
||||
String value = LineageSettings.System.getString(getContext().getContentResolver(), getKey());
|
||||
return value == null ? defaultReturnValue : value;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isPersisted() {
|
||||
return CMSettings.System.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
return LineageSettings.System.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
}
|
||||
|
||||
public int getIntValue(int defValue) {
|
||||
|
||||
@@ -14,24 +14,24 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.AttributeSet;
|
||||
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
public class CMSystemSettingSwitchPreference extends SelfRemovingSwitchPreference {
|
||||
public class LineageSystemSettingSwitchPreference extends SelfRemovingSwitchPreference {
|
||||
|
||||
public CMSystemSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
public LineageSystemSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
|
||||
super(context, attrs, defStyle);
|
||||
}
|
||||
|
||||
public CMSystemSettingSwitchPreference(Context context, AttributeSet attrs) {
|
||||
public LineageSystemSettingSwitchPreference(Context context, AttributeSet attrs) {
|
||||
super(context, attrs);
|
||||
}
|
||||
|
||||
public CMSystemSettingSwitchPreference(Context context) {
|
||||
public LineageSystemSettingSwitchPreference(Context context) {
|
||||
super(context);
|
||||
}
|
||||
|
||||
@@ -42,7 +42,7 @@ public class CMSystemSettingSwitchPreference extends SelfRemovingSwitchPreferenc
|
||||
// It's already there, so the same as persisting
|
||||
return true;
|
||||
}
|
||||
CMSettings.System.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
|
||||
LineageSettings.System.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
@@ -53,12 +53,12 @@ public class CMSystemSettingSwitchPreference extends SelfRemovingSwitchPreferenc
|
||||
if (!shouldPersist()) {
|
||||
return defaultReturnValue;
|
||||
}
|
||||
return CMSettings.System.getInt(getContext().getContentResolver(),
|
||||
return LineageSettings.System.getInt(getContext().getContentResolver(),
|
||||
getKey(), defaultReturnValue ? 1 : 0) != 0;
|
||||
}
|
||||
|
||||
@Override
|
||||
protected boolean isPersisted() {
|
||||
return CMSettings.System.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
return LineageSettings.System.getString(getContext().getContentResolver(), getKey()) != null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.ComponentName;
|
||||
import android.content.Context;
|
||||
@@ -66,20 +66,20 @@ public class RemotePreference extends SelfRemovingPreference
|
||||
private static final boolean DEBUG = Log.isLoggable(TAG, Log.VERBOSE);
|
||||
|
||||
public static final String ACTION_REFRESH_PREFERENCE =
|
||||
"cyanogenmod.intent.action.REFRESH_PREFERENCE";
|
||||
"lineageos.intent.action.REFRESH_PREFERENCE";
|
||||
|
||||
public static final String ACTION_UPDATE_PREFERENCE =
|
||||
"cyanogenmod.intent.action.UPDATE_PREFERENCE";
|
||||
"lineageos.intent.action.UPDATE_PREFERENCE";
|
||||
|
||||
public static final String META_REMOTE_RECEIVER =
|
||||
"org.cyanogenmod.settings.summary.receiver";
|
||||
"org.lineageos.settings.summary.receiver";
|
||||
|
||||
public static final String META_REMOTE_KEY =
|
||||
"org.cyanogenmod.settings.summary.key";
|
||||
"org.lineageos.settings.summary.key";
|
||||
|
||||
public static final String EXTRA_ENABLED = ":cm:pref_enabled";
|
||||
public static final String EXTRA_KEY = ":cm:pref_key";
|
||||
public static final String EXTRA_SUMMARY = ":cm:pref_summary";
|
||||
public static final String EXTRA_ENABLED = ":lineage:pref_enabled";
|
||||
public static final String EXTRA_KEY = ":lineage:pref_key";
|
||||
public static final String EXTRA_SUMMARY = ":lineage:pref_summary";
|
||||
|
||||
protected final Context mContext;
|
||||
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.BroadcastReceiver;
|
||||
@@ -33,11 +33,11 @@ import java.util.Map;
|
||||
import java.util.Objects;
|
||||
import java.util.Set;
|
||||
|
||||
import cyanogenmod.platform.Manifest;
|
||||
import lineageos.platform.Manifest;
|
||||
|
||||
import static cyanogenmod.preference.RemotePreference.ACTION_REFRESH_PREFERENCE;
|
||||
import static cyanogenmod.preference.RemotePreference.ACTION_UPDATE_PREFERENCE;
|
||||
import static cyanogenmod.preference.RemotePreference.EXTRA_KEY;
|
||||
import static lineageos.preference.RemotePreference.ACTION_REFRESH_PREFERENCE;
|
||||
import static lineageos.preference.RemotePreference.ACTION_UPDATE_PREFERENCE;
|
||||
import static lineageos.preference.RemotePreference.EXTRA_KEY;
|
||||
|
||||
/**
|
||||
* Manages attaching and detaching of RemotePreferences and optimizes callbacks
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.app.Activity;
|
||||
import android.content.BroadcastReceiver;
|
||||
@@ -25,7 +25,7 @@ import android.util.Log;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
import cyanogenmod.platform.Manifest;
|
||||
import lineageos.platform.Manifest;
|
||||
|
||||
/**
|
||||
* Base class for remote summary providers.
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.provider.Settings;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.support.v7.preference.DropDownPreference;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.support.v7.preference.ListPreference;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.support.v7.preference.Preference;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.support.v14.preference.SwitchPreference;
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.ContentResolver;
|
||||
import android.content.Context;
|
||||
@@ -29,7 +29,7 @@ import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
import cyanogenmod.providers.CMSettings;
|
||||
import lineageos.providers.LineageSettings;
|
||||
|
||||
public class SettingsHelper {
|
||||
|
||||
@@ -37,9 +37,9 @@ public class SettingsHelper {
|
||||
private static final String SETTINGS_SECURE = Settings.Secure.CONTENT_URI.toString();
|
||||
private static final String SETTINGS_SYSTEM = Settings.System.CONTENT_URI.toString();
|
||||
|
||||
private static final String CMSETTINGS_GLOBAL = CMSettings.Global.CONTENT_URI.toString();
|
||||
private static final String CMSETTINGS_SECURE = CMSettings.Secure.CONTENT_URI.toString();
|
||||
private static final String CMSETTINGS_SYSTEM = CMSettings.System.CONTENT_URI.toString();
|
||||
private static final String LINEAGESETTINGS_GLOBAL = LineageSettings.Global.CONTENT_URI.toString();
|
||||
private static final String LINEAGESETTINGS_SECURE = LineageSettings.Secure.CONTENT_URI.toString();
|
||||
private static final String LINEAGESETTINGS_SYSTEM = LineageSettings.System.CONTENT_URI.toString();
|
||||
|
||||
private static SettingsHelper sInstance;
|
||||
|
||||
@@ -68,12 +68,12 @@ public class SettingsHelper {
|
||||
return Settings.System.getString(resolver, uri.substring(SETTINGS_SYSTEM.length()));
|
||||
} else if (uri.startsWith(SETTINGS_GLOBAL)) {
|
||||
return Settings.Global.getString(resolver, uri.substring(SETTINGS_GLOBAL.length()));
|
||||
} else if (uri.startsWith(CMSETTINGS_SECURE)) {
|
||||
return CMSettings.Secure.getString(resolver, uri.substring(CMSETTINGS_SECURE.length()));
|
||||
} else if (uri.startsWith(CMSETTINGS_SYSTEM)) {
|
||||
return CMSettings.System.getString(resolver, uri.substring(CMSETTINGS_SYSTEM.length()));
|
||||
} else if (uri.startsWith(CMSETTINGS_GLOBAL)) {
|
||||
return CMSettings.Global.getString(resolver, uri.substring(CMSETTINGS_GLOBAL.length()));
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SECURE)) {
|
||||
return LineageSettings.Secure.getString(resolver, uri.substring(LINEAGESETTINGS_SECURE.length()));
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SYSTEM)) {
|
||||
return LineageSettings.System.getString(resolver, uri.substring(LINEAGESETTINGS_SYSTEM.length()));
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_GLOBAL)) {
|
||||
return LineageSettings.Global.getString(resolver, uri.substring(LINEAGESETTINGS_GLOBAL.length()));
|
||||
}
|
||||
return null;
|
||||
}
|
||||
@@ -88,12 +88,12 @@ public class SettingsHelper {
|
||||
return Settings.System.getInt(resolver, uri.substring(SETTINGS_SYSTEM.length()), def);
|
||||
} else if (uri.startsWith(SETTINGS_GLOBAL)) {
|
||||
return Settings.Global.getInt(resolver, uri.substring(SETTINGS_GLOBAL.length()), def);
|
||||
} else if (uri.startsWith(CMSETTINGS_SECURE)) {
|
||||
return CMSettings.Secure.getInt(resolver, uri.substring(CMSETTINGS_SECURE.length()), def);
|
||||
} else if (uri.startsWith(CMSETTINGS_SYSTEM)) {
|
||||
return CMSettings.System.getInt(resolver, uri.substring(CMSETTINGS_SYSTEM.length()), def);
|
||||
} else if (uri.startsWith(CMSETTINGS_GLOBAL)) {
|
||||
return CMSettings.Global.getInt(resolver, uri.substring(CMSETTINGS_GLOBAL.length()), def);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SECURE)) {
|
||||
return LineageSettings.Secure.getInt(resolver, uri.substring(LINEAGESETTINGS_SECURE.length()), def);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SYSTEM)) {
|
||||
return LineageSettings.System.getInt(resolver, uri.substring(LINEAGESETTINGS_SYSTEM.length()), def);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_GLOBAL)) {
|
||||
return LineageSettings.Global.getInt(resolver, uri.substring(LINEAGESETTINGS_GLOBAL.length()), def);
|
||||
}
|
||||
return def;
|
||||
}
|
||||
@@ -113,12 +113,12 @@ public class SettingsHelper {
|
||||
Settings.System.putString(resolver, uri.substring(SETTINGS_SYSTEM.length()), value);
|
||||
} else if (uri.startsWith(SETTINGS_GLOBAL)) {
|
||||
Settings.Global.putString(resolver, uri.substring(SETTINGS_GLOBAL.length()), value);
|
||||
} else if (uri.startsWith(CMSETTINGS_SECURE)) {
|
||||
CMSettings.Secure.putString(resolver, uri.substring(CMSETTINGS_SECURE.length()), value);
|
||||
} else if (uri.startsWith(CMSETTINGS_SYSTEM)) {
|
||||
CMSettings.System.putString(resolver, uri.substring(CMSETTINGS_SYSTEM.length()), value);
|
||||
} else if (uri.startsWith(CMSETTINGS_GLOBAL)) {
|
||||
CMSettings.Global.putString(resolver, uri.substring(CMSETTINGS_GLOBAL.length()), value);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SECURE)) {
|
||||
LineageSettings.Secure.putString(resolver, uri.substring(LINEAGESETTINGS_SECURE.length()), value);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SYSTEM)) {
|
||||
LineageSettings.System.putString(resolver, uri.substring(LINEAGESETTINGS_SYSTEM.length()), value);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_GLOBAL)) {
|
||||
LineageSettings.Global.putString(resolver, uri.substring(LINEAGESETTINGS_GLOBAL.length()), value);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -132,12 +132,12 @@ public class SettingsHelper {
|
||||
Settings.System.putInt(resolver, uri.substring(SETTINGS_SYSTEM.length()), value);
|
||||
} else if (uri.startsWith(SETTINGS_GLOBAL)) {
|
||||
Settings.Global.putInt(resolver, uri.substring(SETTINGS_GLOBAL.length()), value);
|
||||
} else if (uri.startsWith(CMSETTINGS_SECURE)) {
|
||||
CMSettings.Secure.putInt(resolver, uri.substring(CMSETTINGS_SECURE.length()), value);
|
||||
} else if (uri.startsWith(CMSETTINGS_SYSTEM)) {
|
||||
CMSettings.System.putInt(resolver, uri.substring(CMSETTINGS_SYSTEM.length()), value);
|
||||
} else if (uri.startsWith(CMSETTINGS_GLOBAL)) {
|
||||
CMSettings.Global.putInt(resolver, uri.substring(CMSETTINGS_GLOBAL.length()), value);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SECURE)) {
|
||||
LineageSettings.Secure.putInt(resolver, uri.substring(LINEAGESETTINGS_SECURE.length()), value);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_SYSTEM)) {
|
||||
LineageSettings.System.putInt(resolver, uri.substring(LINEAGESETTINGS_SYSTEM.length()), value);
|
||||
} else if (uri.startsWith(LINEAGESETTINGS_GLOBAL)) {
|
||||
LineageSettings.Global.putInt(resolver, uri.substring(LINEAGESETTINGS_GLOBAL.length()), value);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.preference;
|
||||
package lineageos.preference;
|
||||
|
||||
import android.content.Context;
|
||||
import android.provider.Settings;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.profiles;
|
||||
package lineageos.profiles;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
@@ -22,9 +22,9 @@ import android.provider.Settings;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParser;
|
||||
import org.xmlpull.v1.XmlPullParserException;
|
||||
@@ -212,7 +212,7 @@ public final class AirplaneModeSettings implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mOverride = in.readInt() != 0;
|
||||
mValue = in.readInt();
|
||||
mDirty = in.readInt() != 0;
|
||||
|
||||
@@ -14,16 +14,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.profiles;
|
||||
package lineageos.profiles;
|
||||
|
||||
import android.content.Context;
|
||||
import android.provider.Settings;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParser;
|
||||
import org.xmlpull.v1.XmlPullParserException;
|
||||
@@ -210,7 +210,7 @@ public final class BrightnessSettings implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mOverride = in.readInt() != 0;
|
||||
mValue = in.readInt();
|
||||
mDirty = in.readInt() != 0;
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.profiles;
|
||||
package lineageos.profiles;
|
||||
|
||||
import android.bluetooth.BluetoothAdapter;
|
||||
import android.content.ContentResolver;
|
||||
@@ -31,9 +31,9 @@ import android.telephony.SubscriptionManager;
|
||||
import android.telephony.TelephonyManager;
|
||||
import com.android.internal.telephony.RILConstants;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParser;
|
||||
import org.xmlpull.v1.XmlPullParserException;
|
||||
@@ -139,11 +139,11 @@ public final class ConnectionSettings implements Parcelable {
|
||||
public static final int STATE_ENABLED = 1;
|
||||
}
|
||||
|
||||
private static final int CM_MODE_2G = 0;
|
||||
private static final int CM_MODE_3G = 1;
|
||||
private static final int CM_MODE_4G = 2;
|
||||
private static final int CM_MODE_2G3G = 3;
|
||||
private static final int CM_MODE_ALL = 4;
|
||||
private static final int LINEAGE_MODE_2G = 0;
|
||||
private static final int LINEAGE_MODE_3G = 1;
|
||||
private static final int LINEAGE_MODE_4G = 2;
|
||||
private static final int LINEAGE_MODE_2G3G = 3;
|
||||
private static final int LINEAGE_MODE_ALL = 4;
|
||||
|
||||
/** @hide */
|
||||
public static final Parcelable.Creator<ConnectionSettings> CREATOR =
|
||||
@@ -281,7 +281,7 @@ public final class ConnectionSettings implements Parcelable {
|
||||
}
|
||||
break;
|
||||
case PROFILE_CONNECTION_2G3G4G:
|
||||
if (Build.CM_VERSION.SDK_INT >= Build.CM_VERSION_CODES.ELDERBERRY) {
|
||||
if (Build.LINEAGE_VERSION.SDK_INT >= Build.LINEAGE_VERSION_CODES.ELDERBERRY) {
|
||||
Intent intent = new Intent(ACTION_MODIFY_NETWORK_MODE);
|
||||
intent.putExtra(EXTRA_NETWORK_MODE, getValue());
|
||||
intent.putExtra(EXTRA_SUB_ID, getSubId());
|
||||
@@ -289,19 +289,19 @@ public final class ConnectionSettings implements Parcelable {
|
||||
} else {
|
||||
Intent intent = new Intent(ACTION_MODIFY_NETWORK_MODE);
|
||||
switch(getValue()) {
|
||||
case CM_MODE_2G:
|
||||
case LINEAGE_MODE_2G:
|
||||
intent.putExtra(EXTRA_NETWORK_MODE, RILConstants.NETWORK_MODE_GSM_ONLY);
|
||||
break;
|
||||
case CM_MODE_3G:
|
||||
case LINEAGE_MODE_3G:
|
||||
intent.putExtra(EXTRA_NETWORK_MODE, RILConstants.NETWORK_MODE_WCDMA_ONLY);
|
||||
break;
|
||||
case CM_MODE_4G:
|
||||
case LINEAGE_MODE_4G:
|
||||
intent.putExtra(EXTRA_NETWORK_MODE, RILConstants.NETWORK_MODE_LTE_ONLY);
|
||||
break;
|
||||
case CM_MODE_2G3G:
|
||||
case LINEAGE_MODE_2G3G:
|
||||
intent.putExtra(EXTRA_NETWORK_MODE, RILConstants.NETWORK_MODE_WCDMA_PREF);
|
||||
break;
|
||||
case CM_MODE_ALL:
|
||||
case LINEAGE_MODE_ALL:
|
||||
intent.putExtra(EXTRA_NETWORK_MODE,
|
||||
RILConstants.NETWORK_MODE_LTE_GSM_WCDMA);
|
||||
break;
|
||||
@@ -409,7 +409,7 @@ public final class ConnectionSettings implements Parcelable {
|
||||
builder.append("</value>\n<override>");
|
||||
builder.append(mOverride);
|
||||
builder.append("</override>\n");
|
||||
if (Build.CM_VERSION.SDK_INT >= Build.CM_VERSION_CODES.ELDERBERRY) {
|
||||
if (Build.LINEAGE_VERSION.SDK_INT >= Build.LINEAGE_VERSION_CODES.ELDERBERRY) {
|
||||
if (mConnectionId == PROFILE_CONNECTION_2G3G4G
|
||||
&& mSubId != SubscriptionManager.INVALID_SUBSCRIPTION_ID) {
|
||||
builder.append("<subId>").append(mSubId).append("</subId>\n");
|
||||
@@ -453,14 +453,14 @@ public final class ConnectionSettings implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mConnectionId = in.readInt();
|
||||
mOverride = in.readInt() != 0;
|
||||
mValue = in.readInt();
|
||||
mDirty = in.readInt() != 0;
|
||||
}
|
||||
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.ELDERBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.ELDERBERRY) {
|
||||
if (mConnectionId == PROFILE_CONNECTION_2G3G4G) {
|
||||
mSubId = in.readInt();
|
||||
}
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.profiles;
|
||||
package lineageos.profiles;
|
||||
|
||||
import android.app.admin.DevicePolicyManager;
|
||||
import android.content.Context;
|
||||
@@ -26,10 +26,10 @@ import android.util.Log;
|
||||
import com.android.internal.policy.IKeyguardService;
|
||||
/* import com.android.internal.policy.PolicyManager; */
|
||||
|
||||
import cyanogenmod.app.Profile;
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.app.Profile;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
/**
|
||||
* The {@link LockSettings} class allows for overriding and setting the
|
||||
@@ -168,7 +168,7 @@ public final class LockSettings implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mValue = in.readInt();
|
||||
mDirty = in.readInt() != 0;
|
||||
}
|
||||
|
||||
@@ -14,16 +14,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.profiles;
|
||||
package lineageos.profiles;
|
||||
|
||||
import android.content.Context;
|
||||
import android.media.AudioManager;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import org.xmlpull.v1.XmlPullParser;
|
||||
import org.xmlpull.v1.XmlPullParserException;
|
||||
@@ -202,7 +202,7 @@ public final class RingModeSettings implements Parcelable {
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mOverride = in.readInt() != 0;
|
||||
mValue = in.readString();
|
||||
mDirty = in.readInt() != 0;
|
||||
|
||||
@@ -14,16 +14,16 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.profiles;
|
||||
package lineageos.profiles;
|
||||
|
||||
import android.content.Context;
|
||||
import android.os.Parcel;
|
||||
import android.os.Parcelable;
|
||||
|
||||
|
||||
import cyanogenmod.os.Build;
|
||||
import cyanogenmod.os.Concierge;
|
||||
import cyanogenmod.os.Concierge.ParcelInfo;
|
||||
import lineageos.os.Build;
|
||||
import lineageos.os.Concierge;
|
||||
import lineageos.os.Concierge.ParcelInfo;
|
||||
|
||||
import java.io.IOException;
|
||||
|
||||
@@ -203,7 +203,7 @@ public final class StreamSettings implements Parcelable{
|
||||
// Pattern here is that all new members should be added to the end of
|
||||
// the writeToParcel method. Then we step through each version, until the latest
|
||||
// API release to help unravel this parcel
|
||||
if (parcelableVersion >= Build.CM_VERSION_CODES.BOYSENBERRY) {
|
||||
if (parcelableVersion >= Build.LINEAGE_VERSION_CODES.BOYSENBERRY) {
|
||||
mStreamId = in.readInt();
|
||||
mOverride = in.readInt() != 0;
|
||||
mValue = in.readInt();
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.providers;
|
||||
package lineageos.providers;
|
||||
|
||||
import android.content.ContentResolver;
|
||||
import android.net.Uri;
|
||||
@@ -28,7 +28,7 @@ import android.net.Uri;
|
||||
public final class DataUsageContract {
|
||||
|
||||
/** The authority for the DataUsage provider */
|
||||
public static final String DATAUSAGE_AUTHORITY = "org.cyanogenmod.providers.datausage";
|
||||
public static final String DATAUSAGE_AUTHORITY = "org.lineageos.providers.datausage";
|
||||
public static final String DATAUSAGE_TABLE = "datausage";
|
||||
|
||||
/** The content URI for the top-level datausage authority */
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.providers;
|
||||
package lineageos.providers;
|
||||
|
||||
import com.android.internal.util.ArrayUtils;
|
||||
|
||||
@@ -44,16 +44,16 @@ import java.util.Map;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
/**
|
||||
* CMSettings contains CM specific preferences in System, Secure, and Global.
|
||||
* LineageSettings contains Lineage specific preferences in System, Secure, and Global.
|
||||
*/
|
||||
public final class CMSettings {
|
||||
private static final String TAG = "CMSettings";
|
||||
public final class LineageSettings {
|
||||
private static final String TAG = "LineageSettings";
|
||||
private static final boolean LOCAL_LOGV = false;
|
||||
|
||||
public static final String AUTHORITY = "cmsettings";
|
||||
public static final String AUTHORITY = "lineagesettings";
|
||||
|
||||
public static class CMSettingNotFoundException extends AndroidException {
|
||||
public CMSettingNotFoundException(String msg) {
|
||||
public static class LineageSettingNotFoundException extends AndroidException {
|
||||
public LineageSettingNotFoundException(String msg) {
|
||||
super(msg);
|
||||
}
|
||||
}
|
||||
@@ -66,7 +66,7 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* Output: Nothing.
|
||||
*/
|
||||
public static final String ACTION_DATA_USAGE = "cyanogenmod.settings.ACTION_DATA_USAGE";
|
||||
public static final String ACTION_DATA_USAGE = "lineageos.settings.ACTION_DATA_USAGE";
|
||||
|
||||
/**
|
||||
* Activity Action: Show LiveDisplay settings
|
||||
@@ -76,7 +76,7 @@ public final class CMSettings {
|
||||
* Output: Nothing.
|
||||
*/
|
||||
public static final String ACTION_LIVEDISPLAY_SETTINGS =
|
||||
"cyanogenmod.settings.LIVEDISPLAY_SETTINGS";
|
||||
"lineageos.settings.LIVEDISPLAY_SETTINGS";
|
||||
|
||||
// region Call Methods
|
||||
|
||||
@@ -116,12 +116,12 @@ public final class CMSettings {
|
||||
public static final String CALL_METHOD_PUT_GLOBAL= "PUT_global";
|
||||
|
||||
/**
|
||||
* @hide - Private call() method on CMSettingsProvider to migrate CM settings
|
||||
* @hide - Private call() method on LineageSettingsProvider to migrate Lineage settings
|
||||
*/
|
||||
public static final String CALL_METHOD_MIGRATE_SETTINGS = "migrate_settings";
|
||||
|
||||
/**
|
||||
* @hide - Private call() method on CMSettingsProvider to migrate CM settings for a user
|
||||
* @hide - Private call() method on LineageSettingsProvider to migrate Lineage settings for a user
|
||||
*/
|
||||
public static final String CALL_METHOD_MIGRATE_SETTINGS_FOR_USER = "migrate_settings_for_user";
|
||||
|
||||
@@ -424,16 +424,16 @@ public final class CMSettings {
|
||||
// endregion Validators
|
||||
|
||||
/**
|
||||
* System settings, containing miscellaneous CM system preferences. This table holds simple
|
||||
* System settings, containing miscellaneous Lineage system preferences. This table holds simple
|
||||
* name/value pairs. There are convenience functions for accessing individual settings entries.
|
||||
*/
|
||||
public static final class System extends Settings.NameValueTable {
|
||||
public static final Uri CONTENT_URI = Uri.parse("content://" + AUTHORITY + "/system");
|
||||
|
||||
public static final String SYS_PROP_CM_SETTING_VERSION = "sys.cm_settings_system_version";
|
||||
public static final String SYS_PROP_LINEAGE_SETTING_VERSION = "sys.lineage_settings_system_version";
|
||||
|
||||
private static final NameValueCache sNameValueCache = new NameValueCache(
|
||||
SYS_PROP_CM_SETTING_VERSION,
|
||||
SYS_PROP_LINEAGE_SETTING_VERSION,
|
||||
CONTENT_URI,
|
||||
CALL_METHOD_GET_SYSTEM,
|
||||
CALL_METHOD_PUT_SYSTEM);
|
||||
@@ -509,9 +509,9 @@ public final class CMSettings {
|
||||
public static String getStringForUser(ContentResolver resolver, String name,
|
||||
int userId) {
|
||||
if (MOVED_TO_SECURE.contains(name)) {
|
||||
Log.w(TAG, "Setting " + name + " has moved from CMSettings.System"
|
||||
+ " to CMSettings.Secure, value is unchanged.");
|
||||
return CMSettings.Secure.getStringForUser(resolver, name, userId);
|
||||
Log.w(TAG, "Setting " + name + " has moved from LineageSettings.System"
|
||||
+ " to LineageSettings.Secure, value is unchanged.");
|
||||
return LineageSettings.Secure.getStringForUser(resolver, name, userId);
|
||||
}
|
||||
return sNameValueCache.getStringForUser(resolver, name, userId);
|
||||
}
|
||||
@@ -531,8 +531,8 @@ public final class CMSettings {
|
||||
public static boolean putStringForUser(ContentResolver resolver, String name, String value,
|
||||
int userId) {
|
||||
if (MOVED_TO_SECURE.contains(name)) {
|
||||
Log.w(TAG, "Setting " + name + " has moved from CMSettings.System"
|
||||
+ " to CMSettings.Secure, value is unchanged.");
|
||||
Log.w(TAG, "Setting " + name + " has moved from LineageSettings.System"
|
||||
+ " to LineageSettings.Secure, value is unchanged.");
|
||||
return false;
|
||||
}
|
||||
return sNameValueCache.putStringForUser(resolver, name, value, userId);
|
||||
@@ -574,29 +574,29 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not an integer.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
*/
|
||||
public static int getInt(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getIntForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static int getIntForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String v = getStringForUser(cr, name, userId);
|
||||
try {
|
||||
return Integer.parseInt(v);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -662,28 +662,28 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not an integer.
|
||||
*/
|
||||
public static long getLong(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getLongForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static long getLongForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String valString = getStringForUser(cr, name, userId);
|
||||
try {
|
||||
return Long.parseLong(valString);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -747,32 +747,32 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not a float.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
*/
|
||||
public static float getFloat(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getFloatForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static float getFloatForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String v = getStringForUser(cr, name, userId);
|
||||
if (v == null) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
try {
|
||||
return Float.parseFloat(v);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1405,7 +1405,7 @@ public final class CMSettings {
|
||||
public static final String DISPLAY_CABC = "display_low_power";
|
||||
|
||||
/**
|
||||
* @deprecated Use {@link cyanogenmod.providers.CMSettings.System#DISPLAY_CABC} instead
|
||||
* @deprecated Use {@link lineageos.providers.LineageSettings.System#DISPLAY_CABC} instead
|
||||
*/
|
||||
@Deprecated
|
||||
public static final String DISPLAY_LOW_POWER = DISPLAY_CABC;
|
||||
@@ -1935,93 +1935,93 @@ public final class CMSettings {
|
||||
* @hide
|
||||
*/
|
||||
public static final String[] LEGACY_SYSTEM_SETTINGS = new String[]{
|
||||
CMSettings.System.NAV_BUTTONS,
|
||||
CMSettings.System.KEY_HOME_LONG_PRESS_ACTION,
|
||||
CMSettings.System.KEY_HOME_DOUBLE_TAP_ACTION,
|
||||
CMSettings.System.BACK_WAKE_SCREEN,
|
||||
CMSettings.System.MENU_WAKE_SCREEN,
|
||||
CMSettings.System.VOLUME_WAKE_SCREEN,
|
||||
CMSettings.System.KEY_MENU_ACTION,
|
||||
CMSettings.System.KEY_MENU_LONG_PRESS_ACTION,
|
||||
CMSettings.System.KEY_ASSIST_ACTION,
|
||||
CMSettings.System.KEY_ASSIST_LONG_PRESS_ACTION,
|
||||
CMSettings.System.KEY_APP_SWITCH_ACTION,
|
||||
CMSettings.System.KEY_APP_SWITCH_LONG_PRESS_ACTION,
|
||||
CMSettings.System.HOME_WAKE_SCREEN,
|
||||
CMSettings.System.ASSIST_WAKE_SCREEN,
|
||||
CMSettings.System.APP_SWITCH_WAKE_SCREEN,
|
||||
CMSettings.System.CAMERA_WAKE_SCREEN,
|
||||
CMSettings.System.CAMERA_SLEEP_ON_RELEASE,
|
||||
CMSettings.System.CAMERA_LAUNCH,
|
||||
CMSettings.System.STYLUS_ICON_ENABLED,
|
||||
CMSettings.System.SWAP_VOLUME_KEYS_ON_ROTATION,
|
||||
CMSettings.System.BATTERY_LIGHT_ENABLED,
|
||||
CMSettings.System.BATTERY_LIGHT_PULSE,
|
||||
CMSettings.System.BATTERY_LIGHT_LOW_COLOR,
|
||||
CMSettings.System.BATTERY_LIGHT_MEDIUM_COLOR,
|
||||
CMSettings.System.BATTERY_LIGHT_FULL_COLOR,
|
||||
CMSettings.System.ENABLE_MWI_NOTIFICATION,
|
||||
CMSettings.System.PROXIMITY_ON_WAKE,
|
||||
CMSettings.System.ENABLE_FORWARD_LOOKUP,
|
||||
CMSettings.System.ENABLE_PEOPLE_LOOKUP,
|
||||
CMSettings.System.ENABLE_REVERSE_LOOKUP,
|
||||
CMSettings.System.FORWARD_LOOKUP_PROVIDER,
|
||||
CMSettings.System.PEOPLE_LOOKUP_PROVIDER,
|
||||
CMSettings.System.REVERSE_LOOKUP_PROVIDER,
|
||||
CMSettings.System.DIALER_OPENCNAM_ACCOUNT_SID,
|
||||
CMSettings.System.DIALER_OPENCNAM_AUTH_TOKEN,
|
||||
CMSettings.System.DISPLAY_TEMPERATURE_DAY,
|
||||
CMSettings.System.DISPLAY_TEMPERATURE_NIGHT,
|
||||
CMSettings.System.DISPLAY_TEMPERATURE_MODE,
|
||||
CMSettings.System.DISPLAY_AUTO_OUTDOOR_MODE,
|
||||
CMSettings.System.DISPLAY_CABC,
|
||||
CMSettings.System.DISPLAY_COLOR_ENHANCE,
|
||||
CMSettings.System.DISPLAY_COLOR_ADJUSTMENT,
|
||||
CMSettings.System.LIVE_DISPLAY_HINTED,
|
||||
CMSettings.System.DOUBLE_TAP_SLEEP_GESTURE,
|
||||
CMSettings.System.STATUS_BAR_SHOW_WEATHER,
|
||||
CMSettings.System.RECENTS_SHOW_SEARCH_BAR,
|
||||
CMSettings.System.NAVBAR_LEFT_IN_LANDSCAPE,
|
||||
CMSettings.System.T9_SEARCH_INPUT_LOCALE,
|
||||
CMSettings.System.BLUETOOTH_ACCEPT_ALL_FILES,
|
||||
CMSettings.System.LOCKSCREEN_PIN_SCRAMBLE_LAYOUT,
|
||||
CMSettings.System.SHOW_ALARM_ICON,
|
||||
CMSettings.System.STATUS_BAR_IME_SWITCHER,
|
||||
CMSettings.System.QS_SHOW_BRIGHTNESS_SLIDER,
|
||||
CMSettings.System.STATUS_BAR_BRIGHTNESS_CONTROL,
|
||||
CMSettings.System.VOLBTN_MUSIC_CONTROLS,
|
||||
CMSettings.System.USE_EDGE_SERVICE_FOR_GESTURES,
|
||||
CMSettings.System.STATUS_BAR_NOTIF_COUNT,
|
||||
CMSettings.System.CALL_RECORDING_FORMAT,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_BRIGHTNESS_LEVEL,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_MULTIPLE_LEDS_ENABLE,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_SCREEN_ON,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_COLOR,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_ON,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_OFF,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_COLOR,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_LED_ON,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_LED_OFF,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_COLOR,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_LED_ON,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_LED_OFF,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_CUSTOM_ENABLE,
|
||||
CMSettings.System.NOTIFICATION_LIGHT_PULSE_CUSTOM_VALUES,
|
||||
CMSettings.System.STATUS_BAR_QUICK_QS_PULLDOWN,
|
||||
CMSettings.System.VOLUME_ADJUST_SOUNDS_ENABLED,
|
||||
CMSettings.System.SYSTEM_PROFILES_ENABLED,
|
||||
CMSettings.System.INCREASING_RING,
|
||||
CMSettings.System.INCREASING_RING_START_VOLUME,
|
||||
CMSettings.System.INCREASING_RING_RAMP_UP_TIME,
|
||||
CMSettings.System.STATUS_BAR_CLOCK,
|
||||
CMSettings.System.STATUS_BAR_AM_PM,
|
||||
CMSettings.System.STATUS_BAR_BATTERY_STYLE,
|
||||
CMSettings.System.STATUS_BAR_SHOW_BATTERY_PERCENT,
|
||||
CMSettings.System.VOLUME_KEYS_CONTROL_RING_STREAM,
|
||||
CMSettings.System.NAVIGATION_BAR_MENU_ARROW_KEYS,
|
||||
CMSettings.System.HEADSET_CONNECT_PLAYER,
|
||||
CMSettings.System.ZEN_ALLOW_LIGHTS,
|
||||
CMSettings.System.TOUCHSCREEN_GESTURE_HAPTIC_FEEDBACK,
|
||||
LineageSettings.System.NAV_BUTTONS,
|
||||
LineageSettings.System.KEY_HOME_LONG_PRESS_ACTION,
|
||||
LineageSettings.System.KEY_HOME_DOUBLE_TAP_ACTION,
|
||||
LineageSettings.System.BACK_WAKE_SCREEN,
|
||||
LineageSettings.System.MENU_WAKE_SCREEN,
|
||||
LineageSettings.System.VOLUME_WAKE_SCREEN,
|
||||
LineageSettings.System.KEY_MENU_ACTION,
|
||||
LineageSettings.System.KEY_MENU_LONG_PRESS_ACTION,
|
||||
LineageSettings.System.KEY_ASSIST_ACTION,
|
||||
LineageSettings.System.KEY_ASSIST_LONG_PRESS_ACTION,
|
||||
LineageSettings.System.KEY_APP_SWITCH_ACTION,
|
||||
LineageSettings.System.KEY_APP_SWITCH_LONG_PRESS_ACTION,
|
||||
LineageSettings.System.HOME_WAKE_SCREEN,
|
||||
LineageSettings.System.ASSIST_WAKE_SCREEN,
|
||||
LineageSettings.System.APP_SWITCH_WAKE_SCREEN,
|
||||
LineageSettings.System.CAMERA_WAKE_SCREEN,
|
||||
LineageSettings.System.CAMERA_SLEEP_ON_RELEASE,
|
||||
LineageSettings.System.CAMERA_LAUNCH,
|
||||
LineageSettings.System.STYLUS_ICON_ENABLED,
|
||||
LineageSettings.System.SWAP_VOLUME_KEYS_ON_ROTATION,
|
||||
LineageSettings.System.BATTERY_LIGHT_ENABLED,
|
||||
LineageSettings.System.BATTERY_LIGHT_PULSE,
|
||||
LineageSettings.System.BATTERY_LIGHT_LOW_COLOR,
|
||||
LineageSettings.System.BATTERY_LIGHT_MEDIUM_COLOR,
|
||||
LineageSettings.System.BATTERY_LIGHT_FULL_COLOR,
|
||||
LineageSettings.System.ENABLE_MWI_NOTIFICATION,
|
||||
LineageSettings.System.PROXIMITY_ON_WAKE,
|
||||
LineageSettings.System.ENABLE_FORWARD_LOOKUP,
|
||||
LineageSettings.System.ENABLE_PEOPLE_LOOKUP,
|
||||
LineageSettings.System.ENABLE_REVERSE_LOOKUP,
|
||||
LineageSettings.System.FORWARD_LOOKUP_PROVIDER,
|
||||
LineageSettings.System.PEOPLE_LOOKUP_PROVIDER,
|
||||
LineageSettings.System.REVERSE_LOOKUP_PROVIDER,
|
||||
LineageSettings.System.DIALER_OPENCNAM_ACCOUNT_SID,
|
||||
LineageSettings.System.DIALER_OPENCNAM_AUTH_TOKEN,
|
||||
LineageSettings.System.DISPLAY_TEMPERATURE_DAY,
|
||||
LineageSettings.System.DISPLAY_TEMPERATURE_NIGHT,
|
||||
LineageSettings.System.DISPLAY_TEMPERATURE_MODE,
|
||||
LineageSettings.System.DISPLAY_AUTO_OUTDOOR_MODE,
|
||||
LineageSettings.System.DISPLAY_CABC,
|
||||
LineageSettings.System.DISPLAY_COLOR_ENHANCE,
|
||||
LineageSettings.System.DISPLAY_COLOR_ADJUSTMENT,
|
||||
LineageSettings.System.LIVE_DISPLAY_HINTED,
|
||||
LineageSettings.System.DOUBLE_TAP_SLEEP_GESTURE,
|
||||
LineageSettings.System.STATUS_BAR_SHOW_WEATHER,
|
||||
LineageSettings.System.RECENTS_SHOW_SEARCH_BAR,
|
||||
LineageSettings.System.NAVBAR_LEFT_IN_LANDSCAPE,
|
||||
LineageSettings.System.T9_SEARCH_INPUT_LOCALE,
|
||||
LineageSettings.System.BLUETOOTH_ACCEPT_ALL_FILES,
|
||||
LineageSettings.System.LOCKSCREEN_PIN_SCRAMBLE_LAYOUT,
|
||||
LineageSettings.System.SHOW_ALARM_ICON,
|
||||
LineageSettings.System.STATUS_BAR_IME_SWITCHER,
|
||||
LineageSettings.System.QS_SHOW_BRIGHTNESS_SLIDER,
|
||||
LineageSettings.System.STATUS_BAR_BRIGHTNESS_CONTROL,
|
||||
LineageSettings.System.VOLBTN_MUSIC_CONTROLS,
|
||||
LineageSettings.System.USE_EDGE_SERVICE_FOR_GESTURES,
|
||||
LineageSettings.System.STATUS_BAR_NOTIF_COUNT,
|
||||
LineageSettings.System.CALL_RECORDING_FORMAT,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_BRIGHTNESS_LEVEL,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_MULTIPLE_LEDS_ENABLE,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_SCREEN_ON,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_COLOR,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_ON,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_DEFAULT_LED_OFF,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_COLOR,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_LED_ON,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CALL_LED_OFF,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_COLOR,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_LED_ON,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_VMAIL_LED_OFF,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CUSTOM_ENABLE,
|
||||
LineageSettings.System.NOTIFICATION_LIGHT_PULSE_CUSTOM_VALUES,
|
||||
LineageSettings.System.STATUS_BAR_QUICK_QS_PULLDOWN,
|
||||
LineageSettings.System.VOLUME_ADJUST_SOUNDS_ENABLED,
|
||||
LineageSettings.System.SYSTEM_PROFILES_ENABLED,
|
||||
LineageSettings.System.INCREASING_RING,
|
||||
LineageSettings.System.INCREASING_RING_START_VOLUME,
|
||||
LineageSettings.System.INCREASING_RING_RAMP_UP_TIME,
|
||||
LineageSettings.System.STATUS_BAR_CLOCK,
|
||||
LineageSettings.System.STATUS_BAR_AM_PM,
|
||||
LineageSettings.System.STATUS_BAR_BATTERY_STYLE,
|
||||
LineageSettings.System.STATUS_BAR_SHOW_BATTERY_PERCENT,
|
||||
LineageSettings.System.VOLUME_KEYS_CONTROL_RING_STREAM,
|
||||
LineageSettings.System.NAVIGATION_BAR_MENU_ARROW_KEYS,
|
||||
LineageSettings.System.HEADSET_CONNECT_PLAYER,
|
||||
LineageSettings.System.ZEN_ALLOW_LIGHTS,
|
||||
LineageSettings.System.TOUCHSCREEN_GESTURE_HAPTIC_FEEDBACK,
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -2038,7 +2038,7 @@ public final class CMSettings {
|
||||
switch (key) {
|
||||
case System.SYSTEM_PROFILES_ENABLED:
|
||||
// some apps still query Settings.System.DEV_FORCE_SHOW_NAVBAR;
|
||||
// we intercept the call, and return CMSettings.Secure.DEV_FORCE_SHOW_NAVBAR's value
|
||||
// we intercept the call, and return LineageSettings.Secure.DEV_FORCE_SHOW_NAVBAR's value
|
||||
case Secure.DEV_FORCE_SHOW_NAVBAR:
|
||||
return true;
|
||||
default:
|
||||
@@ -2198,17 +2198,17 @@ public final class CMSettings {
|
||||
}
|
||||
|
||||
/**
|
||||
* Secure settings, containing miscellaneous CM secure preferences. This
|
||||
* Secure settings, containing miscellaneous Lineage secure preferences. This
|
||||
* table holds simple name/value pairs. There are convenience
|
||||
* functions for accessing individual settings entries.
|
||||
*/
|
||||
public static final class Secure extends Settings.NameValueTable {
|
||||
public static final Uri CONTENT_URI = Uri.parse("content://" + AUTHORITY + "/secure");
|
||||
|
||||
public static final String SYS_PROP_CM_SETTING_VERSION = "sys.cm_settings_secure_version";
|
||||
public static final String SYS_PROP_LINEAGE_SETTING_VERSION = "sys.lineage_settings_secure_version";
|
||||
|
||||
private static final NameValueCache sNameValueCache = new NameValueCache(
|
||||
SYS_PROP_CM_SETTING_VERSION,
|
||||
SYS_PROP_LINEAGE_SETTING_VERSION,
|
||||
CONTENT_URI,
|
||||
CALL_METHOD_GET_SECURE,
|
||||
CALL_METHOD_PUT_SECURE);
|
||||
@@ -2284,9 +2284,9 @@ public final class CMSettings {
|
||||
public static String getStringForUser(ContentResolver resolver, String name,
|
||||
int userId) {
|
||||
if (MOVED_TO_GLOBAL.contains(name)) {
|
||||
Log.w(TAG, "Setting " + name + " has moved from CMSettings.Secure"
|
||||
+ " to CMSettings.Global, value is unchanged.");
|
||||
return CMSettings.Global.getStringForUser(resolver, name, userId);
|
||||
Log.w(TAG, "Setting " + name + " has moved from LineageSettings.Secure"
|
||||
+ " to LineageSettings.Global, value is unchanged.");
|
||||
return LineageSettings.Global.getStringForUser(resolver, name, userId);
|
||||
}
|
||||
return sNameValueCache.getStringForUser(resolver, name, userId);
|
||||
}
|
||||
@@ -2306,8 +2306,8 @@ public final class CMSettings {
|
||||
public static boolean putStringForUser(ContentResolver resolver, String name, String value,
|
||||
int userId) {
|
||||
if (MOVED_TO_GLOBAL.contains(name)) {
|
||||
Log.w(TAG, "Setting " + name + " has moved from CMSettings.Secure"
|
||||
+ " to CMSettings.Global, value is unchanged.");
|
||||
Log.w(TAG, "Setting " + name + " has moved from LineageSettings.Secure"
|
||||
+ " to LineageSettings.Global, value is unchanged.");
|
||||
return false;
|
||||
}
|
||||
return sNameValueCache.putStringForUser(resolver, name, value, userId);
|
||||
@@ -2349,29 +2349,29 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not an integer.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
*/
|
||||
public static int getInt(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getIntForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static int getIntForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String v = getStringForUser(cr, name, userId);
|
||||
try {
|
||||
return Integer.parseInt(v);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2437,28 +2437,28 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not an integer.
|
||||
*/
|
||||
public static long getLong(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getLongForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static long getLongForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String valString = getStringForUser(cr, name, userId);
|
||||
try {
|
||||
return Long.parseLong(valString);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2522,32 +2522,32 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not a float.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
*/
|
||||
public static float getFloat(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getFloatForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static float getFloatForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String v = getStringForUser(cr, name, userId);
|
||||
if (v == null) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
try {
|
||||
return Float.parseFloat(v);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2682,7 +2682,7 @@ public final class CMSettings {
|
||||
/**
|
||||
* Whether the global stats collection setting has been successfully reported to server
|
||||
* @hide
|
||||
* @deprecated {@link org.cyanogenmod.cmparts.cmstats.AnonymousStats} no longer uses this
|
||||
* @deprecated {@link org.lineageos.lineageparts.lineagestats.AnonymousStats} no longer uses this
|
||||
*/
|
||||
@Deprecated
|
||||
public static final String STATS_COLLECTION_REPORTED = "stats_collection_reported";
|
||||
@@ -2808,7 +2808,7 @@ public final class CMSettings {
|
||||
|
||||
/**
|
||||
* This will be set to the system's current theme API version when ThemeService starts.
|
||||
* It is useful for when an upgrade from one version of CM to another occurs.
|
||||
* It is useful for when an upgrade from one version of Lineage to another occurs.
|
||||
* For example, after a user upgrades from CM11 to CM12, the value of this field
|
||||
* might be 19. ThemeService would then change the value to 21. This is useful
|
||||
* when an API change breaks a theme. Themeservice can identify old themes and
|
||||
@@ -2910,15 +2910,15 @@ public final class CMSettings {
|
||||
public static final String WEATHER_PROVIDER_SERVICE = "weather_provider_service";
|
||||
|
||||
/**
|
||||
* Set to 0 when we enter the CM Setup Wizard.
|
||||
* Set to 1 when we exit the CM Setup Wizard.
|
||||
* Set to 0 when we enter the Lineage Setup Wizard.
|
||||
* Set to 1 when we exit the Lineage Setup Wizard.
|
||||
*
|
||||
* @deprecated Use {@link Secure#USER_SETUP_COMPLETE} or
|
||||
* {@link Settings.Global#DEVICE_PROVISIONED} instead
|
||||
* @hide
|
||||
*/
|
||||
@Deprecated
|
||||
public static final String CM_SETUP_WIZARD_COMPLETED = "cm_setup_wizard_completed";
|
||||
public static final String LINEAGE_SETUP_WIZARD_COMPLETED = "lineage_setup_wizard_completed";
|
||||
|
||||
/**
|
||||
* Whether lock screen bluring is enabled on devices that support this feature
|
||||
@@ -2946,40 +2946,40 @@ public final class CMSettings {
|
||||
* @hide
|
||||
*/
|
||||
public static final String[] LEGACY_SECURE_SETTINGS = new String[]{
|
||||
CMSettings.Secure.ADVANCED_MODE,
|
||||
CMSettings.Secure.BUTTON_BACKLIGHT_TIMEOUT,
|
||||
CMSettings.Secure.BUTTON_BRIGHTNESS,
|
||||
CMSettings.Secure.DEFAULT_THEME_COMPONENTS,
|
||||
CMSettings.Secure.DEFAULT_THEME_PACKAGE,
|
||||
CMSettings.Secure.DEV_FORCE_SHOW_NAVBAR,
|
||||
CMSettings.Secure.KEYBOARD_BRIGHTNESS,
|
||||
CMSettings.Secure.POWER_MENU_ACTIONS,
|
||||
CMSettings.Secure.STATS_COLLECTION,
|
||||
CMSettings.Secure.QS_SHOW_BRIGHTNESS_SLIDER,
|
||||
CMSettings.Secure.QS_TILES,
|
||||
CMSettings.Secure.QS_USE_MAIN_TILES,
|
||||
CMSettings.Secure.NAVIGATION_RING_TARGETS[0],
|
||||
CMSettings.Secure.NAVIGATION_RING_TARGETS[1],
|
||||
CMSettings.Secure.NAVIGATION_RING_TARGETS[2],
|
||||
CMSettings.Secure.RECENTS_LONG_PRESS_ACTIVITY,
|
||||
CMSettings.Secure.ADB_NOTIFY,
|
||||
CMSettings.Secure.ADB_PORT,
|
||||
CMSettings.Secure.DEVICE_HOSTNAME,
|
||||
CMSettings.Secure.KILL_APP_LONGPRESS_BACK,
|
||||
CMSettings.Secure.PROTECTED_COMPONENTS,
|
||||
CMSettings.Secure.LIVE_DISPLAY_COLOR_MATRIX,
|
||||
CMSettings.Secure.ADVANCED_REBOOT,
|
||||
CMSettings.Secure.THEME_PREV_BOOT_API_LEVEL,
|
||||
CMSettings.Secure.LOCKSCREEN_TARGETS,
|
||||
CMSettings.Secure.RING_HOME_BUTTON_BEHAVIOR,
|
||||
CMSettings.Secure.PRIVACY_GUARD_DEFAULT,
|
||||
CMSettings.Secure.PRIVACY_GUARD_NOTIFICATION,
|
||||
CMSettings.Secure.DEVELOPMENT_SHORTCUT,
|
||||
CMSettings.Secure.PERFORMANCE_PROFILE,
|
||||
CMSettings.Secure.APP_PERFORMANCE_PROFILES_ENABLED,
|
||||
CMSettings.Secure.QS_LOCATION_ADVANCED,
|
||||
CMSettings.Secure.LOCKSCREEN_VISUALIZER_ENABLED,
|
||||
CMSettings.Secure.LOCK_PASS_TO_SECURITY_VIEW
|
||||
LineageSettings.Secure.ADVANCED_MODE,
|
||||
LineageSettings.Secure.BUTTON_BACKLIGHT_TIMEOUT,
|
||||
LineageSettings.Secure.BUTTON_BRIGHTNESS,
|
||||
LineageSettings.Secure.DEFAULT_THEME_COMPONENTS,
|
||||
LineageSettings.Secure.DEFAULT_THEME_PACKAGE,
|
||||
LineageSettings.Secure.DEV_FORCE_SHOW_NAVBAR,
|
||||
LineageSettings.Secure.KEYBOARD_BRIGHTNESS,
|
||||
LineageSettings.Secure.POWER_MENU_ACTIONS,
|
||||
LineageSettings.Secure.STATS_COLLECTION,
|
||||
LineageSettings.Secure.QS_SHOW_BRIGHTNESS_SLIDER,
|
||||
LineageSettings.Secure.QS_TILES,
|
||||
LineageSettings.Secure.QS_USE_MAIN_TILES,
|
||||
LineageSettings.Secure.NAVIGATION_RING_TARGETS[0],
|
||||
LineageSettings.Secure.NAVIGATION_RING_TARGETS[1],
|
||||
LineageSettings.Secure.NAVIGATION_RING_TARGETS[2],
|
||||
LineageSettings.Secure.RECENTS_LONG_PRESS_ACTIVITY,
|
||||
LineageSettings.Secure.ADB_NOTIFY,
|
||||
LineageSettings.Secure.ADB_PORT,
|
||||
LineageSettings.Secure.DEVICE_HOSTNAME,
|
||||
LineageSettings.Secure.KILL_APP_LONGPRESS_BACK,
|
||||
LineageSettings.Secure.PROTECTED_COMPONENTS,
|
||||
LineageSettings.Secure.LIVE_DISPLAY_COLOR_MATRIX,
|
||||
LineageSettings.Secure.ADVANCED_REBOOT,
|
||||
LineageSettings.Secure.THEME_PREV_BOOT_API_LEVEL,
|
||||
LineageSettings.Secure.LOCKSCREEN_TARGETS,
|
||||
LineageSettings.Secure.RING_HOME_BUTTON_BEHAVIOR,
|
||||
LineageSettings.Secure.PRIVACY_GUARD_DEFAULT,
|
||||
LineageSettings.Secure.PRIVACY_GUARD_NOTIFICATION,
|
||||
LineageSettings.Secure.DEVELOPMENT_SHORTCUT,
|
||||
LineageSettings.Secure.PERFORMANCE_PROFILE,
|
||||
LineageSettings.Secure.APP_PERFORMANCE_PROFILES_ENABLED,
|
||||
LineageSettings.Secure.QS_LOCATION_ADVANCED,
|
||||
LineageSettings.Secure.LOCKSCREEN_VISUALIZER_ENABLED,
|
||||
LineageSettings.Secure.LOCK_PASS_TO_SECURITY_VIEW
|
||||
};
|
||||
|
||||
/**
|
||||
@@ -3051,8 +3051,8 @@ public final class CMSettings {
|
||||
public static boolean shouldInterceptSystemProvider(String key) {
|
||||
switch (key) {
|
||||
// some apps still query Settings.System.DEV_FORCE_SHOW_NAVBAR, and it was moved to
|
||||
// Settings.Secure, then CMSettings.Secure. Forward queries from Settings.Secure
|
||||
// to CMSettings.Secure here just in case an app stuck with the Settings.Secure call
|
||||
// Settings.Secure, then LineageSettings.Secure. Forward queries from Settings.Secure
|
||||
// to LineageSettings.Secure here just in case an app stuck with the Settings.Secure call
|
||||
case DEV_FORCE_SHOW_NAVBAR:
|
||||
return true;
|
||||
default:
|
||||
@@ -3062,17 +3062,17 @@ public final class CMSettings {
|
||||
}
|
||||
|
||||
/**
|
||||
* Global settings, containing miscellaneous CM global preferences. This
|
||||
* Global settings, containing miscellaneous Lineage global preferences. This
|
||||
* table holds simple name/value pairs. There are convenience
|
||||
* functions for accessing individual settings entries.
|
||||
*/
|
||||
public static final class Global extends Settings.NameValueTable {
|
||||
public static final Uri CONTENT_URI = Uri.parse("content://" + AUTHORITY + "/global");
|
||||
|
||||
public static final String SYS_PROP_CM_SETTING_VERSION = "sys.cm_settings_global_version";
|
||||
public static final String SYS_PROP_LINEAGE_SETTING_VERSION = "sys.lineage_settings_global_version";
|
||||
|
||||
private static final NameValueCache sNameValueCache = new NameValueCache(
|
||||
SYS_PROP_CM_SETTING_VERSION,
|
||||
SYS_PROP_LINEAGE_SETTING_VERSION,
|
||||
CONTENT_URI,
|
||||
CALL_METHOD_GET_GLOBAL,
|
||||
CALL_METHOD_PUT_GLOBAL);
|
||||
@@ -3197,29 +3197,29 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not an integer.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
*/
|
||||
public static int getInt(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getIntForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static int getIntForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String v = getStringForUser(cr, name, userId);
|
||||
try {
|
||||
return Integer.parseInt(v);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3285,28 +3285,28 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not an integer.
|
||||
*/
|
||||
public static long getLong(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getLongForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static long getLongForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String valString = getStringForUser(cr, name, userId);
|
||||
try {
|
||||
return Long.parseLong(valString);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3370,32 +3370,32 @@ public final class CMSettings {
|
||||
* <p>
|
||||
* This version does not take a default value. If the setting has not
|
||||
* been set, or the string value is not a number,
|
||||
* it throws {@link CMSettingNotFoundException}.
|
||||
* it throws {@link LineageSettingNotFoundException}.
|
||||
*
|
||||
* @param cr The ContentResolver to access.
|
||||
* @param name The name of the setting to retrieve.
|
||||
*
|
||||
* @throws CMSettingNotFoundException Thrown if a setting by the given
|
||||
* @throws LineageSettingNotFoundException Thrown if a setting by the given
|
||||
* name can't be found or the setting value is not a float.
|
||||
*
|
||||
* @return The setting's current value.
|
||||
*/
|
||||
public static float getFloat(ContentResolver cr, String name)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
return getFloatForUser(cr, name, UserHandle.myUserId());
|
||||
}
|
||||
|
||||
/** @hide */
|
||||
public static float getFloatForUser(ContentResolver cr, String name, int userId)
|
||||
throws CMSettingNotFoundException {
|
||||
throws LineageSettingNotFoundException {
|
||||
String v = getStringForUser(cr, name, userId);
|
||||
if (v == null) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
try {
|
||||
return Float.parseFloat(v);
|
||||
} catch (NumberFormatException e) {
|
||||
throw new CMSettingNotFoundException(name);
|
||||
throw new LineageSettingNotFoundException(name);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3470,8 +3470,8 @@ public final class CMSettings {
|
||||
/**
|
||||
* Global temperature unit in which the weather data will be reported
|
||||
* Valid values are:
|
||||
* <p>{@link cyanogenmod.providers.WeatherContract.WeatherColumns.TempUnit#CELSIUS}</p>
|
||||
* <p>{@link cyanogenmod.providers.WeatherContract.WeatherColumns.TempUnit#FAHRENHEIT}</p>
|
||||
* <p>{@link lineageos.providers.WeatherContract.WeatherColumns.TempUnit#CELSIUS}</p>
|
||||
* <p>{@link lineageos.providers.WeatherContract.WeatherColumns.TempUnit#FAHRENHEIT}</p>
|
||||
*/
|
||||
public static final String WEATHER_TEMPERATURE_UNIT = "weather_temperature_unit";
|
||||
|
||||
@@ -3493,11 +3493,11 @@ public final class CMSettings {
|
||||
* @hide
|
||||
*/
|
||||
public static final String[] LEGACY_GLOBAL_SETTINGS = new String[]{
|
||||
CMSettings.Global.WAKE_WHEN_PLUGGED_OR_UNPLUGGED,
|
||||
CMSettings.Global.POWER_NOTIFICATIONS_VIBRATE,
|
||||
CMSettings.Global.POWER_NOTIFICATIONS_RINGTONE,
|
||||
CMSettings.Global.ZEN_DISABLE_DUCKING_DURING_MEDIA_PLAYBACK,
|
||||
CMSettings.Global.WIFI_AUTO_PRIORITIES_CONFIGURATION
|
||||
LineageSettings.Global.WAKE_WHEN_PLUGGED_OR_UNPLUGGED,
|
||||
LineageSettings.Global.POWER_NOTIFICATIONS_VIBRATE,
|
||||
LineageSettings.Global.POWER_NOTIFICATIONS_RINGTONE,
|
||||
LineageSettings.Global.ZEN_DISABLE_DUCKING_DURING_MEDIA_PLAYBACK,
|
||||
LineageSettings.Global.WIFI_AUTO_PRIORITIES_CONFIGURATION
|
||||
};
|
||||
|
||||
/**
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.providers;
|
||||
package lineageos.providers;
|
||||
|
||||
import android.net.Uri;
|
||||
|
||||
@@ -26,7 +26,7 @@ import android.net.Uri;
|
||||
*/
|
||||
public class ThemesContract {
|
||||
/** The authority for the themes provider */
|
||||
public static final String AUTHORITY = "com.cyanogenmod.themes";
|
||||
public static final String AUTHORITY = "org.lineageos.themes";
|
||||
/** A content:// style uri to the authority for the themes provider */
|
||||
public static final Uri AUTHORITY_URI = Uri.parse("content://" + AUTHORITY);
|
||||
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.providers;
|
||||
package lineageos.providers;
|
||||
|
||||
import android.net.Uri;
|
||||
|
||||
@@ -26,7 +26,7 @@ public class WeatherContract {
|
||||
/**
|
||||
* The authority of the weather content provider
|
||||
*/
|
||||
public static final String AUTHORITY = "com.cyanogenmod.weather";
|
||||
public static final String AUTHORITY = "org.lineageos.weather";
|
||||
|
||||
/**
|
||||
* A content:// style uri to the authority for the weather provider
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package cyanogenmod.themes;
|
||||
package lineageos.themes;
|
||||
|
||||
/** {@hide} */
|
||||
oneway interface IThemeChangeListener {
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user