主播开播优化

This commit is contained in:
Martin
2024-08-22 10:45:11 +08:00
parent 67b79cd306
commit 0d1e2c4e6b
41 changed files with 1210 additions and 973 deletions

View File

@@ -33,11 +33,16 @@ public class LiveClarityCustomPopup extends BottomPopupView implements View.OnCl
private TextView titleSDText, titleHDText, titleFHDText, mTips;
private int banSelect;
private boolean isUser = false;
private SelectPositionListener selectPositionListener;
public int getSelectClarity() {
return selectClarity;
}
public void setSelectPositionListener(SelectPositionListener selectPositionListener) {
this.selectPositionListener = selectPositionListener;
}
/**
* @param banSelect 禁止选项,{@link #BAN_720} 禁止高清和超高清。 {@link #BAN_1080} 禁止超高清
* @param isUser 是否为观众true 观众false 主播
@@ -227,6 +232,13 @@ public class LiveClarityCustomPopup extends BottomPopupView implements View.OnCl
iconFhd.setVisibility(VISIBLE);
break;
}
if(selectPositionListener!=null){
selectPositionListener.onSelect(selectClarity);
}
}
public interface SelectPositionListener{
void onSelect(int position);
}
private Handler netHandler = new Handler();

View File

@@ -0,0 +1,23 @@
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android">
<!--设置ProgressBar背景色-->
<item android:id="@android:id/background">
<shape>
<!--设置ProgressBar进度条圆角半径-->
<corners android:radius="1dp" />
<solid android:color="#A5A193" />
</shape>
</item>
<!--设置ProgressBar进度条颜色-->
<item android:id="@android:id/progress">
<scale android:scaleWidth="100%">
<shape>
<corners android:radius="1dp" />
<gradient
android:endColor="#FFC949"
android:startColor="#FFC949" />
</shape>
</scale>
</item>
</layer-list>

View File

@@ -8,8 +8,8 @@
<LinearLayout
android:id="@+id/interactionLayout"
android:layout_width="match_parent"
android:orientation="vertical"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
@@ -41,9 +41,10 @@
android:src="@mipmap/icon_interaction_zg" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/live_zg"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -63,9 +64,10 @@
android:src="@mipmap/icon_interaction_wish" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/live_wishlist"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -74,8 +76,8 @@
<LinearLayout
android:id="@+id/live_tool_mic"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical"
android:visibility="visible">
@@ -86,9 +88,10 @@
android:src="@mipmap/icon_interaction_mic" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/live_mic"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -97,8 +100,8 @@
<LinearLayout
android:id="@+id/live_tool_game"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
@@ -108,9 +111,10 @@
android:src="@mipmap/icon_interaction_game" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/interactive_game"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -126,8 +130,8 @@
<LinearLayout
android:id="@+id/live_tool_anchor_say"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
@@ -137,9 +141,10 @@
android:src="@mipmap/icon_interaction_anchor_say" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/live_fun_anchor_say"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -148,8 +153,8 @@
<LinearLayout
android:id="@+id/live_tool_qa"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
@@ -159,17 +164,19 @@
android:src="@mipmap/icon_interaction_qa" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/dialog_live_function_qa"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
</LinearLayout>
<View
android:layout_width="0dp"
android:layout_weight="2"
android:layout_height="match_parent"/>
android:layout_height="match_parent"
android:layout_weight="2" />
</LinearLayout>
</LinearLayout>
@@ -177,8 +184,8 @@
<LinearLayout
android:id="@+id/equityLayout"
android:layout_width="match_parent"
android:orientation="vertical"
android:layout_height="wrap_content">
android:layout_height="wrap_content"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
@@ -209,9 +216,10 @@
android:src="@mipmap/icon_interaction_live_data" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/broadcast_data"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -231,9 +239,10 @@
android:src="@mipmap/icon_interaction_robot" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/robot_setup"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -241,9 +250,10 @@
<View
android:layout_width="0dp"
android:layout_weight="2"
android:layout_height="match_parent"/>
android:layout_height="match_parent"
android:layout_weight="2" />
</LinearLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
@@ -252,18 +262,19 @@
android:text="@string/live_interaction_tools"
android:textColor="@color/white"
android:textSize="14sp" />
<LinearLayout
android:layout_marginTop="14dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="14dp"
android:layout_marginBottom="20dp"
android:paddingEnd="16dp">
<LinearLayout
android:id="@+id/live_tool_beauty"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
@@ -273,9 +284,10 @@
android:src="@mipmap/icon_interaction_beauty" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/live_beauty"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -284,8 +296,8 @@
<LinearLayout
android:id="@+id/live_tool_camera"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
@@ -295,9 +307,10 @@
android:src="@mipmap/icon_interaction_camera" />
<TextView
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/live_camera"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
@@ -306,8 +319,8 @@
<LinearLayout
android:id="@+id/live_tool_leave"
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="wrap_content"
android:layout_weight="1"
android:gravity="center"
android:orientation="vertical">
@@ -319,17 +332,19 @@
<TextView
android:id="@+id/live_tool_leave_text"
android:layout_width="wrap_content"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center"
android:text="@string/live_zslk"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
</LinearLayout>
<View
android:layout_width="0dp"
android:layout_weight="1"
android:layout_height="match_parent"/>
android:layout_height="match_parent"
android:layout_weight="1" />
</LinearLayout>
</LinearLayout>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.4 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

View File

@@ -290,7 +290,7 @@
<string name="live_camera">Flip</string>
<string name="live_camera_s">Mirroring</string>
<string name="live_zg">Trickster</string>
<string name="live_dr">MultiplayerPK</string>
<string name="live_dr">Multi PK</string>
<string name="live_mic">Voice connection</string>
<string name="live_wks">billboard</string>
<string name="live_zslk">leave temporarily</string>
@@ -1105,7 +1105,7 @@ Limited ride And limited avatar frame</string>
<string name="lunar_wish">Month Wishes</string>
<string name="seasonal_wish">Seasonal Wishes</string>
<string name="wish_number">Wish%s</string>
<string name="aristocrat">aristocrat</string>
<string name="aristocrat">noble</string>
<string name="aristocrat_determine">sure</string>
<string name="replacement_wish_day">Reset Your: Day</string>
<string name="replacement_wish_zhou">Reset Wish: Week</string>
@@ -1488,5 +1488,5 @@ Limited ride And limited avatar frame</string>
<string name="live_data_tip">* Non-real-time calculation of data</string>
<string name="live_data_msg2">Historical data can be viewed in the anchor center</string>
<string name="live_data_msg1">This live data statistics</string>
<string name="live_data_msg1">This live information</string>
</resources>

View File

@@ -1617,6 +1617,6 @@
<string name="live_data_history_gain">收益</string>
<string name="live_data_tip">* 人數及新增相關數據非实时计算</string>
<string name="live_data_msg2">歷史數據可在主播中心查看</string>
<string name="live_data_msg1">本場直播數據統計</string>
<string name="live_data_msg1">本場直播信息</string>
</resources>

View File

@@ -233,7 +233,7 @@
<string name="must_hint">A maximum of 10 entries can be set</string>
<string name="live_camera">Flip</string>
<string name="live_zg">Trickster</string>
<string name="live_dr">MultiplayerPK</string>
<string name="live_dr">Multi PK</string>
<string name="live_mic">Voice connection</string>
<string name="live_wks">billboard</string>
<string name="live_zslk">leave temporarily</string>
@@ -929,7 +929,7 @@ Limited ride And limited avatar frame</string>
<string name="lunar_wish">Month Wishes</string>
<string name="seasonal_wish">Seasonal Wishes</string>
<string name="wish_number">Wish%s</string>
<string name="aristocrat">aristocrat</string>
<string name="aristocrat">noble</string>
<string name="aristocrat_determine">sure</string>
<string name="replacement_wish_day">Reset Your: Day</string>
<string name="replacement_wish_zhou">Reset Wish: Week</string>
@@ -1426,5 +1426,5 @@ Limited ride And limited avatar frame</string>
<string name="live_data_tip">* Non-real-time calculation of data</string>
<string name="live_data_msg2">Historical data can be viewed in the anchor center</string>
<string name="live_data_msg1">This live data statistics</string>
<string name="live_data_msg1">This live information</string>
</resources>