diff --git a/common/src/main/java/com/yunbao/common/views/weight/AtTextWatcher.java b/common/src/main/java/com/yunbao/common/views/weight/AtTextWatcher.java index e0a8807ba..b09afcd98 100644 --- a/common/src/main/java/com/yunbao/common/views/weight/AtTextWatcher.java +++ b/common/src/main/java/com/yunbao/common/views/weight/AtTextWatcher.java @@ -37,10 +37,10 @@ public class AtTextWatcher implements TextWatcher { int endIndex = startIndex + nameStr.length();//字符结束的位置 spanMap.put(model.getId(), model); //插入要添加的字符,此处是为了给span占位 - input.getText().insert(startIndex, "@" + nameStr + " "); + input.getText().insert(startIndex, "@" + nameStr); //1、使用mEditText构造一个SpannableString StringBuffer atName = new StringBuffer(); - atName.append("@").append(nameStr).append(" "); + atName.append("@").append(nameStr); if (spannableStringBuilder.length() > 0) { spannableStringBuilder.insert(startIndex, atName.toString()); } else {