Skip to content

Commit

Permalink
Fixed merge conflicts
Browse files Browse the repository at this point in the history
  • Loading branch information
BenjaminHalko committed Feb 17, 2024
1 parent 0cb84be commit aa7a8c4
Show file tree
Hide file tree
Showing 7 changed files with 50 additions and 55 deletions.
Empty file removed assets/i18n/en_US.json
Empty file.
12 changes: 11 additions & 1 deletion assets/i18n/strings.i18n.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,12 @@
"refreshSuccess": "Refreshed successfully",
"widgetTitle": "Dashboard",
"updatesSubtitle": "Updates",
"patchedSubtitle": "Patched apps",
"patchHistorySubtitle": "Last patch",
"patchedSubtitle": "Installed apps",
"changeLaterSubtitle": "You can change this in the settings at a later time.",
"noUpdates": "No updates available",
"WIP": "Work in progress...",
"noHistory": "No app found",
"noInstallations": "No patched apps installed",
"installUpdate": "Continue to install the update?",
"updateSheetTitle": "Update ReVanced Manager",
Expand Down Expand Up @@ -201,6 +203,8 @@
"showUpdateDialogHint": "Show a dialog when a new update is available",
"universalPatchesLabel": "Show universal patches",
"universalPatchesHint": "Display all apps and universal patches (may slow down the app list)",
"patchHistoryLabel": "Save patched app",
"patchHistoryHint": "Save the last patch to install or export later",
"versionCompatibilityCheckLabel": "Version compatibility check",
"versionCompatibilityCheckHint": "Prevent selecting patches that are not compatible with the selected app version",
"requireSuggestedAppVersionLabel": "Require suggested app version",
Expand Down Expand Up @@ -252,18 +256,24 @@
"appInfoView": {
"widgetTitle": "App info",
"openButton": "Open",
"installButton": "Install",
"uninstallButton": "Uninstall",
"unmountButton": "Unmount",
"exportButton": "Export",
"deleteButton": "Delete",
"rootDialogTitle": "Error",
"unmountDialogText": "Are you sure you want to unmount this app?",
"uninstallDialogText": "Are you sure you want to uninstall this app?",
"rootDialogText": "App was installed with superuser permissions, but currently ReVanced Manager has no permissions.\nPlease grant superuser permissions first.",
"removeAppDialogTitle": "Delete app?",
"removeAppDialogText": "Are you sure you want to delete this app?",
"packageNameLabel": "Package name",
"installTypeLabel": "Installation type",
"mountTypeLabel": "Mount",
"regularTypeLabel": "Regular",
"patchedDateLabel": "Patched date",
"appliedPatchesLabel": "Applied patches",
"sizeLabel": "File size",
"patchedDateHint": "${date} at ${time}",
"appliedPatchesHint": "${quantity} applied patches",
"updateNotImplemented": "This feature has not been implemented yet"
Expand Down
27 changes: 11 additions & 16 deletions lib/services/manager_api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -831,9 +831,7 @@ class ManagerAPI {
context: context,
barrierDismissible: false,
builder: (context) => AlertDialog(
title: I18nText(
'installerView.installType',
),
title: Text(t.installerView.installType),
backgroundColor: Theme.of(context).colorScheme.secondaryContainer,
icon: const Icon(Icons.file_download_outlined),
contentPadding: const EdgeInsets.symmetric(vertical: 16),
Expand All @@ -850,20 +848,17 @@ class ManagerAPI {
horizontal: 20,
vertical: 10,
),
child: I18nText(
'installerView.installTypeDescription',
child: Text(
'',
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.w500,
color: Theme.of(context).colorScheme.secondary,
),
child: Text(
t.installerView.installTypeDescription,
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.w500,
color: Theme.of(context).colorScheme.secondary,
),
),
),
RadioListTile(
title: I18nText('installerView.installNonRootType'),
title: Text(t.installerView.installNonRootType),
contentPadding:
const EdgeInsets.symmetric(horizontal: 16),
value: 0,
Expand All @@ -873,7 +868,7 @@ class ManagerAPI {
},
),
RadioListTile(
title: I18nText('installerView.installRootType'),
title: Text(t.installerView.installRootType),
contentPadding:
const EdgeInsets.symmetric(horizontal: 16),
value: 1,
Expand All @@ -889,13 +884,13 @@ class ManagerAPI {
),
actions: [
OutlinedButton(
child: I18nText('cancelButton'),
child: Text(t.cancelButton),
onPressed: () {
Navigator.of(context).pop();
},
),
FilledButton(
child: I18nText('installerView.installButton'),
child: Text(t.installerView.installButton),
onPressed: () {
Navigator.of(context).pop();
},
Expand Down
17 changes: 7 additions & 10 deletions lib/ui/widgets/appInfoView/app_info_view.dart
Original file line number Diff line number Diff line change
Expand Up @@ -187,16 +187,13 @@ class AppInfoView extends StatelessWidget {
.primary,
),
const SizedBox(height: 10),
I18nText(
'appInfoView.deleteButton',
child: Text(
'',
style: TextStyle(
color: Theme.of(context)
.colorScheme
.primary,
fontWeight: FontWeight.bold,
),
Text(
t.appInfoView.deleteButton,
style: TextStyle(
color: Theme.of(context)
.colorScheme
.primary,
fontWeight: FontWeight.bold,
),
),
],
Expand Down
8 changes: 4 additions & 4 deletions lib/ui/widgets/appInfoView/app_info_viewmodel.dart
Original file line number Diff line number Diff line change
Expand Up @@ -148,16 +148,16 @@ class AppInfoViewModel extends BaseViewModel {
return showDialog(
context: context,
builder: (context) => AlertDialog(
title: I18nText('appInfoView.removeAppDialogTitle'),
title: Text(t.appInfoView.removeAppDialogTitle),
backgroundColor: Theme.of(context).colorScheme.secondaryContainer,
content: I18nText('appInfoView.removeAppDialogText'),
content: Text(t.appInfoView.removeAppDialogText),
actions: <Widget>[
OutlinedButton(
child: I18nText('cancelButton'),
child: Text(t.cancelButton),
onPressed: () => Navigator.of(context).pop(),
),
FilledButton(
child: I18nText('okButton'),
child: Text(t.okButton),
onPressed: () => {
_managerAPI.deleteLastPatchedApp(),
Navigator.of(context)..pop()..pop(),
Expand Down
24 changes: 10 additions & 14 deletions lib/ui/widgets/homeView/patch_history_card.dart
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import 'package:device_apps/device_apps.dart';
import 'package:flutter/material.dart';
import 'package:flutter_i18n/flutter_i18n.dart';
import 'package:revanced_manager/app/app.locator.dart';
import 'package:revanced_manager/gen/strings.g.dart';
import 'package:revanced_manager/models/patched_application.dart';
import 'package:revanced_manager/services/manager_api.dart';
import 'package:revanced_manager/ui/views/home/home_viewmodel.dart';
Expand All @@ -26,19 +26,15 @@ class PatchHistoryCard extends StatelessWidget {
color: Theme.of(context).colorScheme.secondary,
),
const SizedBox(height: 16),
I18nText(
'homeView.noHistory',
child: Text(
'',
textAlign: TextAlign.center,
style: Theme.of(context)
.textTheme
.titleMedium!
.copyWith(
color:
Theme.of(context).colorScheme.secondary,
),
),
Text(
t.homeView.noHistory,
style: Theme.of(context)
.textTheme
.titleMedium!
.copyWith(
color:
Theme.of(context).colorScheme.secondary,
),
),
],
),
Expand Down
17 changes: 7 additions & 10 deletions lib/ui/widgets/settingsView/settings_patch_history.dart
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import 'package:flutter/material.dart';
import 'package:flutter_i18n/widgets/I18nText.dart';
import 'package:revanced_manager/gen/strings.g.dart';
import 'package:revanced_manager/ui/views/settings/settings_viewmodel.dart';

class SPatchHistory extends StatefulWidget {
Expand All @@ -18,17 +18,14 @@ class _SPatchHistoryState
Widget build(BuildContext context) {
return SwitchListTile(
contentPadding: const EdgeInsets.symmetric(horizontal: 20.0),
title: I18nText(
'settingsView.patchHistoryLabel',
child: const Text(
'',
style: TextStyle(
fontSize: 20,
fontWeight: FontWeight.w500,
),
title: Text(
t.settingsView.patchHistoryLabel,
style: const TextStyle(
fontSize: 20,
fontWeight: FontWeight.w500,
),
),
subtitle: I18nText('settingsView.patchHistoryHint'),
subtitle: Text(t.settingsView.patchHistoryHint),
value: _settingsViewModel.isPatchHistoryEnabled(),
onChanged: (value) {
setState(() {
Expand Down

0 comments on commit aa7a8c4

Please sign in to comment.