Welcome to Theme Interfacer! [1/2]
Change-Id: If9c2dce034c19916748dbebf015efdd16b9018db
diff --git a/Android.mk b/Android.mk
index 670adfe..e36c8bf 100644
--- a/Android.mk
+++ b/Android.mk
@@ -1,11 +1,11 @@
#
-# Inline AOSP Makefile for Masquerade
+# Inline AOSP Makefile for Projekt's ThemeInterfacer
#
LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)
-LOCAL_PACKAGE_NAME := masquerade
+LOCAL_PACKAGE_NAME := ThemeInterfacer
LOCAL_CERTIFICATE := platform
LOCAL_PRIVILEGED_MODULE := true
LOCAL_PROGUARD_ENABLED := disabled
diff --git a/README.md b/README.md
index c314e73..0a24440 100644
--- a/README.md
+++ b/README.md
@@ -1,26 +1,18 @@
-# masquerade
-[](https://travis-ci.org/nicholaschum/masquerade)
+# ThemeInterfacer
-Masquerade is Substratum's background service that runs functions that should run on a completely separate thread. This alleviates the stress on the main app and allows for Substratum to run more smoothly.
+ThemeInterfacer is the background service of the theme system developed by the Projekt team. It allows theme apps (including Substratum) to run system wide operations, otherwise unobtainable without root access. This also alleviates the performance stress on the theme app.
# How to add to ROM builds
If you are a ROM developer, by now you should know how to track new packages while building your ROM. However, if you don't - please follow these steps:
-Add "masquerade" under PRODUCT_PACKAGES in "vendor/config/common.mk"
+Add "ThemeInterfacer" in your PRODUCT_PACKAGES
PRODUCT_PACKAGES += \
...\
...\
...\
- masquerade
-
-Add the project path in "platform_manifest/default.xml"
+ ThemeInterfacer
- <project path="packages/apps/masquerade" name="substratum/masquerade" remote="github" revision="n-rootless" />
+Don't forget to add the project path in your AOSP manifest:
-## An example is found here:
-platform_manifest/default.xml:
-https://github.com/TipsyOs/platform_manifest/commit/fbff9ea598ec04f4f4a69687a8024770fefa83de
-
-vendor_tipsy/config/common.mk:
-https://github.com/TipsyOs/vendor_tipsy/commit/2e72dc4eb3a206fad34e9c4f130e270180eab1c2
+ <project path="packages/apps/ThemeInterfacer" name="substratum/interfacer" remote="github" revision="n-rootless" />
diff --git a/app/build.gradle b/app/build.gradle
index e8062ef..176c47a 100644
--- a/app/build.gradle
+++ b/app/build.gradle
@@ -12,12 +12,12 @@
applicationVariants.all { variant ->
variant.outputs.each { output ->
output.outputFile = new File(
- output.outputFile.parent, "masquerade_" + versionCode + ".apk")
+ output.outputFile.parent, "themeinterfacer_" + versionCode + ".apk")
}
}
defaultConfig {
- applicationId "masquerade.substratum"
+ applicationId "projekt.interfacer"
minSdkVersion 25
targetSdkVersion 25
}
diff --git a/app/src/main/AndroidManifest.xml b/app/src/main/AndroidManifest.xml
index 25d1ff2..d8a1dd8 100644
--- a/app/src/main/AndroidManifest.xml
+++ b/app/src/main/AndroidManifest.xml
@@ -2,10 +2,10 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:tools="http://schemas.android.com/tools"
coreApp="true"
- package="masquerade.substratum"
+ package="projekt.interfacer"
android:sharedUserId="android.uid.system"
- android:versionCode="24"
- android:versionName="twenty four"
+ android:versionCode="50"
+ android:versionName="fifty"
tools:ignore="GradleOverrides">
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE"/>
@@ -23,13 +23,14 @@
tools:ignore="ProtectedPermissions"/>
<uses-permission android:name="android.permission.INSTALL_GRANT_RUNTIME_PERMISSIONS"/>
<uses-permission android:name="android.permission.MODIFY_OVERLAYS"/>
- <protected-broadcast android:name="masquerade.substratum.STATUS_CHANGED" />
- <protected-broadcast android:name="masquerade.substratum.CALLER_AUTHORIZED" />
+ <protected-broadcast android:name="projekt.interfacer.STATUS_CHANGED" />
+ <protected-broadcast android:name="projekt.interfacer.CALLER_AUTHORIZED" />
<application
android:allowBackup="false"
android:icon="@mipmap/ic_launcher"
- android:label="masquerade"
+ android:label="Theme Interfacer"
+ android:roundIcon="@mipmap/ic_launcher_round"
android:supportsRtl="true"
android:theme="@android:style/Theme.NoDisplay"
tools:ignore="GoogleAppIndexingWarning">
diff --git a/app/src/main/java/masquerade/substratum/services/JobService.java b/app/src/main/java/projekt/interfacer/services/JobService.java
similarity index 98%
rename from app/src/main/java/masquerade/substratum/services/JobService.java
rename to app/src/main/java/projekt/interfacer/services/JobService.java
index b93047a..9e896bb 100644
--- a/app/src/main/java/masquerade/substratum/services/JobService.java
+++ b/app/src/main/java/projekt/interfacer/services/JobService.java
@@ -18,7 +18,7 @@
*
*/
-package masquerade.substratum.services;
+package projekt.interfacer.services;
import android.app.ActivityManager;
import android.app.ActivityManagerNative;
@@ -71,11 +71,11 @@
import java.util.Locale;
import java.util.stream.Collectors;
-import masquerade.substratum.utils.IOUtils;
-import masquerade.substratum.utils.SoundUtils;
+import projekt.interfacer.utils.IOUtils;
+import projekt.interfacer.utils.SoundUtils;
public class JobService extends Service {
- public static final String INTENT_STATUS_CHANGED = "masquerade.substratum.STATUS_CHANGED";
+ public static final String INTENT_STATUS_CHANGED = "projekt.interfacer.STATUS_CHANGED";
public static final String PRIMARY_COMMAND_KEY = "primary_command_key";
public static final String JOB_TIME_KEY = "job_time_key";
public static final String INSTALL_LIST_KEY = "install_list";
@@ -112,11 +112,11 @@
public static final String COMMAND_VALUE_MKDIR = "mkdir";
private static final String TAG = JobService.class.getSimpleName();
private static final boolean DEBUG = true;
- private static final String MASQUERADE_TOKEN = "masquerade_token";
- private static final String MASQUERADE_PACKAGE = "masquerade.substratum";
+ private static final String INTERFACER_TOKEN = "interfacer_token";
+ private static final String INTERFACER_PACKAGE = "projekt.interfacer";
private static final String SUBSTRATUM_PACKAGE = "projekt.substratum";
private static final String[] AUTHORIZED_CALLERS = new String[]{
- MASQUERADE_PACKAGE,
+ INTERFACER_PACKAGE,
SUBSTRATUM_PACKAGE,
};
private static List<Sound> SOUNDS = Arrays.asList(
@@ -128,7 +128,7 @@
new Sound(IOUtils.SYSTEM_THEME_NOTIFICATION_PATH, "/SoundsCache/notifications/", "notification", "notification", RingtoneManager.TYPE_NOTIFICATION),
new Sound(IOUtils.SYSTEM_THEME_RINGTONE_PATH, "/SoundsCache/ringtones/", "ringtone", "ringtone", RingtoneManager.TYPE_RINGTONE)
);
- private static final String INTENT_CALLER_AUTHORIZED = "masquerade.substratum.CALLER_AUTHORIZED";
+ private static final String INTENT_CALLER_AUTHORIZED = "projekt.interfacer.CALLER_AUTHORIZED";
private static IOverlayManager mOMS;
private static IPackageManager mPM;
private final List<Runnable> mJobQueue = new ArrayList<>(0);
@@ -686,7 +686,7 @@
}
private static boolean shouldCheckBuildType() {
- return SystemProperties.getBoolean("ro.masquerade.buildtype.check", false);
+ return SystemProperties.getBoolean("ro.interfacer.buildtype.check", false);
}
private boolean forceAuthorizePackages() {
@@ -715,7 +715,7 @@
PendingIntent token = null;
try {
- token = intent.getParcelableExtra(MASQUERADE_TOKEN);
+ token = intent.getParcelableExtra(INTERFACER_TOKEN);
} catch (Exception e) {
log("Attempting to start service without a token - unauthorized!");
}
diff --git a/app/src/main/java/masquerade/substratum/utils/IOUtils.java b/app/src/main/java/projekt/interfacer/utils/IOUtils.java
similarity index 99%
rename from app/src/main/java/masquerade/substratum/utils/IOUtils.java
rename to app/src/main/java/projekt/interfacer/utils/IOUtils.java
index a93485c..5f02424 100644
--- a/app/src/main/java/masquerade/substratum/utils/IOUtils.java
+++ b/app/src/main/java/projekt/interfacer/utils/IOUtils.java
@@ -18,7 +18,7 @@
*
*/
-package masquerade.substratum.utils;
+package projekt.interfacer.utils;
import android.os.FileUtils;
import android.util.Log;
diff --git a/app/src/main/java/masquerade/substratum/utils/SoundUtils.java b/app/src/main/java/projekt/interfacer/utils/SoundUtils.java
similarity index 99%
rename from app/src/main/java/masquerade/substratum/utils/SoundUtils.java
rename to app/src/main/java/projekt/interfacer/utils/SoundUtils.java
index 8fce9e4..a8b74a5 100644
--- a/app/src/main/java/masquerade/substratum/utils/SoundUtils.java
+++ b/app/src/main/java/projekt/interfacer/utils/SoundUtils.java
@@ -18,7 +18,7 @@
*
*/
-package masquerade.substratum.utils;
+package projekt.interfacer.utils;
import android.content.ContentResolver;
import android.content.ContentValues;
diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher.png b/app/src/main/res/mipmap-hdpi/ic_launcher.png
index 2588952..77f858c 100644
--- a/app/src/main/res/mipmap-hdpi/ic_launcher.png
+++ b/app/src/main/res/mipmap-hdpi/ic_launcher.png
Binary files differ
diff --git a/app/src/main/res/mipmap-hdpi/ic_launcher_round.png b/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
new file mode 100644
index 0000000..94f41c7
--- /dev/null
+++ b/app/src/main/res/mipmap-hdpi/ic_launcher_round.png
Binary files differ
diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher.png b/app/src/main/res/mipmap-mdpi/ic_launcher.png
index bd2ae71..0e0f417 100644
--- a/app/src/main/res/mipmap-mdpi/ic_launcher.png
+++ b/app/src/main/res/mipmap-mdpi/ic_launcher.png
Binary files differ
diff --git a/app/src/main/res/mipmap-mdpi/ic_launcher_round.png b/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
new file mode 100644
index 0000000..fbef305
--- /dev/null
+++ b/app/src/main/res/mipmap-mdpi/ic_launcher_round.png
Binary files differ
diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher.png b/app/src/main/res/mipmap-xhdpi/ic_launcher.png
index c56d924..b1070c9 100644
--- a/app/src/main/res/mipmap-xhdpi/ic_launcher.png
+++ b/app/src/main/res/mipmap-xhdpi/ic_launcher.png
Binary files differ
diff --git a/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png b/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
new file mode 100644
index 0000000..e6a4bf6
--- /dev/null
+++ b/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png
Binary files differ
diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
index 69011b7..d1ede44 100644
--- a/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
+++ b/app/src/main/res/mipmap-xxhdpi/ic_launcher.png
Binary files differ
diff --git a/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png b/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
new file mode 100644
index 0000000..ebc0f63
--- /dev/null
+++ b/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png
Binary files differ
diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
index 4448e0b..060b23b 100644
--- a/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
+++ b/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png
Binary files differ
diff --git a/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
new file mode 100644
index 0000000..7f0b6bd
--- /dev/null
+++ b/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png
Binary files differ