mirror of
https://github.com/Divested-Mobile/DivestOS-Build.git
synced 2025-01-26 23:27:08 -05:00
15.1: Remove analytics from SUW
This commit is contained in:
parent
ac990f0491
commit
199ffada5b
@ -1,14 +1,14 @@
|
|||||||
From 2d5570d86d6eb950247a5b4792840c1626eaea94 Mon Sep 17 00:00:00 2001
|
From ed5cc62e6f0bccd5833be40d420e75cff720b2b2 Mon Sep 17 00:00:00 2001
|
||||||
From: Tad <tad@spotco.us>
|
From: Tad <tad@spotco.us>
|
||||||
Date: Wed, 18 Oct 2017 11:54:48 -0400
|
Date: Wed, 28 Feb 2018 08:12:03 -0500
|
||||||
Subject: [PATCH] Remove analytics
|
Subject: [PATCH] Remove analytics
|
||||||
|
|
||||||
Change-Id: I044dd6b137b8a1d4a6dde3a63c0aaa454309341f
|
Change-Id: I189e9362c828569512e819cf655b03bfa3436830
|
||||||
---
|
---
|
||||||
res/layout/setup_lineage_settings.xml | 36 ----------------------
|
res/layout/setup_lineage_settings.xml | 36 ----------------------
|
||||||
.../cyanogenmod/setupwizard/FinishActivity.java | 12 --------
|
src/org/lineageos/setupwizard/FinishActivity.java | 12 --------
|
||||||
.../setupwizard/LineageSettingsActivity.java | 35 ---------------------
|
.../setupwizard/LineageSettingsActivity.java | 35 ---------------------
|
||||||
.../cyanogenmod/setupwizard/SetupWizardApp.java | 1 -
|
src/org/lineageos/setupwizard/SetupWizardApp.java | 1 -
|
||||||
4 files changed, 84 deletions(-)
|
4 files changed, 84 deletions(-)
|
||||||
|
|
||||||
diff --git a/res/layout/setup_lineage_settings.xml b/res/layout/setup_lineage_settings.xml
|
diff --git a/res/layout/setup_lineage_settings.xml b/res/layout/setup_lineage_settings.xml
|
||||||
@ -58,19 +58,19 @@ index 42b4c2d..5792c06 100644
|
|||||||
<!-- Checkbox for using on-screen nav keys -->
|
<!-- Checkbox for using on-screen nav keys -->
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
android:id="@+id/nav_keys"
|
android:id="@+id/nav_keys"
|
||||||
diff --git a/src/com/cyanogenmod/setupwizard/FinishActivity.java b/src/com/cyanogenmod/setupwizard/FinishActivity.java
|
diff --git a/src/org/lineageos/setupwizard/FinishActivity.java b/src/org/lineageos/setupwizard/FinishActivity.java
|
||||||
index cd25811..f927f46 100644
|
index d9c818d..fb2f6e5 100644
|
||||||
--- a/src/com/cyanogenmod/setupwizard/FinishActivity.java
|
--- a/src/org/lineageos/setupwizard/FinishActivity.java
|
||||||
+++ b/src/com/cyanogenmod/setupwizard/FinishActivity.java
|
+++ b/src/org/lineageos/setupwizard/FinishActivity.java
|
||||||
@@ -21,7 +21,6 @@ import static com.cyanogenmod.setupwizard.SetupWizardApp.DISABLE_NAV_KEYS;
|
@@ -20,7 +20,6 @@ package org.lineageos.setupwizard;
|
||||||
import static com.cyanogenmod.setupwizard.SetupWizardApp.KEY_APPLY_DEFAULT_THEME;
|
import static org.lineageos.setupwizard.SetupWizardApp.DISABLE_NAV_KEYS;
|
||||||
import static com.cyanogenmod.setupwizard.SetupWizardApp.KEY_BUTTON_BACKLIGHT;
|
import static org.lineageos.setupwizard.SetupWizardApp.KEY_BUTTON_BACKLIGHT;
|
||||||
import static com.cyanogenmod.setupwizard.SetupWizardApp.KEY_PRIVACY_GUARD;
|
import static org.lineageos.setupwizard.SetupWizardApp.KEY_PRIVACY_GUARD;
|
||||||
-import static com.cyanogenmod.setupwizard.SetupWizardApp.KEY_SEND_METRICS;
|
-import static org.lineageos.setupwizard.SetupWizardApp.KEY_SEND_METRICS;
|
||||||
import static com.cyanogenmod.setupwizard.SetupWizardApp.LOGV;
|
import static org.lineageos.setupwizard.SetupWizardApp.LOGV;
|
||||||
|
|
||||||
import android.animation.Animator;
|
import android.animation.Animator;
|
||||||
@@ -174,7 +173,6 @@ public class FinishActivity extends BaseSetupWizardActivity {
|
@@ -173,7 +172,6 @@ public class FinishActivity extends BaseSetupWizardActivity {
|
||||||
mEnableAccessibilityController.onDestroy();
|
mEnableAccessibilityController.onDestroy();
|
||||||
}
|
}
|
||||||
handlePrivacyGuard(mSetupWizardApp);
|
handlePrivacyGuard(mSetupWizardApp);
|
||||||
@ -78,7 +78,7 @@ index cd25811..f927f46 100644
|
|||||||
handleNavKeys(mSetupWizardApp);
|
handleNavKeys(mSetupWizardApp);
|
||||||
final WallpaperManager wallpaperManager =
|
final WallpaperManager wallpaperManager =
|
||||||
WallpaperManager.getInstance(mSetupWizardApp);
|
WallpaperManager.getInstance(mSetupWizardApp);
|
||||||
@@ -185,16 +183,6 @@ public class FinishActivity extends BaseSetupWizardActivity {
|
@@ -184,16 +182,6 @@ public class FinishActivity extends BaseSetupWizardActivity {
|
||||||
startActivityForResult(intent, NEXT_REQUEST);
|
startActivityForResult(intent, NEXT_REQUEST);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -86,8 +86,8 @@ index cd25811..f927f46 100644
|
|||||||
- Bundle privacyData = setupWizardApp.getSettingsBundle();
|
- Bundle privacyData = setupWizardApp.getSettingsBundle();
|
||||||
- if (privacyData != null
|
- if (privacyData != null
|
||||||
- && privacyData.containsKey(KEY_SEND_METRICS)) {
|
- && privacyData.containsKey(KEY_SEND_METRICS)) {
|
||||||
- CMSettings.Secure.putInt(setupWizardApp.getContentResolver(),
|
- LineageSettings.Secure.putInt(setupWizardApp.getContentResolver(),
|
||||||
- CMSettings.Secure.STATS_COLLECTION, privacyData.getBoolean(KEY_SEND_METRICS)
|
- LineageSettings.Secure.STATS_COLLECTION, privacyData.getBoolean(KEY_SEND_METRICS)
|
||||||
- ? 1 : 0);
|
- ? 1 : 0);
|
||||||
- }
|
- }
|
||||||
- }
|
- }
|
||||||
@ -95,19 +95,19 @@ index cd25811..f927f46 100644
|
|||||||
private static void handlePrivacyGuard(SetupWizardApp setupWizardApp) {
|
private static void handlePrivacyGuard(SetupWizardApp setupWizardApp) {
|
||||||
Bundle mPrivacyData = setupWizardApp.getSettingsBundle();
|
Bundle mPrivacyData = setupWizardApp.getSettingsBundle();
|
||||||
if (mPrivacyData != null && mPrivacyData.containsKey(KEY_PRIVACY_GUARD)) {
|
if (mPrivacyData != null && mPrivacyData.containsKey(KEY_PRIVACY_GUARD)) {
|
||||||
diff --git a/src/com/cyanogenmod/setupwizard/LineageSettingsActivity.java b/src/com/cyanogenmod/setupwizard/LineageSettingsActivity.java
|
diff --git a/src/org/lineageos/setupwizard/LineageSettingsActivity.java b/src/org/lineageos/setupwizard/LineageSettingsActivity.java
|
||||||
index b222c72..5bf8d9f 100644
|
index 5970930..fab07db 100644
|
||||||
--- a/src/com/cyanogenmod/setupwizard/LineageSettingsActivity.java
|
--- a/src/org/lineageos/setupwizard/LineageSettingsActivity.java
|
||||||
+++ b/src/com/cyanogenmod/setupwizard/LineageSettingsActivity.java
|
+++ b/src/org/lineageos/setupwizard/LineageSettingsActivity.java
|
||||||
@@ -20,7 +20,6 @@ package com.cyanogenmod.setupwizard;
|
@@ -19,7 +19,6 @@ package org.lineageos.setupwizard;
|
||||||
import static com.cyanogenmod.setupwizard.SetupWizardApp.DISABLE_NAV_KEYS;
|
|
||||||
import static com.cyanogenmod.setupwizard.SetupWizardApp.KEY_APPLY_DEFAULT_THEME;
|
import static org.lineageos.setupwizard.SetupWizardApp.DISABLE_NAV_KEYS;
|
||||||
import static com.cyanogenmod.setupwizard.SetupWizardApp.KEY_PRIVACY_GUARD;
|
import static org.lineageos.setupwizard.SetupWizardApp.KEY_PRIVACY_GUARD;
|
||||||
-import static com.cyanogenmod.setupwizard.SetupWizardApp.KEY_SEND_METRICS;
|
-import static org.lineageos.setupwizard.SetupWizardApp.KEY_SEND_METRICS;
|
||||||
|
|
||||||
import android.app.Activity;
|
import android.app.Activity;
|
||||||
import android.content.Context;
|
import android.content.Context;
|
||||||
@@ -57,24 +56,13 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
@@ -56,24 +55,13 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
||||||
|
|
||||||
private SetupWizardApp mSetupWizardApp;
|
private SetupWizardApp mSetupWizardApp;
|
||||||
|
|
||||||
@ -132,19 +132,19 @@ index b222c72..5bf8d9f 100644
|
|||||||
private View.OnClickListener mNavKeysClickListener = new View.OnClickListener() {
|
private View.OnClickListener mNavKeysClickListener = new View.OnClickListener() {
|
||||||
@Override
|
@Override
|
||||||
public void onClick(View view) {
|
public void onClick(View view) {
|
||||||
@@ -122,19 +110,6 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
@@ -121,19 +109,6 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
||||||
privacyPolicy.setMovementMethod(LinkMovementMethod.getInstance());
|
privacyPolicy.setMovementMethod(LinkMovementMethod.getInstance());
|
||||||
privacyPolicy.setText(ss);
|
privacyPolicy.setText(ss);
|
||||||
|
|
||||||
- mMetricsRow = findViewById(R.id.metrics);
|
- mMetricsRow = findViewById(R.id.metrics);
|
||||||
- mMetricsRow.setOnClickListener(mMetricsClickListener);
|
- mMetricsRow.setOnClickListener(mMetricsClickListener);
|
||||||
- String metricsHelpImproveCM =
|
- String metricsHelpImproveLineage =
|
||||||
- getString(R.string.services_help_improve_cm, getString(R.string.os_name));
|
- getString(R.string.services_help_improve_cm, getString(R.string.os_name));
|
||||||
- String metricsSummary = getString(R.string.services_metrics_label,
|
- String metricsSummary = getString(R.string.services_metrics_label,
|
||||||
- metricsHelpImproveCM, getString(R.string.os_name));
|
- metricsHelpImproveLineage, getString(R.string.os_name));
|
||||||
- final SpannableStringBuilder metricsSpan = new SpannableStringBuilder(metricsSummary);
|
- final SpannableStringBuilder metricsSpan = new SpannableStringBuilder(metricsSummary);
|
||||||
- metricsSpan.setSpan(new android.text.style.StyleSpan(android.graphics.Typeface.BOLD),
|
- metricsSpan.setSpan(new android.text.style.StyleSpan(android.graphics.Typeface.BOLD),
|
||||||
- 0, metricsHelpImproveCM.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
- 0, metricsHelpImproveLineage.length(), Spannable.SPAN_EXCLUSIVE_EXCLUSIVE);
|
||||||
- TextView metrics = (TextView) findViewById(R.id.enable_metrics_summary);
|
- TextView metrics = (TextView) findViewById(R.id.enable_metrics_summary);
|
||||||
- metrics.setText(metricsSpan);
|
- metrics.setText(metricsSpan);
|
||||||
- mMetrics = (CheckBox) findViewById(R.id.enable_metrics_checkbox);
|
- mMetrics = (CheckBox) findViewById(R.id.enable_metrics_checkbox);
|
||||||
@ -152,7 +152,7 @@ index b222c72..5bf8d9f 100644
|
|||||||
mNavKeysRow = findViewById(R.id.nav_keys);
|
mNavKeysRow = findViewById(R.id.nav_keys);
|
||||||
mNavKeysRow.setOnClickListener(mNavKeysClickListener);
|
mNavKeysRow.setOnClickListener(mNavKeysClickListener);
|
||||||
mNavKeys = (CheckBox) findViewById(R.id.nav_keys_checkbox);
|
mNavKeys = (CheckBox) findViewById(R.id.nav_keys_checkbox);
|
||||||
@@ -163,7 +138,6 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
@@ -162,7 +137,6 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
||||||
public void onResume() {
|
public void onResume() {
|
||||||
super.onResume();
|
super.onResume();
|
||||||
updateDisableNavkeysOption();
|
updateDisableNavkeysOption();
|
||||||
@ -160,7 +160,7 @@ index b222c72..5bf8d9f 100644
|
|||||||
updatePrivacyGuardOption();
|
updatePrivacyGuardOption();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -198,15 +172,6 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
@@ -197,15 +171,6 @@ public class LineageSettingsActivity extends BaseSetupWizardActivity {
|
||||||
return R.drawable.ic_features;
|
return R.drawable.ic_features;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -176,18 +176,18 @@ index b222c72..5bf8d9f 100644
|
|||||||
private void updateDisableNavkeysOption() {
|
private void updateDisableNavkeysOption() {
|
||||||
if (!mHideNavKeysRow) {
|
if (!mHideNavKeysRow) {
|
||||||
final Bundle myPageBundle = mSetupWizardApp.getSettingsBundle();
|
final Bundle myPageBundle = mSetupWizardApp.getSettingsBundle();
|
||||||
diff --git a/src/com/cyanogenmod/setupwizard/SetupWizardApp.java b/src/com/cyanogenmod/setupwizard/SetupWizardApp.java
|
diff --git a/src/org/lineageos/setupwizard/SetupWizardApp.java b/src/org/lineageos/setupwizard/SetupWizardApp.java
|
||||||
index f10a917..f916f5b 100644
|
index 62c1a20..4265493 100644
|
||||||
--- a/src/com/cyanogenmod/setupwizard/SetupWizardApp.java
|
--- a/src/org/lineageos/setupwizard/SetupWizardApp.java
|
||||||
+++ b/src/com/cyanogenmod/setupwizard/SetupWizardApp.java
|
+++ b/src/org/lineageos/setupwizard/SetupWizardApp.java
|
||||||
@@ -59,7 +59,6 @@ public class SetupWizardApp extends Application {
|
@@ -61,7 +61,6 @@ public class SetupWizardApp extends Application {
|
||||||
public static final String EXTRA_RESULT_CODE = "com.android.setupwizard.ResultCode";
|
public static final String EXTRA_PREFS_SET_BACK_TEXT = "extra_prefs_set_back_text";
|
||||||
|
|
||||||
public static final String KEY_DETECT_CAPTIVE_PORTAL = "captive_portal_detection_enabled";
|
public static final String KEY_DETECT_CAPTIVE_PORTAL = "captive_portal_detection_enabled";
|
||||||
- public static final String KEY_SEND_METRICS = "send_metrics";
|
- public static final String KEY_SEND_METRICS = "send_metrics";
|
||||||
public static final String DISABLE_NAV_KEYS = "disable_nav_keys";
|
public static final String DISABLE_NAV_KEYS = "disable_nav_keys";
|
||||||
public static final String KEY_APPLY_DEFAULT_THEME = "apply_default_theme";
|
|
||||||
public static final String KEY_BUTTON_BACKLIGHT = "pre_navbar_button_backlight";
|
public static final String KEY_BUTTON_BACKLIGHT = "pre_navbar_button_backlight";
|
||||||
|
public static final String KEY_PRIVACY_GUARD = "privacy_guard_default";
|
||||||
--
|
--
|
||||||
2.14.2
|
2.16.2
|
||||||
|
|
||||||
|
@ -133,8 +133,8 @@ sed -i 's/private int mPasswordMaxLength = 16;/private int mPasswordMaxLength =
|
|||||||
sed -i 's/GSETTINGS_PROVIDER = "com.google.settings";/GSETTINGS_PROVIDER = "com.google.oQuae4av";/' src/com/android/settings/PrivacySettings.java; #MicroG doesn't support Backup, hide the options
|
sed -i 's/GSETTINGS_PROVIDER = "com.google.settings";/GSETTINGS_PROVIDER = "com.google.oQuae4av";/' src/com/android/settings/PrivacySettings.java; #MicroG doesn't support Backup, hide the options
|
||||||
#patch -p1 < $patches"android_packages_apps_Settings/0001-Privacy_Guard-More_Perms.patch" #Allow more control over various permissions via Privacy Guard #TODO: Rebase
|
#patch -p1 < $patches"android_packages_apps_Settings/0001-Privacy_Guard-More_Perms.patch" #Allow more control over various permissions via Privacy Guard #TODO: Rebase
|
||||||
|
|
||||||
#enterAndClear "packages/apps/SetupWizard"
|
enterAndClear "packages/apps/SetupWizard"
|
||||||
#patch -p1 < $patches"android_packages_apps_SetupWizard/0001-Remove_Analytics.patch" #Remove analytics #TODO: Rebase
|
patch -p1 < $patches"android_packages_apps_SetupWizard/0001-Remove_Analytics.patch" #Remove analytics
|
||||||
|
|
||||||
enterAndClear "packages/apps/Silence"
|
enterAndClear "packages/apps/Silence"
|
||||||
cp $patches"android_packages_apps_Silence/Android.mk" Android.mk #Add a build file
|
cp $patches"android_packages_apps_Silence/Android.mk" Android.mk #Add a build file
|
||||||
|
Loading…
x
Reference in New Issue
Block a user