diff --git a/app/src/main/java/fr/gouv/etalab/mastodon/activities/TootActivity.java b/app/src/main/java/fr/gouv/etalab/mastodon/activities/TootActivity.java
index ce50419a6..ad924f46a 100644
--- a/app/src/main/java/fr/gouv/etalab/mastodon/activities/TootActivity.java
+++ b/app/src/main/java/fr/gouv/etalab/mastodon/activities/TootActivity.java
@@ -1843,7 +1843,11 @@ public class TootActivity extends BaseActivity implements OnRetrieveSearcAccount
}
if( tootReply.getMentions() != null ){
//Put other accounts mentioned at the bottom
- toot_content.setText(String.format("%s", (toot_content.getText().toString() + "\n\n")));
+ boolean capitalize = sharedpreferences.getBoolean(Helper.SET_CAPITALIZE, true);
+ if( capitalize)
+ toot_content.setText(String.format("%s", (toot_content.getText().toString() + "\n\n")));
+ else
+ toot_content.setText(String.format("%s", (toot_content.getText().toString() + " \n")));
for(Mention mention : tootReply.getMentions()){
if( mention.getAcct() != null && !mention.getId().equals(userIdReply) && !mentionedAccountsAdded.contains(mention.getAcct())) {
mentionedAccountsAdded.add(mention.getAcct());
diff --git a/app/src/main/java/fr/gouv/etalab/mastodon/fragments/SettingsFragment.java b/app/src/main/java/fr/gouv/etalab/mastodon/fragments/SettingsFragment.java
index e565346f5..11681642c 100644
--- a/app/src/main/java/fr/gouv/etalab/mastodon/fragments/SettingsFragment.java
+++ b/app/src/main/java/fr/gouv/etalab/mastodon/fragments/SettingsFragment.java
@@ -285,6 +285,21 @@ public class SettingsFragment extends Fragment {
}
});
+
+ boolean capitalize = sharedpreferences.getBoolean(Helper.SET_CAPITALIZE, true);
+ final CheckBox set_capitalize = rootView.findViewById(R.id.set_capitalize);
+ set_capitalize.setChecked(capitalize);
+
+ set_capitalize.setOnClickListener(new View.OnClickListener() {
+ @Override
+ public void onClick(View v) {
+ SharedPreferences.Editor editor = sharedpreferences.edit();
+ editor.putBoolean(Helper.SET_CAPITALIZE, set_capitalize.isChecked());
+ editor.apply();
+ }
+ });
+
+
final CheckBox set_embedded_browser = rootView.findViewById(R.id.set_embedded_browser);
final LinearLayout set_javascript_container = rootView.findViewById(R.id.set_javascript_container);
final SwitchCompat set_javascript = rootView.findViewById(R.id.set_javascript);
diff --git a/app/src/main/java/fr/gouv/etalab/mastodon/helper/Helper.java b/app/src/main/java/fr/gouv/etalab/mastodon/helper/Helper.java
index b95549a30..b7d6ba8c6 100644
--- a/app/src/main/java/fr/gouv/etalab/mastodon/helper/Helper.java
+++ b/app/src/main/java/fr/gouv/etalab/mastodon/helper/Helper.java
@@ -223,6 +223,7 @@ public class Helper {
public static final String INSTANCE_VERSION = "instance_version";
public static final String SET_LIVE_NOTIFICATIONS = "set_live_notifications";
public static final String SET_DISABLE_GIF = "set_disable_gif";
+ public static final String SET_CAPITALIZE = "set_capitalize";
public static final int ATTACHMENT_ALWAYS = 1;
public static final int ATTACHMENT_WIFI = 2;
public static final int ATTACHMENT_ASK = 3;
diff --git a/app/src/main/res/layout-sw600dp/fragment_settings.xml b/app/src/main/res/layout-sw600dp/fragment_settings.xml
index c7e8a8960..75b4e7868 100644
--- a/app/src/main/res/layout-sw600dp/fragment_settings.xml
+++ b/app/src/main/res/layout-sw600dp/fragment_settings.xml
@@ -112,6 +112,13 @@
android:text="@string/set_display_global"
android:layout_height="wrap_content" />
+
+
+
+
+
Follows you
Search
-
+ First letter in capital for replies
Push notifications