liuzhenxing1118 2 lat temu
rodzic
commit
dd61e4daf6

+ 3 - 2
app/src/main/java/com/xplora/xpchat/manager/DatabaseUtils.java

@@ -385,7 +385,7 @@ public class DatabaseUtils {
         for (int i = 0; i < 10; i++) {
             ContactBean bean = new ContactBean();
             bean.userId = "2000";
-            bean.name = "妈妈";
+            bean.name = "gwandmagm";
             bean.unRead = 5;
             arrayList.add(bean);
         }
@@ -432,11 +432,12 @@ public class DatabaseUtils {
             bean.type = ToolsUtils.random(6) + 100;
             if (bean.type == 104)
                 bean.type = 100;
-            bean.senderUserId = DataManager.getWatchUserId();
+            bean.senderUserId = "2000"; //DataManager.getWatchUserId();
             bean.text = ("fdsafdsafdsafdsaf");
             bean.emojiId = "761c0252e1e55eca9d4b7d186c985688";
             bean.dur = ToolsUtils.random(60);
             bean.localState = Constant.MESSAGE_STATE_SEND_FAIL;
+            bean.create = ToolsUtils.getCurrentTime() - 10000;
             //bean.localState = (5);
             arrayList.add(bean);
         }

+ 1 - 1
app/src/main/res/layout/item_contacts.xml

@@ -21,7 +21,7 @@
             />
 
         <TextView
-            android:layout_width="match_parent"
+            android:layout_width="45dp"
             android:layout_height="wrap_content"
             android:text="app name"
             android:textColor="@color/white"

+ 2 - 2
app/src/main/res/layout/item_other_emoji.xml

@@ -14,15 +14,15 @@
         >
         <TextView
             android:id="@+id/mNameTv"
-            android:layout_width="wrap_content"
+            android:layout_width="47dp"
             android:layout_height="wrap_content"
             android:layout_marginStart="15dp"
             android:fontFamily="Roboto"
             android:textFontWeight="500"
             android:textSize="9dp"
             android:textColor="@color/white"
-            android:maxLength="10"
             android:ellipsize="end"
+            android:maxLines="1"
             />
 
         <TextView

+ 2 - 2
app/src/main/res/layout/item_other_photo.xml

@@ -14,15 +14,15 @@
         >
         <TextView
             android:id="@+id/mNameTv"
-            android:layout_width="wrap_content"
+            android:layout_width="47dp"
             android:layout_height="wrap_content"
             android:layout_marginStart="15dp"
             android:fontFamily="Roboto"
             android:textFontWeight="500"
             android:textSize="9dp"
             android:textColor="@color/white"
-            android:maxLength="10"
             android:ellipsize="end"
+            android:maxLines="1"
             />
 
         <TextView

+ 2 - 2
app/src/main/res/layout/item_other_text.xml

@@ -14,15 +14,15 @@
         >
         <TextView
             android:id="@+id/mNameTv"
-            android:layout_width="wrap_content"
+            android:layout_width="47dp"
             android:layout_height="wrap_content"
             android:layout_marginStart="15dp"
             android:fontFamily="Roboto"
             android:textFontWeight="500"
             android:textSize="9dp"
             android:textColor="@color/white"
-            android:maxLength="10"
             android:ellipsize="end"
+            android:maxLines="1"
             />
 
         <TextView

+ 2 - 2
app/src/main/res/layout/item_other_video.xml

@@ -14,15 +14,15 @@
         >
         <TextView
             android:id="@+id/mNameTv"
-            android:layout_width="wrap_content"
+            android:layout_width="47dp"
             android:layout_height="wrap_content"
             android:layout_marginStart="15dp"
             android:fontFamily="Roboto"
             android:textFontWeight="500"
             android:textSize="9dp"
             android:textColor="@color/white"
-            android:maxLength="10"
             android:ellipsize="end"
+            android:maxLines="1"
             />
 
         <TextView

+ 2 - 2
app/src/main/res/layout/item_other_voice.xml

@@ -15,15 +15,15 @@
         >
         <TextView
             android:id="@+id/mNameTv"
-            android:layout_width="wrap_content"
+            android:layout_width="47dp"
             android:layout_height="wrap_content"
             android:layout_marginStart="15dp"
             android:fontFamily="Roboto"
             android:textFontWeight="500"
             android:textSize="9dp"
             android:textColor="@color/white"
-            android:maxLength="10"
             android:ellipsize="end"
+            android:maxLines="1"
             />
 
         <TextView