From 849f5aa66d74969a25835cc7a33727ccb6a0d033 Mon Sep 17 00:00:00 2001 From: Martin <13046765170@163.com> Date: Thu, 29 Aug 2024 16:28:02 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=BE=A9bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/yunbao/common/utils/StringUtil.java | 10 ++++------ common/src/main/res/layout/live_data_history_item.xml | 2 +- live/src/main/res/layout/view_live_room.xml | 2 +- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/common/src/main/java/com/yunbao/common/utils/StringUtil.java b/common/src/main/java/com/yunbao/common/utils/StringUtil.java index 389490fa4..0883d8b30 100644 --- a/common/src/main/java/com/yunbao/common/utils/StringUtil.java +++ b/common/src/main/java/com/yunbao/common/utils/StringUtil.java @@ -95,13 +95,11 @@ public class StringUtil { int minutes = (int) ((mms % (1000 * 60 * 60)) / (1000 * 60)); int seconds = (int) ((mms % (1000 * 60)) / 1000); sStringBuilder.delete(0, sStringBuilder.length()); - if (hours > 0) { - if (hours < 10) { - sStringBuilder.append("0"); - } - sStringBuilder.append(String.valueOf(hours)); - sStringBuilder.append(":"); + if (hours < 10) { + sStringBuilder.append("0"); } + sStringBuilder.append(String.valueOf(hours)); + sStringBuilder.append(":"); if (minutes > 0) { if (minutes < 10) { sStringBuilder.append("0"); diff --git a/common/src/main/res/layout/live_data_history_item.xml b/common/src/main/res/layout/live_data_history_item.xml index 938d9fea7..3e3b83c60 100644 --- a/common/src/main/res/layout/live_data_history_item.xml +++ b/common/src/main/res/layout/live_data_history_item.xml @@ -19,7 +19,7 @@ android:layout_height="wrap_content" android:paddingStart="20dp" android:layout_gravity="center_vertical" - android:layout_weight="1" + android:layout_weight="1.2" android:ellipsize="end" android:gravity="center_vertical" android:textColor="#92949A" diff --git a/live/src/main/res/layout/view_live_room.xml b/live/src/main/res/layout/view_live_room.xml index b85e77e62..0f22f805d 100644 --- a/live/src/main/res/layout/view_live_room.xml +++ b/live/src/main/res/layout/view_live_room.xml @@ -330,7 +330,7 @@ android:layout_marginStart="4dp" android:layout_marginEnd="7dp" android:background="@drawable/bg_live_item" - android:visibility="visible"> + android:visibility="gone">