diff --git a/app/src/main/java/eu/faircode/email/FragmentCompose.java b/app/src/main/java/eu/faircode/email/FragmentCompose.java index d4c22d3311..2651b0e730 100644 --- a/app/src/main/java/eu/faircode/email/FragmentCompose.java +++ b/app/src/main/java/eu/faircode/email/FragmentCompose.java @@ -6845,7 +6845,12 @@ public class FragmentCompose extends FragmentBase { if (spannedRef.length() > 0 && spannedRef.charAt(0) == '\n') spannedRef = (Spanned) spannedRef.subSequence(1, spannedRef.length()); - Locale ref_lang = TextHelper.detectLanguage(context, spannedRef.toString()); + SharedPreferences prefs = PreferenceManager.getDefaultSharedPreferences(context); + boolean language_detection = prefs.getBoolean("language_detection", false); + + Locale ref_lang = (language_detection + ? TextHelper.detectLanguage(context, spannedRef.toString()) + : null); args.putSerializable("ref_lang", ref_lang); } diff --git a/app/src/main/res/layout/fragment_options_behavior.xml b/app/src/main/res/layout/fragment_options_behavior.xml index 6f8f9334d6..7c37f53899 100644 --- a/app/src/main/res/layout/fragment_options_behavior.xml +++ b/app/src/main/res/layout/fragment_options_behavior.xml @@ -157,17 +157,6 @@ app:layout_constraintTop_toBottomOf="@id/swConversationActionsReplies" app:switchPadding="12dp" /> - - + app:layout_constraintTop_toBottomOf="@id/swLanguageDetection" /> This will more accurately display messages, but possibly with a delay Restore last app state when restarted via the launcher icon within %1$d minutes - Language detection support depends on the device manufacturer Automatically open message when there is just one message or just one unread message in a conversation The answer button will not be shown when multiple messages are expanded because it is unclear which message the button applies to Automatically marking messages as read on expanding can be disabled in the advanced account settings of each account