1
0
mirror of https://github.com/TeamNewPipe/NewPipe synced 2024-12-23 00:20:32 +00:00

Added strings to strings.xml to allow translation.

This commit is contained in:
Vincent Tanumihardja 2022-10-29 11:33:10 +11:00 committed by TobiGr
parent 40a3e1b18a
commit d7ef9b1f0c
2 changed files with 5 additions and 5 deletions

View File

@ -99,11 +99,9 @@ public class DebugSettingsFragment extends BasePreferenceFragment {
resetSettings.setOnPreferenceClickListener(preference -> { resetSettings.setOnPreferenceClickListener(preference -> {
// Show Alert Dialogue // Show Alert Dialogue
final AlertDialog.Builder builder = new AlertDialog.Builder(getContext()); final AlertDialog.Builder builder = new AlertDialog.Builder(getContext());
builder.setMessage("Resetting all settings will discard " builder.setMessage(R.string.reset_all_settings);
+ "all of your preferred settings and restarts the app. "
+ "Are you sure you want to proceed?");
builder.setCancelable(true); builder.setCancelable(true);
builder.setPositiveButton("Yes", (dialogInterface, i) -> { builder.setPositiveButton(R.string.ok, (dialogInterface, i) -> {
// Deletes all shared preferences xml files. // Deletes all shared preferences xml files.
final SharedPreferences sharedPreferences = final SharedPreferences sharedPreferences =
PreferenceManager.getDefaultSharedPreferences(requireContext()); PreferenceManager.getDefaultSharedPreferences(requireContext());
@ -114,7 +112,7 @@ public class DebugSettingsFragment extends BasePreferenceFragment {
} }
NavigationHelper.restartApp(getActivity()); NavigationHelper.restartApp(getActivity());
}); });
builder.setNegativeButton("Cancel", (dialogInterface, i) -> { builder.setNegativeButton(R.string.cancel, (dialogInterface, i) -> {
}); });
final AlertDialog alertDialog = builder.create(); final AlertDialog alertDialog = builder.create();
alertDialog.show(); alertDialog.show();

View File

@ -595,6 +595,8 @@
<item quantity="one">Download finished</item> <item quantity="one">Download finished</item>
<item quantity="other">%s downloads finished</item> <item quantity="other">%s downloads finished</item>
</plurals> </plurals>
<!-- dialog about resetting settings -->
<string name="reset_all_settings">Resetting all settings will discard all of your preferred settings and restarts the app. Are you sure you want to proceed?</string>
<!-- dialog about existing downloads --> <!-- dialog about existing downloads -->
<string name="generate_unique_name">Generate unique name</string> <string name="generate_unique_name">Generate unique name</string>
<string name="overwrite">Overwrite</string> <string name="overwrite">Overwrite</string>