OmniControl: Switch to our OmniRom platform library
Change-Id: Ie0eebf23050ab48f904e1b07bac8e45ad7dec1ce
diff --git a/Android.bp b/Android.bp
index 27154ab..1a3de80 100644
--- a/Android.bp
+++ b/Android.bp
@@ -22,7 +22,7 @@
"com.google.android.material_material",
"androidx.recyclerview_recyclerview",
"OmniLib",
- "OmniLibCore",
+ "OmniPreference",
"OmniPreferenceTheme",
"SystemUISharedLib",
],
diff --git a/app/src/main/java/org/omnirom/control/AbstractSettingsFragment.kt b/app/src/main/java/org/omnirom/control/AbstractSettingsFragment.kt
index 5ce7592..deeb102 100644
--- a/app/src/main/java/org/omnirom/control/AbstractSettingsFragment.kt
+++ b/app/src/main/java/org/omnirom/control/AbstractSettingsFragment.kt
@@ -22,10 +22,10 @@
import androidx.preference.PreferenceFragmentCompat
import org.omnirom.control.search.PreferenceXmlParserUtils
import org.omnirom.control.search.PreferenceXmlParserUtils.METADATA_KEY
-import org.omnirom.omnilib.preference.SecureCheckBoxPreference
-import org.omnirom.omnilib.preference.SecureSettingSwitchPreference
-import org.omnirom.omnilib.preference.SystemCheckBoxPreference
-import org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+import omnirom.preference.SecureCheckBoxPreference
+import omnirom.preference.SecureSettingSwitchPreference
+import omnirom.preference.SystemCheckBoxPreference
+import omnirom.preference.SystemSettingSwitchPreference
abstract class AbstractSettingsFragment() : PreferenceFragmentCompat() {
diff --git a/app/src/main/java/org/omnirom/control/DialerSettingsFragment.kt b/app/src/main/java/org/omnirom/control/DialerSettingsFragment.kt
index 159f452..a96baac 100644
--- a/app/src/main/java/org/omnirom/control/DialerSettingsFragment.kt
+++ b/app/src/main/java/org/omnirom/control/DialerSettingsFragment.kt
@@ -26,7 +26,7 @@
import androidx.preference.Preference
import androidx.preference.PreferenceFragmentCompat
-import org.omnirom.omnilibcore.utils.DeviceUtils
+import org.omnirom.omnilib.utils.DeviceUtils
class DialerSettingsFragment : AbstractSettingsFragment() {
companion object {
diff --git a/app/src/main/java/org/omnirom/control/GridViewFragment.kt b/app/src/main/java/org/omnirom/control/GridViewFragment.kt
index addd7e2..b88f436 100644
--- a/app/src/main/java/org/omnirom/control/GridViewFragment.kt
+++ b/app/src/main/java/org/omnirom/control/GridViewFragment.kt
@@ -30,7 +30,7 @@
import com.android.internal.util.ArrayUtils;
import org.omnirom.control.search.SearchFragment
-import org.omnirom.omnilibcore.utils.DeviceUtils
+import org.omnirom.omnilib.utils.DeviceUtils
class GridViewFragment() : Fragment() {
private lateinit var gridView: GridView
diff --git a/app/src/main/java/org/omnirom/omnilib/preference/SecureCheckBoxPreference.java b/app/src/main/java/org/omnirom/omnilib/preference/SecureCheckBoxPreference.java
deleted file mode 100644
index bf0b228..0000000
--- a/app/src/main/java/org/omnirom/omnilib/preference/SecureCheckBoxPreference.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*
- * Copyright (C) 2013 The CyanogenMod project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.omnirom.omnilib.preference;
-
-import android.content.Context;
-import android.provider.Settings;
-import android.util.AttributeSet;
-
-import androidx.preference.CheckBoxPreference;
-
-public class SecureCheckBoxPreference extends CheckBoxPreference {
- public SecureCheckBoxPreference(Context context, AttributeSet attrs, int defStyle) {
- super(context, attrs, defStyle);
- }
-
- public SecureCheckBoxPreference(Context context, AttributeSet attrs) {
- super(context, attrs);
- }
-
- public SecureCheckBoxPreference(Context context) {
- super(context, null);
- }
-
- @Override
- protected boolean persistBoolean(boolean value) {
- if (shouldPersist()) {
- if (value == getPersistedBoolean(!value)) {
- // It's already there, so the same as persisting
- return true;
- }
- try {
- Settings.Secure.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
- } catch (SecurityException e) {
-
- }
- return true;
- }
- return false;
- }
-
- @Override
- protected boolean getPersistedBoolean(boolean defaultReturnValue) {
- if (!shouldPersist()) {
- return defaultReturnValue;
- }
-
- return Settings.Secure.getInt(getContext().getContentResolver(),
- getKey(), defaultReturnValue ? 1 : 0) != 0;
- }
-
- @Override
- protected void onSetInitialValue(boolean restoreValue, Object defaultValue) {
- setChecked(Settings.Secure.getString(getContext().getContentResolver(), getKey()) != null ? getPersistedBoolean(isChecked())
- : (Boolean) defaultValue);
- }
-}
diff --git a/app/src/main/java/org/omnirom/omnilib/preference/SecureSettingSwitchPreference.java b/app/src/main/java/org/omnirom/omnilib/preference/SecureSettingSwitchPreference.java
deleted file mode 100644
index 65b4eaa..0000000
--- a/app/src/main/java/org/omnirom/omnilib/preference/SecureSettingSwitchPreference.java
+++ /dev/null
@@ -1,69 +0,0 @@
-/*
- * Copyright (C) 2015 The CyanogenMod project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.omnirom.omnilib.preference;
-
-import android.content.Context;
-import androidx.preference.SwitchPreference;
-import android.util.AttributeSet;
-
-import android.provider.Settings;
-
-public class SecureSettingSwitchPreference extends SwitchPreference {
- public SecureSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
- super(context, attrs, defStyle);
- }
-
- public SecureSettingSwitchPreference(Context context, AttributeSet attrs) {
- super(context, attrs);
- }
-
- public SecureSettingSwitchPreference(Context context) {
- super(context, null);
- }
-
- @Override
- protected boolean persistBoolean(boolean value) {
- if (shouldPersist()) {
- if (value == getPersistedBoolean(!value)) {
- // It's already there, so the same as persisting
- return true;
- }
- try {
- Settings.Secure.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
- } catch (SecurityException e){
-
- }
- return true;
- }
- return false;
- }
-
- @Override
- protected boolean getPersistedBoolean(boolean defaultReturnValue) {
- if (!shouldPersist()) {
- return defaultReturnValue;
- }
- return Settings.Secure.getInt(getContext().getContentResolver(),
- getKey(), defaultReturnValue ? 1 : 0) != 0;
- }
-
- @Override
- protected void onSetInitialValue(boolean restoreValue, Object defaultValue) {
- setChecked(Settings.Secure.getString(getContext().getContentResolver(), getKey()) != null ? getPersistedBoolean(isChecked())
- : (Boolean) defaultValue);
- }
-}
diff --git a/app/src/main/java/org/omnirom/omnilib/preference/SeekBarPreference.java b/app/src/main/java/org/omnirom/omnilib/preference/SeekBarPreference.java
deleted file mode 100644
index 49b62ca..0000000
--- a/app/src/main/java/org/omnirom/omnilib/preference/SeekBarPreference.java
+++ /dev/null
@@ -1,221 +0,0 @@
-/*
- ** Copyright 2013, The ChameleonOS Open Source Project
- ** Copyright 2016, The OmniROM Project
- **
- ** Licensed under the Apache License, Version 2.0 (the "License");
- ** you may not use this file except in compliance with the License.
- ** You may obtain a copy of the License at
- **
- ** http://www.apache.org/licenses/LICENSE-2.0
- **
- ** Unless required by applicable law or agreed to in writing, software
- ** distributed under the License is distributed on an "AS IS" BASIS,
- ** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- ** See the License for the specific language governing permissions and
- ** limitations under the License.
- */
-package org.omnirom.omnilib.preference;
-
-import android.content.Context;
-import android.content.res.TypedArray;
-import android.util.TypedValue;
-import androidx.preference.Preference;
-import androidx.preference.PreferenceViewHolder;
-import android.util.AttributeSet;
-import android.util.Log;
-import android.view.LayoutInflater;
-import android.view.View;
-import android.view.ViewGroup;
-import android.view.ViewParent;
-import android.widget.SeekBar;
-import android.widget.SeekBar.OnSeekBarChangeListener;
-import android.widget.TextView;
-
-import org.omnirom.omnilib.R;
-
-public class SeekBarPreference extends Preference implements OnSeekBarChangeListener {
-
- private final String TAG = getClass().getName();
-
- private static final String ANDROIDNS = "http://schemas.android.com/apk/res/android";
- private static final int DEFAULT_VALUE = 50;
-
- private int mMaxValue = 100;
- private int mMinValue = 0;
- private int mInterval = 1;
- private int mCurrentValue;
- private String mUnitsLeft = "";
- private String mUnitsRight = "";
- private SeekBar mSeekBar;
- private TextView mStatusText;
-
- public SeekBarPreference(Context context, AttributeSet attrs) {
- super(context, attrs);
- initPreference(context, attrs);
- }
-
- public SeekBarPreference(Context context, AttributeSet attrs, int defStyle) {
- super(context, attrs, defStyle);
- initPreference(context, attrs);
- }
-
- private void initPreference(Context context, AttributeSet attrs) {
- setValuesFromXml(context, attrs);
- setLayoutResource(R.layout.preference_seek_bar);
- }
-
- private void setValuesFromXml(Context context, AttributeSet attrs) {
- mMaxValue = attrs.getAttributeIntValue(ANDROIDNS, "max", 100);
-
- final TypedArray attributes = context.obtainStyledAttributes(attrs,
- R.styleable.SeekBarPreference);
-
- TypedValue minAttr =
- attributes.peekValue(R.styleable.SeekBarPreference_min);
- if (minAttr != null && minAttr.type == TypedValue.TYPE_INT_DEC) {
- mMinValue = minAttr.data;
- }
-
- TypedValue unitsLeftAttr =
- attributes.peekValue(R.styleable.SeekBarPreference_unitsLeft);
- CharSequence data = null;
- if (unitsLeftAttr != null && unitsLeftAttr.type == TypedValue.TYPE_STRING) {
- if (unitsLeftAttr.resourceId != 0) {
- data = context.getText(unitsLeftAttr.resourceId);
- } else {
- data = unitsLeftAttr.string;
- }
- }
- mUnitsLeft = (data == null) ? "" : data.toString();
-
- TypedValue unitsRightAttr =
- attributes.peekValue(R.styleable.SeekBarPreference_unitsRight);
- data = null;
- if (unitsRightAttr != null && unitsRightAttr.type == TypedValue.TYPE_STRING) {
- if (unitsRightAttr.resourceId != 0) {
- data = context.getText(unitsRightAttr.resourceId);
- } else {
- data = unitsRightAttr.string;
- }
- }
- mUnitsRight = (data == null) ? "" : data.toString();
-
- TypedValue intervalAttr =
- attributes.peekValue(R.styleable.SeekBarPreference_interval);
- if (intervalAttr != null && intervalAttr.type == TypedValue.TYPE_INT_DEC) {
- mInterval = intervalAttr.data;
- }
-
- attributes.recycle();
- }
-
- @Override
- public void onDependencyChanged(Preference dependency, boolean disableDependent) {
- super.onDependencyChanged(dependency, disableDependent);
- this.setShouldDisableView(true);
- if (mSeekBar != null) {
- mSeekBar.setEnabled(!disableDependent);
- }
- }
-
- @Override
- public void onBindViewHolder(PreferenceViewHolder holder) {
- super.onBindViewHolder(holder);
-
- mSeekBar = (SeekBar) holder.findViewById(R.id.seekbar);
- mSeekBar.setMax(mMaxValue - mMinValue);
- mSeekBar.setProgress(mCurrentValue - mMinValue);
- mSeekBar.setOnSeekBarChangeListener(this);
- mSeekBar.setEnabled(isEnabled());
-
- mStatusText = (TextView) holder.findViewById(R.id.seekBarPrefValue);
- mStatusText.setText(String.valueOf(mCurrentValue));
- mStatusText.setMinimumWidth(30);
-
- TextView unitsRight = (TextView) holder.findViewById(R.id.seekBarPrefUnitsRight);
- unitsRight.setText(mUnitsRight);
- TextView unitsLeft = (TextView) holder.findViewById(R.id.seekBarPrefUnitsLeft);
- unitsLeft.setText(mUnitsLeft);
- }
-
- @Override
- public void onProgressChanged(SeekBar seekBar, int progress, boolean fromUser) {
- int newValue = progress + mMinValue;
-
- if (newValue > mMaxValue) {
- newValue = mMaxValue;
- } else if (newValue < mMinValue) {
- newValue = mMinValue;
- } else if (mInterval != 1 && newValue % mInterval != 0) {
- newValue = Math.round(((float) newValue) / mInterval) * mInterval;
- }
-
- // change rejected, revert to the previous value
- if (!callChangeListener(newValue)) {
- seekBar.setProgress(mCurrentValue - mMinValue);
- return;
- }
-
- // change accepted, store it
- mCurrentValue = newValue;
- mStatusText.setText(String.valueOf(newValue));
- persistInt(newValue);
- }
-
- @Override
- public void onStartTrackingTouch(SeekBar seekBar) {
- }
-
- @Override
- public void onStopTrackingTouch(SeekBar seekBar) {
- notifyChanged();
- }
-
- @Override
- protected Object onGetDefaultValue(TypedArray ta, int index) {
- int defaultValue = ta.getInt(index, DEFAULT_VALUE);
- return defaultValue;
- }
-
- @Override
- protected void onSetInitialValue(boolean restoreValue, Object defaultValue) {
- if (restoreValue) {
- mCurrentValue = getPersistedInt(mCurrentValue);
- } else {
- int temp = 0;
- try {
- temp = (Integer) defaultValue;
- } catch (Exception ex) {
- Log.e(TAG, "Invalid default value: " + defaultValue.toString());
- }
- persistInt(temp);
- mCurrentValue = temp;
- }
- }
-
- public void setValue(int value) {
- mCurrentValue = value;
- }
-
- public void setMaxValue(int value) {
- mMaxValue = value;
- if (mSeekBar != null) {
- mSeekBar.setMax(mMaxValue - mMinValue);
- }
- }
-
- public void setMinValue(int value) {
- mMinValue = value;
- if (mSeekBar != null) {
- mSeekBar.setMax(mMaxValue - mMinValue);
- }
- }
-
- @Override
- public void setEnabled(boolean enabled) {
- if (mSeekBar != null) {
- mSeekBar.setEnabled(enabled);
- }
- super.setEnabled(enabled);
- }
-}
diff --git a/app/src/main/java/org/omnirom/omnilib/preference/SystemCheckBoxPreference.java b/app/src/main/java/org/omnirom/omnilib/preference/SystemCheckBoxPreference.java
deleted file mode 100644
index 9b025ea..0000000
--- a/app/src/main/java/org/omnirom/omnilib/preference/SystemCheckBoxPreference.java
+++ /dev/null
@@ -1,67 +0,0 @@
-/*
- * Copyright (C) 2013 The CyanogenMod project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.omnirom.omnilib.preference;
-
-import android.content.Context;
-import androidx.preference.CheckBoxPreference;
-import android.provider.Settings;
-import android.util.AttributeSet;
-
-public class SystemCheckBoxPreference extends CheckBoxPreference {
- public SystemCheckBoxPreference(Context context, AttributeSet attrs, int defStyle) {
- super(context, attrs, defStyle);
- }
-
- public SystemCheckBoxPreference(Context context, AttributeSet attrs) {
- super(context, attrs);
- }
-
- public SystemCheckBoxPreference(Context context) {
- super(context, null);
- }
-
- @Override
- protected boolean persistBoolean(boolean value) {
- if (shouldPersist()) {
- if (value == getPersistedBoolean(!value)) {
- // It's already there, so the same as persisting
- return true;
- }
- if (Settings.System.canWrite(getContext())) {
- Settings.System.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
- }
- return true;
- }
- return false;
- }
-
- @Override
- protected boolean getPersistedBoolean(boolean defaultReturnValue) {
- if (!shouldPersist()) {
- return defaultReturnValue;
- }
-
- return Settings.System.getInt(getContext().getContentResolver(),
- getKey(), defaultReturnValue ? 1 : 0) != 0;
- }
-
- @Override
- protected void onSetInitialValue(boolean restoreValue, Object defaultValue) {
- setChecked(Settings.System.getString(getContext().getContentResolver(), getKey()) != null ? getPersistedBoolean(isChecked())
- : (Boolean) defaultValue);
- }
-}
diff --git a/app/src/main/java/org/omnirom/omnilib/preference/SystemSettingSwitchPreference.java b/app/src/main/java/org/omnirom/omnilib/preference/SystemSettingSwitchPreference.java
deleted file mode 100644
index aec0725..0000000
--- a/app/src/main/java/org/omnirom/omnilib/preference/SystemSettingSwitchPreference.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*
- * Copyright (C) 2013 The CyanogenMod project
- *
- * Licensed under the Apache License, Version 2.0 (the "License");
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an "AS IS" BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-package org.omnirom.omnilib.preference;
-
-import android.content.Context;
-import android.provider.Settings;
-import androidx.preference.SwitchPreference;
-import android.util.AttributeSet;
-
-public class SystemSettingSwitchPreference extends SwitchPreference {
- public SystemSettingSwitchPreference(Context context, AttributeSet attrs, int defStyle) {
- super(context, attrs, defStyle);
- }
-
- public SystemSettingSwitchPreference(Context context, AttributeSet attrs) {
- super(context, attrs);
- }
-
- public SystemSettingSwitchPreference(Context context) {
- super(context, null);
- }
-
- @Override
- protected boolean persistBoolean(boolean value) {
- if (shouldPersist()) {
- if (value == getPersistedBoolean(!value)) {
- // It's already there, so the same as persisting
- return true;
- }
- if (Settings.System.canWrite(getContext())) {
- Settings.System.putInt(getContext().getContentResolver(), getKey(), value ? 1 : 0);
- }
- return true;
- }
- return false;
- }
-
- @Override
- protected boolean getPersistedBoolean(boolean defaultReturnValue) {
- if (!shouldPersist()) {
- return defaultReturnValue;
- }
- return Settings.System.getInt(getContext().getContentResolver(),
- getKey(), defaultReturnValue ? 1 : 0) != 0;
- }
-
- @Override
- protected void onSetInitialValue(boolean restoreValue, Object defaultValue) {
- setChecked(Settings.System.getString(getContext().getContentResolver(), getKey()) != null ? getPersistedBoolean(isChecked())
- : (Boolean) defaultValue);
- }
-}
diff --git a/app/src/main/res/xml/bars_settings_preferences.xml b/app/src/main/res/xml/bars_settings_preferences.xml
index e816932..97263b0 100644
--- a/app/src/main/res/xml/bars_settings_preferences.xml
+++ b/app/src/main/res/xml/bars_settings_preferences.xml
@@ -4,31 +4,31 @@
android:key="statusbar_settings_category"
android:title="@string/statusbar_settings_category">
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="status_bar_bt_battery"
android:title="@string/status_bar_bt_battery_title"
android:summary="@string/status_bar_bt_battery_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SecureSettingSwitchPreference
+ <omnirom.preference.SecureSettingSwitchPreference
android:key="clock_seconds"
android:title="@string/status_bar_clock_seconds_title"
android:summary="@string/status_bar_clock_seconds_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="status_bar_alarm"
android:title="@string/status_bar_alarm_title"
android:summary="@string/status_bar_alarm_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="use_old_mobiletype"
android:title="@string/use_old_mobiletype_title"
android:summary="@string/use_old_mobiletype_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="hide_roaming_icon"
android:title="@string/hide_roaming_icon_title"
android:summary="@string/hide_roaming_icon_summary"
@@ -41,13 +41,13 @@
android:key="category_navigationbar"
android:title="@string/navigationbar_title">
- <!--<org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <!--<omnirom.preference.SystemSettingSwitchPreference
android:key="navbar_visibility"
android:title="@string/navigation_bar_show_title"
android:summary="@string/navigation_bar_show_summary"
android:defaultValue="true"/>-->
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="navigation_bar_menu_arrow_keys"
android:title="@string/navigation_bar_menu_arrow_keys_title"
android:summary="@string/navigation_bar_menu_arrow_keys_summary"
@@ -59,7 +59,7 @@
android:key="category_taskbar"
android:title="@string/taskbar_title">
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="taskbar_disable"
android:title="@string/taskbar_disable_title"
android:summary="@string/taskbar_disable_summary"
diff --git a/app/src/main/res/xml/battery_light_settings_preferences.xml b/app/src/main/res/xml/battery_light_settings_preferences.xml
index bbc8cf7..7a94455 100644
--- a/app/src/main/res/xml/battery_light_settings_preferences.xml
+++ b/app/src/main/res/xml/battery_light_settings_preferences.xml
@@ -8,7 +8,7 @@
android:widgetLayout="@layout/reset_default"
android:key="reset_to_default_key" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="battery_light_enabled"
android:title="@string/battery_light_enable"
android:defaultValue="false"/>
@@ -17,19 +17,19 @@
android:key="general_section"
android:title="@string/notification_light_general_title">
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="battery_light_pulse"
android:title="@string/battery_low_pulse_title"
android:dependency="battery_light_enabled"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="battery_light_only_fully_charged"
android:title="@string/battery_light_only_full_charge_title"
android:dependency="battery_light_enabled"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="battery_light_allow_on_dnd"
android:title="@string/notification_light_zen_mode"
android:dependency="battery_light_enabled"
@@ -42,25 +42,25 @@
android:title="@string/battery_light_list_title"
android:dependency="battery_light_enabled" >
- <org.omnirom.omnilib.preference.SystemSettingsColorSelectPreference
+ <omnirom.preference.SystemSettingsColorSelectPreference
android:key="battery_light_low_color"
omnilib:ledPreview="true"
android:title="@string/battery_light_low_color_title"
android:defaultValue="0" />
- <org.omnirom.omnilib.preference.SystemSettingsColorSelectPreference
+ <omnirom.preference.SystemSettingsColorSelectPreference
android:key="battery_light_medium_color"
omnilib:ledPreview="true"
android:title="@string/battery_light_medium_color_title"
android:defaultValue="0" />
- <org.omnirom.omnilib.preference.SystemSettingsColorSelectPreference
+ <omnirom.preference.SystemSettingsColorSelectPreference
android:key="battery_light_full_color"
omnilib:ledPreview="true"
android:title="@string/battery_light_full_color_title"
android:defaultValue="0" />
- <org.omnirom.omnilib.preference.SystemSettingsColorSelectPreference
+ <omnirom.preference.SystemSettingsColorSelectPreference
android:key="battery_light_really_full_color"
omnilib:ledPreview="true"
android:title="@string/battery_light_really_full_color_title"
@@ -73,13 +73,13 @@
android:title="@string/fast_color_cat_title"
android:dependency="battery_light_enabled" >
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="fast_charging_led_enabled"
android:title="@string/fast_charging_led_enabled_title"
android:summary="@string/fast_charging_led_enabled_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingsColorSelectPreference
+ <omnirom.preference.SystemSettingsColorSelectPreference
android:key="fast_battery_light_color"
omnilib:ledPreview="true"
android:title="@string/fast_charging_light_color_title"
diff --git a/app/src/main/res/xml/button_settings_preferences.xml b/app/src/main/res/xml/button_settings_preferences.xml
index fdd4930..138bb08 100644
--- a/app/src/main/res/xml/button_settings_preferences.xml
+++ b/app/src/main/res/xml/button_settings_preferences.xml
@@ -7,13 +7,13 @@
android:key="button_power"
android:title="@string/global_actions_power_title" >
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="advanced_reboot"
android:title="@string/global_actions_advanced_reboot_title"
android:summary="@string/global_actions_advanced_reboot_summary_new"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="long_press_power_torch"
android:title="@string/long_press_power_torch_title"
android:summary="@string/long_press_power_torch_summary"
diff --git a/app/src/main/res/xml/dialer_settings_preferences.xml b/app/src/main/res/xml/dialer_settings_preferences.xml
index 138ec3e..6df10fc 100644
--- a/app/src/main/res/xml/dialer_settings_preferences.xml
+++ b/app/src/main/res/xml/dialer_settings_preferences.xml
@@ -4,19 +4,19 @@
android:key="dialer_settings_category"
android:title="@string/dialer_settings_title">
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="vibrate_on_connect"
android:title="@string/incall_vibrate_connect_title"
android:summary="@string/incall_vibrate_connect_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="vibrate_on_callwaiting"
android:title="@string/incall_vibrate_call_wait_title"
android:summary="@string/incall_vibrate_call_wait_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="vibrate_on_disconnect"
android:title="@string/incall_vibrate_disconnect_title"
android:summary="@string/incall_vibrate_disconnect_summary"
diff --git a/app/src/main/res/xml/lockscreen_settings_preferences.xml b/app/src/main/res/xml/lockscreen_settings_preferences.xml
index ae84612..acf6aa9 100644
--- a/app/src/main/res/xml/lockscreen_settings_preferences.xml
+++ b/app/src/main/res/xml/lockscreen_settings_preferences.xml
@@ -2,13 +2,13 @@
android:key="lockscreen_item"
android:title="@string/lockscreen_item_title">
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:defaultValue="false"
android:key="doze_on_charge"
android:title="@string/doze_on_charge_title"
android:summary="@string/doze_on_charge_summary" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:defaultValue="false"
android:key="lockscreen_weather_enabled"
android:summary="@string/lockscreen_weather_summary"
@@ -24,19 +24,19 @@
android:targetPackage="org.omnirom.omnijaws" />
</Preference>
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:defaultValue="true"
android:key="lockscreen_alarm_enabled"
android:summary="@string/lockscreen_alarm_summary"
android:title="@string/lockscreen_alarm_title" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:defaultValue="false"
android:key="lockscreen_dnd_enabled"
android:summary="@string/lockscreen_dnd_summary"
android:title="@string/lockscreen_dnd_title" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:defaultValue="true"
android:key="lockscreen_clock_colored"
android:summary="@string/lockscreen_clock_colored_summary"
diff --git a/app/src/main/res/xml/more_settings_preferences.xml b/app/src/main/res/xml/more_settings_preferences.xml
index fc8bbd5..0969ae4 100644
--- a/app/src/main/res/xml/more_settings_preferences.xml
+++ b/app/src/main/res/xml/more_settings_preferences.xml
@@ -6,7 +6,7 @@
android:key="category_system"
android:title="@string/system_category">
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="show_cpu_overlay"
android:title="@string/show_cpu_title"
android:summary="@string/show_cpu_summary"
diff --git a/app/src/main/res/xml/qs_settings_preferences.xml b/app/src/main/res/xml/qs_settings_preferences.xml
index ac049e6..2b14529 100644
--- a/app/src/main/res/xml/qs_settings_preferences.xml
+++ b/app/src/main/res/xml/qs_settings_preferences.xml
@@ -5,19 +5,19 @@
android:key="qs_layout_category"
android:title="@string/qs_layout_title">
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="qs_tile_vertical_layout"
android:title="@string/qs_tile_vertical_layout_title"
android:summary="@string/qs_tile_vertical_layout_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SystemSettingSwitchPreference
+ <omnirom.preference.SystemSettingSwitchPreference
android:key="qs_tile_label_hide"
android:title="@string/qs_tile_label_hide_title"
android:summary="@string/qs_tile_label_hide_summary"
android:defaultValue="false" />
- <org.omnirom.omnilib.preference.SeekBarPreference
+ <omnirom.preference.SeekBarPreference
android:key="qs_layout_columns"
android:title="@string/qs_layout_columns_title"
android:summary="@string/qs_layout_columns_summary"
@@ -25,7 +25,7 @@
app:min="2"
android:persistent="false" />
- <org.omnirom.omnilib.preference.SeekBarPreference
+ <omnirom.preference.SeekBarPreference
android:key="qs_layout_columns_landscape"
android:title="@string/qs_layout_columns_landscape_title"
android:summary="@string/qs_layout_columns_landscape_summary"
@@ -39,7 +39,7 @@
android:key="qs_contents_category"
android:title="@string/qs_contents_title">
- <org.omnirom.omnilib.preference.SecureSettingSwitchPreference
+ <omnirom.preference.SecureSettingSwitchPreference
android:key="qs_show_brightness"
android:title="@string/qs_show_brightness_title"
android:summary="@string/qs_show_brightness_summary"