From 4ff446cdefefdb713ba118555d0e87162b3b5c74 Mon Sep 17 00:00:00 2001 From: Alex Cruz Date: Sun, 21 May 2017 22:51:19 +0200 Subject: [PATCH] Further Refactoring, change theme to match pixel (settings) - Remove package from showing up in settings - Changed package name so we can do our own thing and not have it get in the way of the Doze package currently used by Nick and others - Set OneplusDoze to compile Change-Id: Ieebf13f88c02d5036a09b5ef83ca1b53bd6999ac --- device.mk | 2 +- doze/Android.mk | 2 +- doze/AndroidManifest.xml | 14 ++--- doze/proguard.flags | 2 +- doze/res/drawable/ic_settings_doze.xml | 51 ------------------- .../doze/BootCompletedReceiver.java | 2 +- .../doze/DozeService.java | 2 +- .../doze/DozeSettings.java | 2 +- .../doze/ProximitySensor.java | 2 +- .../doze/TiltSensor.java | 2 +- .../doze/Utils.java | 2 +- 11 files changed, 13 insertions(+), 70 deletions(-) delete mode 100644 doze/res/drawable/ic_settings_doze.xml rename doze/src/com/cyanogenmod/{settings => oneplusthree}/doze/BootCompletedReceiver.java (96%) rename doze/src/com/cyanogenmod/{settings => oneplusthree}/doze/DozeService.java (98%) rename doze/src/com/cyanogenmod/{settings => oneplusthree}/doze/DozeSettings.java (99%) rename doze/src/com/cyanogenmod/{settings => oneplusthree}/doze/ProximitySensor.java (98%) rename doze/src/com/cyanogenmod/{settings => oneplusthree}/doze/TiltSensor.java (98%) rename doze/src/com/cyanogenmod/{settings => oneplusthree}/doze/Utils.java (98%) diff --git a/device.mk b/device.mk index 1d6e606..1be6290 100755 --- a/device.mk +++ b/device.mk @@ -147,7 +147,7 @@ PRODUCT_PACKAGES += \ # Doze mode PRODUCT_PACKAGES += \ - ZukDoze + OneplusThreeDoze # Fingerprint PRODUCT_PACKAGES += \ diff --git a/doze/Android.mk b/doze/Android.mk index 4af9971..af3e27b 100644 --- a/doze/Android.mk +++ b/doze/Android.mk @@ -5,7 +5,7 @@ LOCAL_MODULE_TAGS := optional LOCAL_SRC_FILES := $(call all-java-files-under, src) -LOCAL_PACKAGE_NAME := OneplusDoze +LOCAL_PACKAGE_NAME := OneplusThreeDoze LOCAL_CERTIFICATE := platform LOCAL_PRIVILEGED_MODULE := true diff --git a/doze/AndroidManifest.xml b/doze/AndroidManifest.xml index e4ba8dc..7e4dc5c 100644 --- a/doze/AndroidManifest.xml +++ b/doze/AndroidManifest.xml @@ -1,6 +1,6 @@ @@ -16,30 +16,24 @@ android:label="OneplusDoze" android:persistent="true"> - + - + android:theme="@android:style/Theme.DeviceDefault.Settings"> - - diff --git a/doze/proguard.flags b/doze/proguard.flags index a21e62f..399c549 100644 --- a/doze/proguard.flags +++ b/doze/proguard.flags @@ -1,3 +1,3 @@ --keep class com.cyanogenmod.settings.doze.* { +-keep class com.cyanogenmod.oneplusthree.doze.* { *; } diff --git a/doze/res/drawable/ic_settings_doze.xml b/doze/res/drawable/ic_settings_doze.xml deleted file mode 100644 index 8386024..0000000 --- a/doze/res/drawable/ic_settings_doze.xml +++ /dev/null @@ -1,51 +0,0 @@ - - - - - - - diff --git a/doze/src/com/cyanogenmod/settings/doze/BootCompletedReceiver.java b/doze/src/com/cyanogenmod/oneplusthree/doze/BootCompletedReceiver.java similarity index 96% rename from doze/src/com/cyanogenmod/settings/doze/BootCompletedReceiver.java rename to doze/src/com/cyanogenmod/oneplusthree/doze/BootCompletedReceiver.java index 51fd196..606662f 100644 --- a/doze/src/com/cyanogenmod/settings/doze/BootCompletedReceiver.java +++ b/doze/src/com/cyanogenmod/oneplusthree/doze/BootCompletedReceiver.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.cyanogenmod.settings.doze; +package com.cyanogenmod.oneplusthree.doze; import android.content.BroadcastReceiver; import android.content.Context; diff --git a/doze/src/com/cyanogenmod/settings/doze/DozeService.java b/doze/src/com/cyanogenmod/oneplusthree/doze/DozeService.java similarity index 98% rename from doze/src/com/cyanogenmod/settings/doze/DozeService.java rename to doze/src/com/cyanogenmod/oneplusthree/doze/DozeService.java index 2ee79bf..6002e7a 100644 --- a/doze/src/com/cyanogenmod/settings/doze/DozeService.java +++ b/doze/src/com/cyanogenmod/oneplusthree/doze/DozeService.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.cyanogenmod.settings.doze; +package com.cyanogenmod.oneplusthree.doze; import android.app.Service; import android.content.BroadcastReceiver; diff --git a/doze/src/com/cyanogenmod/settings/doze/DozeSettings.java b/doze/src/com/cyanogenmod/oneplusthree/doze/DozeSettings.java similarity index 99% rename from doze/src/com/cyanogenmod/settings/doze/DozeSettings.java rename to doze/src/com/cyanogenmod/oneplusthree/doze/DozeSettings.java index 2e179bc..a23fc66 100644 --- a/doze/src/com/cyanogenmod/settings/doze/DozeSettings.java +++ b/doze/src/com/cyanogenmod/oneplusthree/doze/DozeSettings.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.cyanogenmod.settings.doze; +package com.cyanogenmod.oneplusthree.doze; import android.app.ActionBar; import android.app.Activity; diff --git a/doze/src/com/cyanogenmod/settings/doze/ProximitySensor.java b/doze/src/com/cyanogenmod/oneplusthree/doze/ProximitySensor.java similarity index 98% rename from doze/src/com/cyanogenmod/settings/doze/ProximitySensor.java rename to doze/src/com/cyanogenmod/oneplusthree/doze/ProximitySensor.java index 0f62b11..c52acda 100644 --- a/doze/src/com/cyanogenmod/settings/doze/ProximitySensor.java +++ b/doze/src/com/cyanogenmod/oneplusthree/doze/ProximitySensor.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.cyanogenmod.settings.doze; +package com.cyanogenmod.oneplusthree.doze; import android.content.Context; import android.hardware.Sensor; diff --git a/doze/src/com/cyanogenmod/settings/doze/TiltSensor.java b/doze/src/com/cyanogenmod/oneplusthree/doze/TiltSensor.java similarity index 98% rename from doze/src/com/cyanogenmod/settings/doze/TiltSensor.java rename to doze/src/com/cyanogenmod/oneplusthree/doze/TiltSensor.java index 443a10d..c71389d 100644 --- a/doze/src/com/cyanogenmod/settings/doze/TiltSensor.java +++ b/doze/src/com/cyanogenmod/oneplusthree/doze/TiltSensor.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.cyanogenmod.settings.doze; +package com.cyanogenmod.oneplusthree.doze; import android.content.Context; import android.hardware.Sensor; diff --git a/doze/src/com/cyanogenmod/settings/doze/Utils.java b/doze/src/com/cyanogenmod/oneplusthree/doze/Utils.java similarity index 98% rename from doze/src/com/cyanogenmod/settings/doze/Utils.java rename to doze/src/com/cyanogenmod/oneplusthree/doze/Utils.java index 767cd96..9b5009e 100644 --- a/doze/src/com/cyanogenmod/settings/doze/Utils.java +++ b/doze/src/com/cyanogenmod/oneplusthree/doze/Utils.java @@ -14,7 +14,7 @@ * limitations under the License. */ -package com.cyanogenmod.settings.doze; +package com.cyanogenmod.oneplusthree.doze; import android.app.ActivityManager; import android.app.ActivityManager.RunningServiceInfo;