mirror of
https://github.com/ImranR98/Obtainium.git
synced 2025-08-11 17:40:15 +02:00
Add more links to the settings page (#1554)
This commit is contained in:
@@ -113,6 +113,7 @@
|
||||
"dark": "Tamna",
|
||||
"light": "Svijetla",
|
||||
"followSystem": "Pratite sistem",
|
||||
"followSystemThemeExplanation": "Following system theme is possible only by using third-party applications",
|
||||
"useBlackTheme": "Koristite čisto crnu tamnu temu",
|
||||
"appSortBy": "Aplikacije sortirane po",
|
||||
"authorName": "Autor/Ime",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "The APK could not be parsed (incompatible or partial download)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Share new Apps with AppVerifier (if available)",
|
||||
"appVerifierInstructionToast": "Share to AppVerifier, then return here when ready.",
|
||||
"wiki": "Help/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App Configurations (use at your own risk)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Želite li ukloniti aplikaciju?",
|
||||
"other": "Želite li ukloniti aplikacije?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Tmavé",
|
||||
"light": "Světlé",
|
||||
"followSystem": "Jako systém",
|
||||
"followSystemThemeExplanation": "Sledování motivu systému je možné pouze pomocí aplikací třetích stran.",
|
||||
"useBlackTheme": "Použít čistě černé tmavé téma",
|
||||
"appSortBy": "Seřadit podle",
|
||||
"authorName": "Autor/Jméno",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "APK nelze analyzovat (nekompatibilní nebo částečné stažení)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Sdílení nových aplikací s aplikací AppVerifier (pokud je k dispozici)",
|
||||
"appVerifierInstructionToast": "Sdílejte do aplikace AppVerifier a po dokončení se sem vraťte.",
|
||||
"wiki": "Nápověda/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Konfigurace aplikací s využitím crowdsourcingu (použití na vlastní nebezpečí)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Odstranit Apku?",
|
||||
"other": "Odstranit Apky?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Dunkel",
|
||||
"light": "Hell",
|
||||
"followSystem": "System folgen",
|
||||
"followSystemThemeExplanation": "Das folgende Systemthema ist nur durch die Verwendung von Drittanbieteranwendungen möglich",
|
||||
"useBlackTheme": "Verwende Pure Black Dark Theme",
|
||||
"appSortBy": "App sortieren nach",
|
||||
"authorName": "Autor/Name",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "Die APK konnte nicht geparst werden (inkompatibler oder teilweiser Download)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Neue Apps mit AppVerifier teilen (falls verfügbar)",
|
||||
"appVerifierInstructionToast": "Geben Sie die Daten an AppVerifier weiter und kehren Sie dann hierher zurück, wenn Sie fertig sind.",
|
||||
"wiki": "Hilfe/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App Configurations (Verwendung auf eigene Gefahr)",
|
||||
"removeAppQuestion": {
|
||||
"one": "App entfernen?",
|
||||
"other": "Apps entfernen?"
|
||||
|
@@ -310,6 +310,8 @@
|
||||
"badDownload": "The APK could not be parsed (incompatible or partial download)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Share new Apps with AppVerifier (if available)",
|
||||
"appVerifierInstructionToast": "Share to AppVerifier, then return here when ready.",
|
||||
"wiki": "Help/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App Configurations (use at your own risk)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Remove App?",
|
||||
"other": "Remove Apps?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Oscuro",
|
||||
"light": "Claro",
|
||||
"followSystem": "Seguir al sistema",
|
||||
"followSystemThemeExplanation": "Seguir el tema del sistema sólo es posible utilizando aplicaciones de terceros",
|
||||
"useBlackTheme": "Negro puro en tema oscuro",
|
||||
"appSortBy": "Ordenar aplicaciones por",
|
||||
"authorName": "Autor/nombre",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "No se ha podido analizar el APK (incompatible o descarga parcial)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Compartir nuevas aplicaciones con AppVerifier (si está disponible)",
|
||||
"appVerifierInstructionToast": "Comparta con AppVerifier y vuelva aquí cuando esté listo.",
|
||||
"wiki": "Ayuda/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App Configurations (uso bajo su propia responsabilidad)",
|
||||
"removeAppQuestion": {
|
||||
"one": "¿Eliminar aplicación?",
|
||||
"other": "¿Eliminar aplicaciones?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "تاریک",
|
||||
"light": "روشن",
|
||||
"followSystem": "هماهنگ با سیستم",
|
||||
"followSystemThemeExplanation": "Following system theme is possible only by using third-party applications",
|
||||
"useBlackTheme": "استفاده از تم تیره سیاه خالص",
|
||||
"appSortBy": "مرتب سازی برنامه بر اساس",
|
||||
"authorName": "سازنده/اسم",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "The APK could not be parsed (incompatible or partial download)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Share new Apps with AppVerifier (if available)",
|
||||
"appVerifierInstructionToast": "Share to AppVerifier, then return here when ready.",
|
||||
"wiki": "Help/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App Configurations (use at your own risk)",
|
||||
"removeAppQuestion": {
|
||||
"one": "برنامه حذف شود؟",
|
||||
"other": "برنامه ها حذف شوند؟"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Sombre",
|
||||
"light": "Clair",
|
||||
"followSystem": "Suivre le système",
|
||||
"followSystemThemeExplanation": "Il n'est possible de suivre le thème du système qu'en utilisant des applications tierces.",
|
||||
"useBlackTheme": "Utilisez le thème noir pur",
|
||||
"appSortBy": "Applications triées par",
|
||||
"authorName": "Auteur/Nom",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "L'APK n'a pas pu être analysé (téléchargement incompatible ou partiel)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Partager les nouvelles applications avec AppVerifier (si disponible)",
|
||||
"appVerifierInstructionToast": "Partagez avec AppVerifier, puis revenez ici lorsque vous êtes prêt.",
|
||||
"wiki": "Aide/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Configurations d'applications par la foule (utilisation à vos risques et périls)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Supprimer l'application ?",
|
||||
"other": "Supprimer les applications ?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Sötét",
|
||||
"light": "Világos",
|
||||
"followSystem": "Rendszer szerint",
|
||||
"followSystemThemeExplanation": "A következő rendszer téma csak harmadik féltől származó alkalmazások használatával lehetséges",
|
||||
"useBlackTheme": "Használjon teljesen fekete sötét témát",
|
||||
"appSortBy": "App rendezés...",
|
||||
"authorName": "Szerző/Név",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "Az APK-t nem lehetett elemezni (inkompatibilis vagy részleges letöltés)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Új alkalmazások megosztása az AppVerifierrel (ha elérhető)",
|
||||
"appVerifierInstructionToast": "Ossza meg az AppVerifierrel, majd térjen vissza ide, ha kész.",
|
||||
"wiki": "Súgó/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App Configurations (használat saját felelősségre)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Eltávolítja az alkalmazást?",
|
||||
"other": "Eltávolítja az alkalmazásokat?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Scuro",
|
||||
"light": "Chiaro",
|
||||
"followSystem": "Segui il sistema",
|
||||
"followSystemThemeExplanation": "È possibile seguire il tema di sistema solo utilizzando applicazioni di terze parti.",
|
||||
"useBlackTheme": "Usa il tema nero puro",
|
||||
"appSortBy": "App ordinate per",
|
||||
"authorName": "Autore/Nome",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "Non è stato possibile analizzare l'APK (download incompatibile o parziale).",
|
||||
"beforeNewInstallsShareToAppVerifier": "Condividere le nuove applicazioni con AppVerifier (se disponibile)",
|
||||
"appVerifierInstructionToast": "Condividete con AppVerifier, quindi tornate qui quando siete pronti.",
|
||||
"wiki": "Aiuto/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Configurazioni di app in crowdsourcing (uso a proprio rischio)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Rimuovere l'app?",
|
||||
"other": "Rimuovere le app?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "ダーク",
|
||||
"light": "ライト",
|
||||
"followSystem": "システムに従う",
|
||||
"followSystemThemeExplanation": "以下のシステムテーマは、サードパーティのアプリケーションを使用することによってのみ可能です。",
|
||||
"useBlackTheme": "ピュアブラックダークテーマを使用する",
|
||||
"appSortBy": "アプリの並び方",
|
||||
"authorName": "作者名/アプリ名",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "APK を解析できませんでした(互換性がないか、部分的にダウンロードされています)。",
|
||||
"beforeNewInstallsShareToAppVerifier": "AppVerifierで新しいアプリを共有する(利用可能な場合)",
|
||||
"appVerifierInstructionToast": "AppVerifierに共有し、準備ができたらここに戻ってください。",
|
||||
"wiki": "ヘルプ/ウィキ",
|
||||
"crowdsourcedConfigsLabel": "クラウドソーシングによるアプリの設定(利用は自己責任で)",
|
||||
"removeAppQuestion": {
|
||||
"one": "アプリを削除しますか?",
|
||||
"other": "アプリを削除しますか?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Donker",
|
||||
"light": "Licht",
|
||||
"followSystem": "Volg systeem",
|
||||
"followSystemThemeExplanation": "Het volgende systeemthema is alleen mogelijk met toepassingen van derden",
|
||||
"useBlackTheme": "Gebruik zwart thema",
|
||||
"appSortBy": "App sorteren op",
|
||||
"authorName": "Auteur/Naam",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "De APK kon niet worden verwerkt (incompatibele of gedeeltelijke download)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Nieuwe Apps delen met AppVerifier (indien beschikbaar)",
|
||||
"appVerifierInstructionToast": "Deel naar AppVerifier en keer hier terug als je klaar bent.",
|
||||
"wiki": "Help/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App-configuraties (gebruik op eigen risico)",
|
||||
"removeAppQuestion": {
|
||||
"one": "App verwijderen?",
|
||||
"other": "Apps verwijderen?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Ciemny",
|
||||
"light": "Jasny",
|
||||
"followSystem": "Zgodny z systemem",
|
||||
"followSystemThemeExplanation": "Podążanie za motywem systemowym jest możliwe tylko przy użyciu aplikacji firm trzecich",
|
||||
"useBlackTheme": "Użyj czarnego motywu",
|
||||
"appSortBy": "Sortuj aplikacje według",
|
||||
"authorName": "Autor/Nazwa",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "Nie można przeanalizować pliku APK (niekompatybilny lub częściowo pobrany).",
|
||||
"beforeNewInstallsShareToAppVerifier": "Udostępnianie nowych aplikacji za pomocą AppVerifier (jeśli dostępne)",
|
||||
"appVerifierInstructionToast": "Udostępnij w AppVerifier, a następnie wróć tutaj, gdy będziesz gotowy.",
|
||||
"wiki": "Pomoc/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Konfiguracje aplikacji pochodzące z crowdsourcingu (korzystanie na własne ryzyko)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Usunąć aplikację?",
|
||||
"few": "Usunąć aplikacje?",
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Escuro",
|
||||
"light": "Claro",
|
||||
"followSystem": "Padrão do sistema",
|
||||
"followSystemThemeExplanation": "O tema do sistema seguinte só é possível através da utilização de aplicações de terceiros",
|
||||
"useBlackTheme": "Usar tema preto AMOLED",
|
||||
"appSortBy": "Classificar aplicativo por",
|
||||
"authorName": "Autor/Nome",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "Não foi possível analisar o APK (transferência incompatível ou parcial)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Partilhar novas aplicações com o AppVerifier (se disponível)",
|
||||
"appVerifierInstructionToast": "Partilhe com o AppVerifier e, em seguida, regresse aqui quando estiver pronto.",
|
||||
"wiki": "Ajuda/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Configurações de aplicações de crowdsourcing (utilização por sua conta e risco)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Remover aplicativo?",
|
||||
"other": "Remover aplicativos?"
|
||||
|
@@ -310,6 +310,8 @@
|
||||
"badDownload": "APK не удалось разобрать (несовместимая или неполная загрузка)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Поделитесь новыми приложениями с AppVerifier (если доступно)",
|
||||
"appVerifierInstructionToast": "Поделитесь с AppVerifier, а затем вернитесь сюда, когда будете готовы.",
|
||||
"wiki": "Помощь/Вики",
|
||||
"crowdsourcedConfigsLabel": "Конфигурации приложений на основе краудсорсинга (используйте на свой страх и риск)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Удалить приложение?",
|
||||
"other": "Удалить приложения?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Mörkt",
|
||||
"light": "Ljust",
|
||||
"followSystem": "Följ System",
|
||||
"followSystemThemeExplanation": "Följande systemtema är endast möjligt med hjälp av tredjepartsapplikationer",
|
||||
"useBlackTheme": "Använd svart tema",
|
||||
"appSortBy": "Sortera Appar via",
|
||||
"authorName": "Utvecklare/Namn",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "APK kunde inte analyseras (inkompatibel eller partiell nedladdning)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Dela nya appar med AppVerifier (om tillgängligt)",
|
||||
"appVerifierInstructionToast": "Dela till AppVerifier och återvänd sedan hit när du är klar.",
|
||||
"wiki": "Hjälp/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourcade appkonfigurationer (använd på egen risk)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Ta Bort App?",
|
||||
"other": "Ta Bort Appar?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Koyu",
|
||||
"light": "Aydınlık",
|
||||
"followSystem": "Sistemi Takip Et",
|
||||
"followSystemThemeExplanation": "Sistem temasını takip etmek yalnızca üçüncü taraf uygulamaları kullanarak mümkündür",
|
||||
"useBlackTheme": "Saf siyah koyu temasını kullan",
|
||||
"appSortBy": "Uygulama Sıralama Ölçütü",
|
||||
"authorName": "Yazar/Ad",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "APK ayrıştırılamadı (uyumsuz veya kısmi indirme)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Yeni Uygulamaları AppVerifier ile paylaşın (varsa)",
|
||||
"appVerifierInstructionToast": "AppVerifier ile paylaşın, hazır olduğunuzda buraya dönün.",
|
||||
"wiki": "Yardım/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Kitle Kaynaklı Uygulama Yapılandırmaları (riski size ait olmak üzere kullanın)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Uygulamayı Kaldır?",
|
||||
"other": "Uygulamaları Kaldır?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Темна",
|
||||
"light": "Світла",
|
||||
"followSystem": "Дотримуватися системи",
|
||||
"followSystemThemeExplanation": "Зміна теми системи можлива лише за допомогою сторонніх додатків",
|
||||
"useBlackTheme": "Використовувати чорну тему (Amoled)",
|
||||
"appSortBy": "Сортувати застосунки за",
|
||||
"authorName": "Автор/Назва",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "APK не вдалося розпарсити (несумісний або часткове завантаження)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Діліться новими додатками з AppVerifier (якщо доступно)",
|
||||
"appVerifierInstructionToast": "Надішліть на AppVerifier, а потім поверніться сюди, коли будете готові.",
|
||||
"wiki": "Довідка/Вікі",
|
||||
"crowdsourcedConfigsLabel": "Краудсорсингові конфігурації додатків (використовуйте на свій страх і ризик)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Видалити застосунок?",
|
||||
"other": "Видалити застосунки?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "Tối",
|
||||
"light": "Sáng",
|
||||
"followSystem": "Theo hệ thống",
|
||||
"followSystemThemeExplanation": "Following system theme is possible only by using third-party applications",
|
||||
"useBlackTheme": "Nền đen",
|
||||
"appSortBy": "Sắp xếp ứng dụng",
|
||||
"authorName": "Tác giả",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "Không thể phân tích cú pháp APK (tải xuống một phần hoặc không tương thích)",
|
||||
"beforeNewInstallsShareToAppVerifier": "Chia sẻ ứng dụng mới với AppVerifier (nếu có)",
|
||||
"appVerifierInstructionToast": "Chia sẻ lên AppVerifier, sau đó quay lại đây khi sẵn sàng.",
|
||||
"wiki": "Help/Wiki",
|
||||
"crowdsourcedConfigsLabel": "Crowdsourced App Configurations (use at your own risk)",
|
||||
"removeAppQuestion": {
|
||||
"one": "Gỡ ứng dụng?",
|
||||
"other": "Gỡ ứng dụng?"
|
||||
|
@@ -113,6 +113,7 @@
|
||||
"dark": "深色",
|
||||
"light": "浅色",
|
||||
"followSystem": "跟随系统",
|
||||
"followSystemThemeExplanation": "只有使用第三方应用程序,才有可能跟踪系统主题",
|
||||
"useBlackTheme": "使用纯黑深色主题",
|
||||
"appSortBy": "排序依据",
|
||||
"authorName": "作者 / 应用名称",
|
||||
@@ -309,6 +310,8 @@
|
||||
"badDownload": "无法解析 APK 文件(不兼容或文件不完整)",
|
||||
"beforeNewInstallsShareToAppVerifier": "与 AppVerifier 共享新应用程序(如有)",
|
||||
"appVerifierInstructionToast": "分享到 AppVerifier,准备就绪后返回此处。",
|
||||
"wiki": "帮助/维基",
|
||||
"crowdsourcedConfigsLabel": "众包应用程序配置(使用风险自负)",
|
||||
"removeAppQuestion": {
|
||||
"one": "是否删除应用?",
|
||||
"other": "是否删除应用?"
|
||||
|
@@ -26,20 +26,33 @@ class SettingsPage extends StatefulWidget {
|
||||
|
||||
class _SettingsPageState extends State<SettingsPage> {
|
||||
List<int> updateIntervalNodes = [
|
||||
15, 30, 60, 120, 180, 360, 720, 1440, 4320, 10080, 20160, 43200];
|
||||
15,
|
||||
30,
|
||||
60,
|
||||
120,
|
||||
180,
|
||||
360,
|
||||
720,
|
||||
1440,
|
||||
4320,
|
||||
10080,
|
||||
20160,
|
||||
43200
|
||||
];
|
||||
int updateInterval = 0;
|
||||
late SplineInterpolation updateIntervalInterpolator; // 🤓
|
||||
late SplineInterpolation updateIntervalInterpolator; // 🤓
|
||||
String updateIntervalLabel = tr('neverManualOnly');
|
||||
bool showIntervalLabel = true;
|
||||
final Map<ColorSwatch<Object>, String> colorsNameMap =
|
||||
<ColorSwatch<Object>, String> {
|
||||
<ColorSwatch<Object>, String>{
|
||||
ColorTools.createPrimarySwatch(obtainiumThemeColor): 'Obtainium'
|
||||
};
|
||||
|
||||
void initUpdateIntervalInterpolator() {
|
||||
List<InterpolationNode> nodes = [];
|
||||
for (final (index, element) in updateIntervalNodes.indexed) {
|
||||
nodes.add(InterpolationNode(x: index.toDouble()+1, y: element.toDouble()));
|
||||
nodes.add(
|
||||
InterpolationNode(x: index.toDouble() + 1, y: element.toDouble()));
|
||||
}
|
||||
updateIntervalInterpolator = SplineInterpolation(nodes: nodes);
|
||||
}
|
||||
@@ -69,7 +82,7 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
int valRounded = (valInterpolated / 30).floor() * 30;
|
||||
updateInterval = valRounded;
|
||||
updateIntervalLabel = plural('hour', valRounded / 60);
|
||||
} else if (valInterpolated < 7 * 24 * 60){
|
||||
} else if (valInterpolated < 7 * 24 * 60) {
|
||||
int valRounded = (valInterpolated / (12 * 60)).floor() * 12 * 60;
|
||||
updateInterval = valRounded;
|
||||
updateIntervalLabel = plural('day', valRounded / (24 * 60));
|
||||
@@ -90,21 +103,18 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
|
||||
var followSystemThemeExplanation = FutureBuilder(
|
||||
builder: (ctx, val) {
|
||||
return ((val.data?.version.sdkInt ?? 30) < 29) ?
|
||||
Text(tr('followSystemThemeExplanation'),
|
||||
style: Theme.of(context).textTheme.labelSmall)
|
||||
: const SizedBox.shrink();
|
||||
return ((val.data?.version.sdkInt ?? 30) < 29)
|
||||
? Text(tr('followSystemThemeExplanation'),
|
||||
style: Theme.of(context).textTheme.labelSmall)
|
||||
: const SizedBox.shrink();
|
||||
},
|
||||
future: DeviceInfoPlugin().androidInfo
|
||||
);
|
||||
future: DeviceInfoPlugin().androidInfo);
|
||||
|
||||
Future<bool> colorPickerDialog() async {
|
||||
return ColorPicker(
|
||||
color: settingsProvider.themeColor,
|
||||
onColorChanged: (Color color) =>
|
||||
setState(() =>
|
||||
settingsProvider.themeColor = color
|
||||
),
|
||||
setState(() => settingsProvider.themeColor = color),
|
||||
actionButtons: const ColorPickerActionButtons(
|
||||
okButton: true,
|
||||
closeButton: true,
|
||||
@@ -137,19 +147,17 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
showColorName: true,
|
||||
materialNameTextStyle: Theme.of(context).textTheme.bodySmall,
|
||||
colorNameTextStyle: Theme.of(context).textTheme.bodySmall,
|
||||
copyPasteBehavior: const ColorPickerCopyPasteBehavior(longPressMenu: true),
|
||||
copyPasteBehavior:
|
||||
const ColorPickerCopyPasteBehavior(longPressMenu: true),
|
||||
).showPickerDialog(
|
||||
context,
|
||||
transitionBuilder: (BuildContext context,
|
||||
Animation<double> a1, Animation<double> a2, Widget widget) {
|
||||
transitionBuilder: (BuildContext context, Animation<double> a1,
|
||||
Animation<double> a2, Widget widget) {
|
||||
final double curvedValue = Curves.easeInCubic.transform(a1.value);
|
||||
return Transform(
|
||||
alignment: Alignment.center,
|
||||
transform: Matrix4.diagonal3Values(curvedValue, curvedValue, 1),
|
||||
child: Opacity(
|
||||
opacity: curvedValue,
|
||||
child: widget
|
||||
),
|
||||
child: Opacity(opacity: curvedValue, child: widget),
|
||||
);
|
||||
},
|
||||
transitionDuration: const Duration(milliseconds: 250),
|
||||
@@ -157,46 +165,44 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
}
|
||||
|
||||
var colorPicker = ListTile(
|
||||
dense: true,
|
||||
contentPadding: EdgeInsets.zero,
|
||||
title: Text(tr('selectX', args: [tr('colour')])),
|
||||
subtitle: Text("${ColorTools.nameThatColor(settingsProvider.themeColor)} "
|
||||
"(${ColorTools.materialNameAndCode(settingsProvider.themeColor,
|
||||
colorSwatchNameMap: colorsNameMap)})"),
|
||||
trailing: ColorIndicator(
|
||||
width: 40,
|
||||
height: 40,
|
||||
borderRadius: 20,
|
||||
color: settingsProvider.themeColor,
|
||||
onSelectFocus: false,
|
||||
onSelect: () async {
|
||||
final Color colorBeforeDialog = settingsProvider.themeColor;
|
||||
if (!(await colorPickerDialog())) {
|
||||
setState(() {
|
||||
settingsProvider.themeColor = colorBeforeDialog;
|
||||
});
|
||||
}
|
||||
}
|
||||
)
|
||||
);
|
||||
dense: true,
|
||||
contentPadding: EdgeInsets.zero,
|
||||
title: Text(tr('selectX', args: [tr('colour')])),
|
||||
subtitle: Text(
|
||||
"${ColorTools.nameThatColor(settingsProvider.themeColor)} "
|
||||
"(${ColorTools.materialNameAndCode(settingsProvider.themeColor, colorSwatchNameMap: colorsNameMap)})"),
|
||||
trailing: ColorIndicator(
|
||||
width: 40,
|
||||
height: 40,
|
||||
borderRadius: 20,
|
||||
color: settingsProvider.themeColor,
|
||||
onSelectFocus: false,
|
||||
onSelect: () async {
|
||||
final Color colorBeforeDialog = settingsProvider.themeColor;
|
||||
if (!(await colorPickerDialog())) {
|
||||
setState(() {
|
||||
settingsProvider.themeColor = colorBeforeDialog;
|
||||
});
|
||||
}
|
||||
}));
|
||||
|
||||
var useMaterialThemeSwitch = FutureBuilder(
|
||||
builder: (ctx, val) {
|
||||
return ((val.data?.version.sdkInt ?? 0) >= 31) ?
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Flexible(child: Text(tr('useMaterialYou'))),
|
||||
Switch(
|
||||
value: settingsProvider.useMaterialYou,
|
||||
onChanged: (value) {
|
||||
settingsProvider.useMaterialYou = value;
|
||||
})
|
||||
],
|
||||
) : const SizedBox.shrink();
|
||||
return ((val.data?.version.sdkInt ?? 0) >= 31)
|
||||
? Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Flexible(child: Text(tr('useMaterialYou'))),
|
||||
Switch(
|
||||
value: settingsProvider.useMaterialYou,
|
||||
onChanged: (value) {
|
||||
settingsProvider.useMaterialYou = value;
|
||||
})
|
||||
],
|
||||
)
|
||||
: const SizedBox.shrink();
|
||||
},
|
||||
future: DeviceInfoPlugin().androidInfo
|
||||
);
|
||||
future: DeviceInfoPlugin().androidInfo);
|
||||
|
||||
var sortDropdown = DropdownButtonFormField(
|
||||
isExpanded: true,
|
||||
@@ -343,13 +349,20 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
),
|
||||
//intervalDropdown,
|
||||
height16,
|
||||
if (showIntervalLabel) SizedBox(
|
||||
child: Text("${tr('bgUpdateCheckInterval')}: $updateIntervalLabel")
|
||||
) else const SizedBox(height: 16),
|
||||
if (showIntervalLabel)
|
||||
SizedBox(
|
||||
child: Text(
|
||||
"${tr('bgUpdateCheckInterval')}: $updateIntervalLabel"))
|
||||
else
|
||||
const SizedBox(height: 16),
|
||||
intervalSlider,
|
||||
FutureBuilder(
|
||||
builder: (ctx, val) {
|
||||
return (settingsProvider.updateInterval > 0) && (((val.data?.version.sdkInt ?? 0) >= 30) || settingsProvider.useShizuku)
|
||||
return (settingsProvider.updateInterval >
|
||||
0) &&
|
||||
(((val.data?.version.sdkInt ?? 0) >=
|
||||
30) ||
|
||||
settingsProvider.useShizuku)
|
||||
? Column(
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.start,
|
||||
@@ -491,33 +504,33 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
children: [
|
||||
Flexible(
|
||||
child: Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Text(tr(
|
||||
'beforeNewInstallsShareToAppVerifier')),
|
||||
GestureDetector(
|
||||
onTap: () {
|
||||
launchUrlString(
|
||||
'https://github.com/soupslurpr/AppVerifier',
|
||||
mode: LaunchMode
|
||||
.externalApplication);
|
||||
},
|
||||
child: Text(
|
||||
tr('about'),
|
||||
style: const TextStyle(
|
||||
decoration:
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
Text(tr(
|
||||
'beforeNewInstallsShareToAppVerifier')),
|
||||
GestureDetector(
|
||||
onTap: () {
|
||||
launchUrlString(
|
||||
'https://github.com/soupslurpr/AppVerifier',
|
||||
mode: LaunchMode
|
||||
.externalApplication);
|
||||
},
|
||||
child: Text(
|
||||
tr('about'),
|
||||
style: const TextStyle(
|
||||
decoration:
|
||||
TextDecoration.underline,
|
||||
fontSize: 12),
|
||||
)),
|
||||
],
|
||||
)),
|
||||
fontSize: 12),
|
||||
)),
|
||||
],
|
||||
)),
|
||||
Switch(
|
||||
value: settingsProvider
|
||||
.beforeNewInstallsShareToAppVerifier,
|
||||
onChanged: (value) {
|
||||
settingsProvider
|
||||
.beforeNewInstallsShareToAppVerifier =
|
||||
.beforeNewInstallsShareToAppVerifier =
|
||||
value;
|
||||
})
|
||||
],
|
||||
@@ -531,17 +544,31 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
value: settingsProvider.useShizuku,
|
||||
onChanged: (useShizuku) {
|
||||
if (useShizuku) {
|
||||
ShizukuApkInstaller.checkPermission().then((resCode) {
|
||||
settingsProvider.useShizuku = resCode!.startsWith('granted');
|
||||
switch(resCode){
|
||||
ShizukuApkInstaller.checkPermission()
|
||||
.then((resCode) {
|
||||
settingsProvider.useShizuku =
|
||||
resCode!.startsWith('granted');
|
||||
switch (resCode) {
|
||||
case 'binder_not_found':
|
||||
showError(ObtainiumError(tr('shizukuBinderNotFound')), context);
|
||||
showError(
|
||||
ObtainiumError(tr(
|
||||
'shizukuBinderNotFound')),
|
||||
context);
|
||||
case 'old_shizuku':
|
||||
showError(ObtainiumError(tr('shizukuOld')), context);
|
||||
showError(
|
||||
ObtainiumError(
|
||||
tr('shizukuOld')),
|
||||
context);
|
||||
case 'old_android_with_adb':
|
||||
showError(ObtainiumError(tr('shizukuOldAndroidWithADB')), context);
|
||||
showError(
|
||||
ObtainiumError(tr(
|
||||
'shizukuOldAndroidWithADB')),
|
||||
context);
|
||||
case 'denied':
|
||||
showError(ObtainiumError(tr('cancelled')), context);
|
||||
showError(
|
||||
ObtainiumError(
|
||||
tr('cancelled')),
|
||||
context);
|
||||
}
|
||||
});
|
||||
} else {
|
||||
@@ -566,7 +593,8 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
color: Theme.of(context).colorScheme.primary),
|
||||
),
|
||||
DropdownButtonFormField(
|
||||
decoration: InputDecoration(labelText: tr('theme')),
|
||||
decoration:
|
||||
InputDecoration(labelText: tr('theme')),
|
||||
value: settingsProvider.theme,
|
||||
items: [
|
||||
DropdownMenuItem(
|
||||
@@ -593,17 +621,17 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
height16,
|
||||
if (settingsProvider.theme != ThemeSettings.light)
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Flexible(child: Text(tr('useBlackTheme'))),
|
||||
Switch(
|
||||
value: settingsProvider.useBlackTheme,
|
||||
onChanged: (value) {
|
||||
settingsProvider.useBlackTheme = value;
|
||||
}
|
||||
)
|
||||
]
|
||||
),
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Flexible(child: Text(tr('useBlackTheme'))),
|
||||
Switch(
|
||||
value: settingsProvider.useBlackTheme,
|
||||
onChanged: (value) {
|
||||
settingsProvider.useBlackTheme =
|
||||
value;
|
||||
})
|
||||
]),
|
||||
height8,
|
||||
useMaterialThemeSwitch,
|
||||
if (!settingsProvider.useMaterialYou) colorPicker,
|
||||
@@ -624,28 +652,39 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
builder: (ctx, val) {
|
||||
return (val.data?.version.sdkInt ?? 0) >= 34
|
||||
? Column(
|
||||
crossAxisAlignment: CrossAxisAlignment.start,
|
||||
children: [
|
||||
height16,
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceBetween,
|
||||
children: [
|
||||
Flexible(child: Text(tr('useSystemFont'))),
|
||||
Switch(
|
||||
value: settingsProvider.useSystemFont,
|
||||
onChanged: (useSystemFont) {
|
||||
if (useSystemFont) {
|
||||
NativeFeatures.loadSystemFont().then((val) {
|
||||
settingsProvider.useSystemFont = true;
|
||||
});
|
||||
} else {
|
||||
settingsProvider.useSystemFont = false;
|
||||
}
|
||||
})
|
||||
]
|
||||
)
|
||||
]
|
||||
)
|
||||
crossAxisAlignment:
|
||||
CrossAxisAlignment.start,
|
||||
children: [
|
||||
height16,
|
||||
Row(
|
||||
mainAxisAlignment:
|
||||
MainAxisAlignment
|
||||
.spaceBetween,
|
||||
children: [
|
||||
Flexible(
|
||||
child: Text(tr(
|
||||
'useSystemFont'))),
|
||||
Switch(
|
||||
value: settingsProvider
|
||||
.useSystemFont,
|
||||
onChanged:
|
||||
(useSystemFont) {
|
||||
if (useSystemFont) {
|
||||
NativeFeatures
|
||||
.loadSystemFont()
|
||||
.then((val) {
|
||||
settingsProvider
|
||||
.useSystemFont =
|
||||
true;
|
||||
});
|
||||
} else {
|
||||
settingsProvider
|
||||
.useSystemFont =
|
||||
false;
|
||||
}
|
||||
})
|
||||
])
|
||||
])
|
||||
: const SizedBox.shrink();
|
||||
},
|
||||
future: DeviceInfoPlugin().androidInfo),
|
||||
@@ -801,17 +840,31 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
Row(
|
||||
mainAxisAlignment: MainAxisAlignment.spaceAround,
|
||||
children: [
|
||||
TextButton.icon(
|
||||
IconButton(
|
||||
onPressed: () {
|
||||
launchUrlString(settingsProvider.sourceUrl,
|
||||
mode: LaunchMode.externalApplication);
|
||||
},
|
||||
icon: const Icon(Icons.code),
|
||||
label: Text(
|
||||
tr('appSource'),
|
||||
),
|
||||
tooltip: tr('appSource'),
|
||||
),
|
||||
TextButton.icon(
|
||||
IconButton(
|
||||
onPressed: () {
|
||||
launchUrlString('${settingsProvider.sourceUrl}/wiki',
|
||||
mode: LaunchMode.externalApplication);
|
||||
},
|
||||
icon: const Icon(Icons.help_outline_rounded),
|
||||
tooltip: tr('wiki'),
|
||||
),
|
||||
IconButton(
|
||||
onPressed: () {
|
||||
launchUrlString('https://apps.obtainium.imranr.dev/',
|
||||
mode: LaunchMode.externalApplication);
|
||||
},
|
||||
icon: const Icon(Icons.apps_rounded),
|
||||
tooltip: tr('crowdsourcedConfigsLabel'),
|
||||
),
|
||||
IconButton(
|
||||
onPressed: () {
|
||||
context.read<LogsProvider>().get().then((logs) {
|
||||
if (logs.isEmpty) {
|
||||
@@ -827,7 +880,7 @@ class _SettingsPageState extends State<SettingsPage> {
|
||||
});
|
||||
},
|
||||
icon: const Icon(Icons.bug_report_outlined),
|
||||
label: Text(tr('appLogs'))),
|
||||
tooltip: tr('appLogs'))
|
||||
],
|
||||
),
|
||||
const SizedBox(
|
||||
|
Reference in New Issue
Block a user