more work

Signed-off-by: androidacy-user <opensource@androidacy.com>
pull/27/head
androidacy-user 3 years ago
parent 5d844e0911
commit f39b3af4fa

@ -42,7 +42,8 @@
android:name=".SetupActivity"
android:exported="false"
android:label="@string/title_activity_setup"
android:theme="@style/Theme.MagiskModuleManager.NoActionBar" />
android:parentActivityName=".MainActivity"
android:theme="@style/Theme.MagiskModuleManager.NoActionBar"/>
<receiver
android:name=".background.BackgroundBootListener"

@ -0,0 +1,245 @@
package com.fox2code.mmm;
import static com.fox2code.mmm.utils.IntentHelper.getActivity;
import android.annotation.SuppressLint;
import android.content.Intent;
import android.content.SharedPreferences;
import android.content.res.Resources;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.view.WindowManager;
import androidx.appcompat.app.ActionBar;
import androidx.fragment.app.FragmentActivity;
import com.fox2code.foxcompat.app.FoxActivity;
import com.fox2code.mmm.databinding.ActivitySetupBinding;
import com.fox2code.rosettax.LanguageActivity;
import com.fox2code.rosettax.LanguageSwitcher;
import com.google.android.material.button.MaterialButton;
import com.google.android.material.dialog.MaterialAlertDialogBuilder;
import com.google.android.material.materialswitch.MaterialSwitch;
import com.topjohnwu.superuser.internal.UiThreadHandler;
import java.util.Objects;
public class SetupActivity extends FoxActivity implements LanguageActivity {
private ActivitySetupBinding binding;
private boolean mSupportsDarkText;
@SuppressLint({"ApplySharedPref", "RestrictedApi"})
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
this.setTitle(R.string.app_name);
this.getWindow().setFlags(WindowManager.LayoutParams.FLAG_TRANSLUCENT_NAVIGATION, 0);
// Set theme
SharedPreferences prefs = MainApplication.getSharedPreferences();
switch (prefs.getString("theme", "system")) {
case "light":
setTheme(R.style.Theme_MagiskModuleManager_Monet_Light);
break;
case "dark":
setTheme(R.style.Theme_MagiskModuleManager_Monet_Dark);
break;
case "system":
setTheme(R.style.Theme_MagiskModuleManager_Monet);
break;
case "black":
setTheme(R.style.Theme_MagiskModuleManager_Monet_Black);
break;
case "transparent_light":
setTheme(R.style.Theme_MagiskModuleManager_Transparent_Light);
break;
}
binding = ActivitySetupBinding.inflate(getLayoutInflater());
setContentView(binding.getRoot());
// Show setup box. Put the setup_box in the main activity layout
View view = binding.setupBox;
// Make the setup_box linear layout the sole child of the root_container constraint layout
setContentView(view);
// Handle action bar. Set it to setup_title and make it visible
ActionBar actionBar = getSupportActionBar();
if (actionBar != null) {
actionBar.setTitle(R.string.app_name);
// Set solid color background
actionBar.show();
}
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_background_update_check))).setChecked(BuildConfig.ENABLE_AUTO_UPDATER);
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_crash_reporting))).setChecked(BuildConfig.DEFAULT_ENABLE_CRASH_REPORTING);
// Repos are a little harder, as the enabled_repos build config is an arraylist
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_androidacy_repo))).setChecked(BuildConfig.ENABLED_REPOS.contains("androidacy_repo"));
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_magisk_alt_repo))).setChecked(BuildConfig.ENABLED_REPOS.contains("magisk_alt_repo"));
// On debug builds, log when a switch is toggled
if (BuildConfig.DEBUG) {
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_background_update_check))).setOnCheckedChangeListener((buttonView, isChecked) -> Log.i("SetupWizard", "Background Update Check: " + isChecked));
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_crash_reporting))).setOnCheckedChangeListener((buttonView, isChecked) -> Log.i("SetupWizard", "Crash Reporting: " + isChecked));
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_androidacy_repo))).setOnCheckedChangeListener((buttonView, isChecked) -> Log.i("SetupWizard", "Androidacy Repo: " + isChecked));
((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_magisk_alt_repo))).setOnCheckedChangeListener((buttonView, isChecked) -> Log.i("SetupWizard", "Magisk Alt Repo: " + isChecked));
}
// Setup popup dialogue for the setup_theme_button
MaterialButton themeButton = view.findViewById(R.id.setup_theme_button);
themeButton.setOnClickListener(v -> {
// Create a new dialog for the theme picker
MaterialAlertDialogBuilder builder = new MaterialAlertDialogBuilder(this);
builder.setTitle(R.string.setup_theme_title);
// Create a new array of theme names (system, light, dark, black, transparent light)
String[] themeNames = new String[]{getString(R.string.theme_system), getString(R.string.theme_light), getString(R.string.theme_dark), getString(R.string.theme_black), getString(R.string.theme_transparent_light)};
// Create a new array of theme values (system, light, dark, black, transparent_light)
String[] themeValues = new String[]{"system", "light", "dark", "black", "transparent_light"};
// if pref_theme is set, check the relevant theme_* menu item, otherwise check the default (theme_system)
String prefTheme = prefs.getString("pref_theme", "system");
int checkedItem = 0;
switch (prefTheme) {
case "system":
break;
case "light":
checkedItem = 1;
break;
case "dark":
checkedItem = 2;
break;
case "black":
checkedItem = 3;
break;
case "transparent_light":
checkedItem = 4;
break;
}
builder.setCancelable(true);
// Create the dialog
builder.setSingleChoiceItems(themeNames, checkedItem, (dialog, which) -> {
// Set the theme
prefs.edit().putString("pref_theme", themeValues[which]).commit();
// Restart the activity
UiThreadHandler.run(() -> {
Intent intent = getIntent();
finish();
startActivity(intent);
});
// Set the theme button text to the selected theme
themeButton.setText(themeNames[which]);
// Dismiss the dialog
dialog.dismiss();
// Set the theme
UiThreadHandler.handler.postDelayed(() -> {
switch (prefs.getString("pref_theme", "system")) {
case "light":
setTheme(R.style.Theme_MagiskModuleManager_Monet_Light);
break;
case "dark":
setTheme(R.style.Theme_MagiskModuleManager_Monet_Dark);
break;
case "system":
setTheme(R.style.Theme_MagiskModuleManager_Monet);
break;
case "black":
setTheme(R.style.Theme_MagiskModuleManager_Monet_Black);
break;
case "transparent_light":
setTheme(R.style.Theme_MagiskModuleManager_Transparent_Light);
break;
}
}, 100);
});
builder.show();
});
// Setup language selector
MaterialButton languageSelector = view.findViewById(R.id.setup_language_button);
languageSelector.setOnClickListener(preference -> {
LanguageSwitcher ls = new LanguageSwitcher(Objects.requireNonNull(getActivity(this)));
ls.setSupportedStringLocales(MainApplication.supportedLocales);
ls.showChangeLanguageDialog((FragmentActivity) getActivity(this));
});
// Set up the buttons
// Setup button
MaterialButton setupButton = view.findViewById(R.id.setup_continue);
setupButton.setOnClickListener(v -> {
// Set first launch to false
// get instance of editor
SharedPreferences.Editor editor = prefs.edit();
editor.putBoolean("first_time_user", false);
// Set the background update check pref
editor.putBoolean("pref_background_update_check", ((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_background_update_check))).isChecked());
// Set the crash reporting pref
editor.putBoolean("pref_crash_reporting", ((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_crash_reporting))).isChecked());
// Set the repos
// first pref_magisk_alt_repo_enabled then pref_androidacy_repo_enabled
editor.putBoolean("pref_magisk_alt_repo_enabled", ((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_magisk_alt_repo))).isChecked());
editor.putBoolean("pref_androidacy_repo_enabled", ((MaterialSwitch) Objects.requireNonNull(view.findViewById(R.id.setup_androidacy_repo))).isChecked());
// Commit the changes
editor.commit();
// Sleep for 1 second to allow the user to see the changes
try {
Thread.sleep(500);
} catch (
InterruptedException e) {
e.printStackTrace();
}
// Log the changes if debug
if (BuildConfig.DEBUG) {
Log.d("SetupWizard", "Background update check: " + prefs.getBoolean("pref_background_update_check", false));
Log.i("SetupWizard", "Crash reporting: " + prefs.getBoolean("pref_crash_reporting", false));
Log.i("SetupWizard", "Magisk Alt Repo: " + prefs.getBoolean("pref_magisk_alt_repo_enabled", false));
Log.i("SetupWizard", "Androidacy Repo: " + prefs.getBoolean("pref_androidacy_repo_enabled", false));
}
// Restart the activity
MainActivity.doSetupRestarting = true;
Intent intent = new Intent(this, MainActivity.class);
startActivity(intent);
finish();
});
// Cancel button
MaterialButton cancelButton = view.findViewById(R.id.setup_cancel);
cancelButton.setText(R.string.cancel);
cancelButton.setOnClickListener(v -> {
// Set first launch to false and restart the activity
prefs.edit().putBoolean("first_time_user", false).commit();
MainActivity.doSetupRestarting = true;
Intent intent = new Intent(this, MainActivity.class);
startActivity(intent);
finish();
});
}
@Override
public Resources.Theme getTheme() {
Resources.Theme theme = super.getTheme();
// Set the theme
SharedPreferences prefs = MainApplication.getSharedPreferences();
switch (prefs.getString("pref_theme", "system")) {
case "light":
theme.applyStyle(R.style.Theme_MagiskModuleManager_Monet_Light, true);
break;
case "dark":
theme.applyStyle(R.style.Theme_MagiskModuleManager_Monet_Dark, true);
break;
case "system":
theme.applyStyle(R.style.Theme_MagiskModuleManager_Monet, true);
break;
case "black":
theme.applyStyle(R.style.Theme_MagiskModuleManager_Monet_Black, true);
break;
case "transparent_light":
theme.applyStyle(R.style.Theme_MagiskModuleManager_Transparent_Light, true);
break;
}
return theme;
}
@Override
@SuppressLint({"InlinedApi", "RestrictedApi"})
public void refreshRosettaX() {
// refresh app language
runOnUiThread(() -> {
// refresh activity
Intent intent = getIntent();
finish();
startActivity(intent);
});
}
}

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/setup_box"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:fitsSystemWindowsInsets="left|right"
tools:context=".SetupActivity">
<include android:id="@+id/include2" layout="@layout/content_scrolling" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toBottomOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>

@ -0,0 +1,215 @@
<?xml version="1.0" encoding="utf-8"?>
<androidx.core.widget.NestedScrollView
xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
tools:context=".SetupActivity"
tools:showIn="@layout/activity_setup">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical"
android:padding="8dp">
<TextView
android:id="@+id/setup_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/setup_title" android:textAppearance="@style/TextAppearance.Material3.HeadlineSmall" app:layout_constraintEnd_toEndOf="parent" app:layout_constraintStart_toStartOf="parent" app:layout_constraintTop_toTopOf="@+id/setup_scroll" />
<com.google.android.material.textview.MaterialTextView
android:id="@+id/setup_summary"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/setup_message" />
<!-- Theme radio select. Options are system, light, dark, black, transparent_light -->
<!-- Button to trigger theme selection, half width, and in container with language -->
<LinearLayout
android:id="@+id/LinearLayout02"
android:layout_width="match_parent"
android:layout_height="wrap_content">
<com.google.android.material.button.MaterialButton
android:id="@+id/setup_theme_button"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="4dp"
android:layout_marginEnd="4dp"
android:layout_weight="1"
android:backgroundTint="@color/gray_900"
android:foreground="?attr/selectableItemBackground"
android:padding="12dp"
android:text="@string/setup_theme_button"
android:textColor="@color/white"
android:textSize="16sp"
app:icon="@drawable/ic_baseline_palette_24"
app:iconGravity="textStart"
app:iconPadding="8dp"
app:iconTint="@color/white"
app:iconTintMode="src_in"
app:rippleColor="@color/gray_800" tools:ignore="DuplicateSpeakableTextCheck" />
<com.google.android.material.button.MaterialButton
android:id="@+id/setup_language_button"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="4dp"
android:layout_marginTop="4dp"
android:layout_weight="1"
android:backgroundTint="@color/gray_900"
android:foreground="?attr/selectableItemBackground"
android:padding="12dp"
android:text="@string/setup_language_button"
android:textColor="@color/white"
android:textSize="16sp"
app:icon="@drawable/ic_baseline_language_24"
app:iconGravity="textStart"
app:iconPadding="8dp"
app:iconTint="@color/white"
app:iconTintMode="src_in"
app:rippleColor="@color/gray_800" tools:ignore="DuplicateSpeakableTextCheck" />
</LinearLayout>
<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:text="@string/repos"
android:textAppearance="@android:style/TextAppearance.Material.Headline" /><com.google.android.material.materialswitch.MaterialSwitch
android:id="@+id/setup_androidacy_repo"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:checked="false"
android:key="pref_androidacy_repo_enabled"
android:text="@string/setup_androidacy_repo"
android:textAppearance="@android:style/TextAppearance.Material.Subhead" />
<!-- Small summary for above switch -->
<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:drawableStart="@drawable/ic_baseline_info_24"
android:drawablePadding="8dp"
android:text="@string/setup_androidacy_repo_summary"
android:textAppearance="@android:style/TextAppearance.Material.Small" />
<com.google.android.material.materialswitch.MaterialSwitch
android:id="@+id/setup_magisk_alt_repo"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:checked="false"
android:key="pref_magisk_alt_repo_enabled"
android:text="@string/setup_magisk_alt_repo"
android:textAppearance="@android:style/TextAppearance.Material.Subhead" />
<!-- Small summary for above switch -->
<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:drawableStart="@drawable/ic_baseline_info_24"
android:drawablePadding="8dp"
android:text="@string/setup_magisk_alt_repo_summary"
android:textAppearance="@android:style/TextAppearance.Material.Small" />
<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:text="@string/setup_custom_repos"
android:textAppearance="@android:style/TextAppearance.Material.Caption" />
<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:text="@string/misc"
android:textAppearance="@android:style/TextAppearance.Material.Headline" />
<com.google.android.material.materialswitch.MaterialSwitch
android:id="@+id/setup_crash_reporting"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:checked="false"
android:key="pref_crash_reporting_enabled"
android:text="@string/setup_crash_reporting"
android:textAppearance="@android:style/TextAppearance.Material.Subhead" />
<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:drawableStart="@drawable/ic_baseline_info_24"
android:drawablePadding="8dp"
android:text="@string/setup_crash_reporting_summary"
android:textAppearance="@android:style/TextAppearance.Material.Small" />
<com.google.android.material.materialswitch.MaterialSwitch
android:id="@+id/setup_background_update_check"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:checked="false"
android:key="pref_background_update_check"
android:text="@string/setup_background_update_check"
android:textAppearance="@android:style/TextAppearance.Material.Subhead" />
<com.google.android.material.textview.MaterialTextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:drawableStart="@drawable/ic_baseline_info_24"
android:drawablePadding="8dp"
android:text="@string/setup_background_update_check_summary"
android:textAppearance="@android:style/TextAppearance.Material.Small"
app:icon="@drawable/ic_baseline_info_24" />
<!-- Placeholder for future settings -->
<!--<com.google.android.material.materialswitch.MaterialSwitch
android:id="@+id/setup_app_analytics"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_margin="4dp"
android:checked="false"
android:key="pref_app_analytics"
android:textAppearance="@android:style/TextAppearance.Material.Small"
android:text="@string/setup_app_analytics" />-->
<!-- Linear layout for the finish and cancel buttons -->
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom|end"
android:layout_margin="4dp"
android:orientation="horizontal">
<com.google.android.material.button.MaterialButton
android:id="@+id/setup_cancel"
android:layout_width="120dp"
android:layout_height="wrap_content"
android:layout_marginEnd="2dp"
android:layout_weight="1"
android:text="@string/cancel" android:textColor="#5D4037" />
<com.google.android.material.button.MaterialButton
android:id="@+id/setup_continue"
android:layout_width="120dp"
android:layout_height="wrap_content"
android:layout_weight="1"
android:text="@string/finish" android:textColor="#5D4037" />
</LinearLayout>
</LinearLayout>
</androidx.core.widget.NestedScrollView>

@ -0,0 +1,10 @@
<menu xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
tools:context="com.fox2code.mmm.SetupActivity">
<item
android:id="@+id/action_settings"
android:orderInCategory="100"
android:title="@string/action_settings"
app:showAsAction="never" />
</menu>

@ -3,7 +3,7 @@
<item>Dle systému</item>
<item>Tmavá</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Světlá</item>
</string-array>
</resources>

@ -4,7 +4,7 @@
<item>Systemvorgabe</item>
<item>Dunkel</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Hell</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Προεπιλογή συστήματως</item>
<item>Σκωτεινό</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Ανοιχτό</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Sistema</item>
<item>Oscuro</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Claro</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Süsteem</item>
<item>Tume</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Hele</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Système</item>
<item>Sombre</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Clair</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Sistem</item>
<item>Gelap</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Terang</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>システムの設定を使用</item>
<item>ダーク</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>ライト</item>
</string-array>
</resources>

@ -0,0 +1,4 @@
<resources>
<dimen name="fab_margin">48dp</dimen>
<dimen name="text_margin">48dp</dimen>
</resources>

@ -3,7 +3,7 @@
<item>Sistema</item>
<item>Escuro</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Claro</item>
</string-array>
</resources>

@ -5,7 +5,7 @@
<item>Sistem</item>
<item>Întunecată</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Luminoasă</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Как в системе</item>
<item>Тёмная</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Светлая</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Podľa systému</item>
<item>Tmavá</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Svetlá</item>
</string-array>
</resources>

@ -3,7 +3,7 @@
<item>Sistem</item>
<item>Koyu</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>ık</item>
</string-array>
</resources>

@ -4,7 +4,7 @@
<item>Hệ thống</item>
<item>Tối</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Sáng</item>
</string-array>
</resources>

@ -0,0 +1,3 @@
<resources>
<dimen name="fab_margin">200dp</dimen>
</resources>

@ -0,0 +1,4 @@
<resources>
<dimen name="fab_margin">48dp</dimen>
<dimen name="text_margin">48dp</dimen>
</resources>

@ -14,7 +14,7 @@
<item>System</item>
<item>Dark</item>
<item>AMOLED Black</item>
<item>Transparent (light)</item>
<item>Transparent</item>
<item>Light</item>
</string-array>
<string-array name="permission_notification_dont_ask_again">Don't prompt again</string-array>

@ -272,102 +272,15 @@
<string name="zip_load_failed">Could not load the zip file</string>
<string name="zip_prop_load_failed">Could not load the module properties</string>
<string name="zip_security_warning">Install %s?</string>
<string name="zip_intent_module_install">Do you really want to install the module \"%s\" from the ZIP file \"%s\"? Installing untrusted modules can lead to security risks.</string>
<string name="zip_intent_module_install">Do you really want to install the module \"%1$s\" from the ZIP file \"%2$s\"?\n\nMake sure you trust the source of this module, as modules are very powerful and can do almost anything.</string>
<string name="androidacy_thanks">Developed in part by Androidacy</string>
<string name="androidacy_thanks_desc">Huge shoutout to Androidacy for their integration and contributions to the app.</string>
<string name="contributors">And of course, thanks to all of our contributors, whether it\'s translations, code, or just being fun to hang out with! We love you all.</string>
<string name="zip_unpacking">Inspecting module…</string>
<string name="warning_message">Warning! This module has indicators it may have been installed without your knowledge, or may be attempting to hide itself. Uninstall is strongly recommended.</string>
<string name="understand">I understand</string><string name="setup_theme_title">Choose theme</string><string name="setup_language_button">Choose language</string>
<string name="title_activity_setup">SetupActivity</string>
<string name="large_text">
"Material is the metaphor.\n\n"
"A material metaphor is the unifying theory of a rationalized space and a system of motion."
"The material is grounded in tactile reality, inspired by the study of paper and ink, yet "
"technologically advanced and open to imagination and magic.\n"
"Surfaces and edges of the material provide visual cues that are grounded in reality. The "
"use of familiar tactile attributes helps users quickly understand affordances. Yet the "
"flexibility of the material creates new affordances that supercede those in the physical "
"world, without breaking the rules of physics.\n"
"The fundamentals of light, surface, and movement are key to conveying how objects move, "
"interact, and exist in space and in relation to each other. Realistic lighting shows "
"seams, divides space, and indicates moving parts.\n\n"
"Bold, graphic, intentional.\n\n"
"The foundational elements of print based design typography, grids, space, scale, color, "
"and use of imagery guide visual treatments. These elements do far more than please the "
"eye. They create hierarchy, meaning, and focus. Deliberate color choices, edge to edge "
"imagery, large scale typography, and intentional white space create a bold and graphic "
"interface that immerse the user in the experience.\n"
"An emphasis on user actions makes core functionality immediately apparent and provides "
"waypoints for the user.\n\n"
"Motion provides meaning.\n\n"
"Motion respects and reinforces the user as the prime mover. Primary user actions are "
"inflection points that initiate motion, transforming the whole design.\n"
"All action takes place in a single environment. Objects are presented to the user without "
"breaking the continuity of experience even as they transform and reorganize.\n"
"Motion is meaningful and appropriate, serving to focus attention and maintain continuity. "
"Feedback is subtle yet clear. Transitions are efficient yet coherent.\n\n"
"3D world.\n\n"
"The material environment is a 3D space, which means all objects have x, y, and z "
"dimensions. The z-axis is perpendicularly aligned to the plane of the display, with the "
"positive z-axis extending towards the viewer. Every sheet of material occupies a single "
"position along the z-axis and has a standard 1dp thickness.\n"
"On the web, the z-axis is used for layering and not for perspective. The 3D world is "
"emulated by manipulating the y-axis.\n\n"
"Light and shadow.\n\n"
"Within the material environment, virtual lights illuminate the scene. Key lights create "
"directional shadows, while ambient light creates soft shadows from all angles.\n"
"Shadows in the material environment are cast by these two light sources. In Android "
"development, shadows occur when light sources are blocked by sheets of material at "
"various positions along the z-axis. On the web, shadows are depicted by manipulating the "
"y-axis only. The following example shows the card with a height of 6dp.\n\n"
"Resting elevation.\n\n"
"All material objects, regardless of size, have a resting elevation, or default elevation "
"that does not change. If an object changes elevation, it should return to its resting "
"elevation as soon as possible.\n\n"
"Component elevations.\n\n"
"The resting elevation for a component type is consistent across apps (e.g., FAB elevation "
"does not vary from 6dp in one app to 16dp in another app).\n"
"Components may have different resting elevations across platforms, depending on the depth "
"of the environment (e.g., TV has a greater depth than mobile or desktop).\n\n"
"Responsive elevation and dynamic elevation offsets.\n\n"
"Some component types have responsive elevation, meaning they change elevation in response "
"to user input (e.g., normal, focused, and pressed) or system events. These elevation "
"changes are consistently implemented using dynamic elevation offsets.\n"
"Dynamic elevation offsets are the goal elevation that a component moves towards, relative "
"to the components resting state. They ensure that elevation changes are consistent "
"across actions and component types. For example, all components that lift on press have "
"the same elevation change relative to their resting elevation.\n"
"Once the input event is completed or cancelled, the component will return to its resting "
"elevation.\n\n"
"Avoiding elevation interference.\n\n"
"Components with responsive elevations may encounter other components as they move between "
"their resting elevations and dynamic elevation offsets. Because material cannot pass "
"through other material, components avoid interfering with one another any number of ways, "
"whether on a per component basis or using the entire app layout.\n"
"On a component level, components can move or be removed before they cause interference. "
"For example, a floating action button (FAB) can disappear or move off screen before a "
"user picks up a card, or it can move if a snackbar appears.\n"
"On the layout level, design your app layout to minimize opportunities for interference. "
"For example, position the FAB to one side of stream of a cards so the FAB wont interfere "
"when a user tries to pick up one of cards.\n\n"
</string>
<string name="warning_message">This module has indicators it may have been installed without your knowledge, or may be attempting to hide itself.\n\nUninstall is strongly recommended.</string>
<string name="understand">I understand</string>
<string name="setup_theme_title">Choose theme</string>
<string name="setup_language_button">Choose language</string>
<string name="title_activity_setup">Setup Wizard</string>
<string name="action_settings">Settings</string>
</resources>

@ -37,18 +37,23 @@
<item name="chipIconTint">@color/black</item>
</style>
<style name="Theme.MagiskModuleManager.Transparent.Light" parent="Theme.MagiskModuleManager.Light">
<style name="Theme.MagiskModuleManager.Transparent.Light" parent="Theme.MagiskModuleManager.Monet.Dark">
<item name="android:windowIsTranslucent">true</item>
<item name="android:windowBackground">@android:color/transparent</item>
<item name="android:windowContentOverlay">@null</item>
<item name="android:backgroundDimEnabled">false</item>
<item name="android:backgroundDimEnabled">true</item>
<item name="android:colorBackgroundCacheHint">@null</item>
<item name="android:windowAnimationStyle">@android:style/Animation</item>
<item name="android:windowTranslucentStatus">true</item>
<item name="android:statusBarColor">@android:color/transparent</item>
<item name="android:windowShowWallpaper">true</item>
<!-- Fix text color in transparent theme -->
<item name="alpha">0.8</item>
<item name="android:textColor">@color/white</item>
<item name="titleTextColor">@color/white</item>
<!-- Fix action bar padding in transparent theme -->
<item name="android:actionBarStyle">@style/Widget.Material3.ActionBar.Solid</item>
<!-- Action bar -->
<item name="actionBarStyle">@style/Widget.Material3.ActionBar.Solid</item>
</style>
<style name="Theme.MagiskModuleManager.Dark" parent="Theme.Material3.Dark">

Loading…
Cancel
Save