This commit is contained in:
B. Petersen
2020-03-12 13:49:05 +01:00
parent 9fbad277a6
commit bf314f57bf
4 changed files with 28 additions and 12 deletions
+18 -2
View File
@@ -143,7 +143,23 @@
<item>@string/mute_forever</item>
</string-array>
<string-array name="autodel_durations">
<string-array name="autodel_device_durations">
<item>@string/off</item>
<item>@string/autodel_after_1_hour</item>
<item>@string/autodel_after_1_day</item>
<item>@string/autodel_after_1_week</item>
<item>@string/autodel_after_4_weeks</item>
</string-array>
<string-array name="autodel_device_values">
<item>0</item>
<item>3600</item>
<item>86400</item>
<item>604800</item>
<item>2419200</item>
</string-array>
<string-array name="autodel_server_durations">
<item>@string/off</item>
<item>@string/autodel_at_once</item>
<item>@string/autodel_after_1_hour</item>
@@ -152,7 +168,7 @@
<item>@string/autodel_after_4_weeks</item>
</string-array>
<string-array name="autodel_values">
<string-array name="autodel_server_values">
<item>0</item>
<item>1</item>
<item>3600</item>
+5 -5
View File
@@ -467,12 +467,12 @@
<string name="pref_background_custom_color">Custom color</string>
<!-- automatically delete message -->
<string name="autodel_title">Ephemeral messages</string>
<string name="autodel_device_title">Delete from device</string>
<string name="autodel_server_title">Delete from server</string>
<string name="autodel_title">Automatically delete messages</string>
<string name="autodel_device_title">Delete messages from device</string>
<string name="autodel_server_title">Delete messages from server</string>
<!-- %1$d will be replaced by the number of messages, you can assume plural/lots here. %1$s will be replaced by a timespan in italics or so. -->
<string name="autodel_device_ask">Do you really want to delete %1$d messages now and all new messages %2$s in the future?\n\n• Message will be deleted whether they were seen or not\n\n• \"Saved messages\" will be skipped from local deletion</string>
<string name="autodel_server_ask">Do you really want to delete %1$d messages now and all new messages %2$s in the future?\n\n• This will also delete emails affected by the \"Show classic emails\" option\n\n• \"Saved messages\" will be deleted from the server as well</string>
<string name="autodel_device_ask">Do you want to delete %1$d messages now and all newly fetched messages %2$s in the future?\n\n• This includes all media\n\n• Message will be deleted whether they were seen or not\n\n• \"Saved messages\" will be skipped from local deletion</string>
<string name="autodel_server_ask">Do you want to delete %1$d messages now and all newly fetched messages %2$s in the future?\n\n• This includes all media\n\n• This will also delete emails affected by the \"Show classic emails\" option\n\n• \"Saved messages\" will be deleted from the server as well</string>
<string name="autodel_confirm">I understand, delete all these messages</string>
<string name="autodel_at_once">At once</string>
<string name="autodel_after_1_hour">After 1 hour</string>
+4 -4
View File
@@ -38,14 +38,14 @@
<ListPreference
android:key="autodel_device"
android:title="@string/autodel_device_title"
android:entries="@array/autodel_durations"
android:entryValues="@array/autodel_values"/>
android:entries="@array/autodel_device_durations"
android:entryValues="@array/autodel_device_values"/>
<ListPreference
android:key="autodel_server"
android:title="@string/autodel_server_title"
android:entries="@array/autodel_durations"
android:entryValues="@array/autodel_values" />
android:entries="@array/autodel_server_durations"
android:entryValues="@array/autodel_server_values" />
</PreferenceCategory>
<PreferenceCategory android:title="@string/pref_backup">
@@ -160,7 +160,7 @@ public class ChatsPreferenceFragment extends ListSummaryPreferenceFragment {
View gl = View.inflate(getActivity(), R.layout.autodel_confirm, null);
CheckBox confirmCheckbox = gl.findViewById(R.id.i_understand);
String msg = context.getString(fromServer?
R.string.pref_autodel_server_ask : R.string.pref_autodel_device_ask,
R.string.autodel_server_ask : R.string.autodel_device_ask,
delCount, "<i>"+getSelectedSummary(preference, newValue)+"</i>");
new AlertDialog.Builder(context)