Fix carriage return replace in chat

This commit is contained in:
Erwan Croze 2017-04-20 17:15:46 +02:00
parent 168ae3f4d7
commit 12d7c1e652

View file

@ -1424,6 +1424,9 @@ public class ChatFragment extends Fragment implements OnClickListener, LinphoneC
if (text.contains(">")) {
text = text.replace(">", ">");
}
if (text.contains("\n")) {
text = text.replace("\n", "<br>");
}
if (text.contains("http://")) {
int indexHttp = text.indexOf("http://");
int indexFinHttp = text.indexOf(" ", indexHttp) == -1 ? text.length() : text.indexOf(" ", indexHttp);