Enable the sending of long messages.

This commit is contained in:
Greyson Parrelli 2019-03-22 12:28:41 -07:00
parent cfdcd61e51
commit ccfcfa71df
2 changed files with 2 additions and 6 deletions

View File

@ -173,9 +173,7 @@
<item name="android:padding">2dp</item> <item name="android:padding">2dp</item>
<item name="android:background">@null</item> <item name="android:background">@null</item>
<item name="android:maxLines">4</item> <item name="android:maxLines">4</item>
<!-- TODO: Switch to 64kb to enable long message sending. --> <item name="android:maxLength">65536</item>
<!--<item name="android:maxLength">65536</item>-->
<item name="android:maxLength">2000</item>
<item name="android:textColor">?conversation_item_sent_text_primary_color</item> <item name="android:textColor">?conversation_item_sent_text_primary_color</item>
<item name="android:capitalize">sentences</item> <item name="android:capitalize">sentences</item>
<item name="android:autoText">true</item> <item name="android:autoText">true</item>

View File

@ -17,9 +17,7 @@
package org.thoughtcrime.securesms.util; package org.thoughtcrime.securesms.util;
public class PushCharacterCalculator extends CharacterCalculator { public class PushCharacterCalculator extends CharacterCalculator {
// TODO: Switch to 64kb to enable long message sending. private static final int MAX_TOTAL_SIZE = 64 * 1024;
// private static final int MAX_TOTAL_SIZE = 64 * 1024;
private static final int MAX_TOTAL_SIZE = 2000;
private static final int MAX_PRIMARY_SIZE = 2000; private static final int MAX_PRIMARY_SIZE = 2000;
@Override @Override
public CharacterState calculateCharacters(String messageBody) { public CharacterState calculateCharacters(String messageBody) {