增加整蛊的消息类型
This commit is contained in:
parent
76e9748eeb
commit
84bbb0c143
@ -931,6 +931,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
|
|
||||||
private TextView sud_text_name;
|
private TextView sud_text_name;
|
||||||
private View sud_layout_name;
|
private View sud_layout_name;
|
||||||
|
private View tricky_layout_name;
|
||||||
private TextView sud_join;
|
private TextView sud_join;
|
||||||
private ImageView iconSudClose;
|
private ImageView iconSudClose;
|
||||||
private Handler sudNameHandler = new Handler();
|
private Handler sudNameHandler = new Handler();
|
||||||
@ -943,6 +944,24 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
private Runnable trickyRunnable = new Runnable() {
|
||||||
|
@Override
|
||||||
|
public void run() {
|
||||||
|
if (tricky_layout_name != null) {
|
||||||
|
tricky_layout_name.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
private void setTrickyMsg(){
|
||||||
|
if (tricky_layout_name != null) {
|
||||||
|
tricky_layout_name.setVisibility(View.VISIBLE);
|
||||||
|
}
|
||||||
|
sudNameHandler.removeCallbacks(trickyRunnable);
|
||||||
|
sudNameHandler.postDelayed(trickyRunnable, 10000);
|
||||||
|
}
|
||||||
|
|
||||||
public void setSudName(String sudName, SudGameDateModel sudGameDateModel) {
|
public void setSudName(String sudName, SudGameDateModel sudGameDateModel) {
|
||||||
sud_text_name = (TextView) findViewById(R.id.sud_text_name);
|
sud_text_name = (TextView) findViewById(R.id.sud_text_name);
|
||||||
sud_layout_name = findViewById(R.id.sud_layout_name);
|
sud_layout_name = findViewById(R.id.sud_layout_name);
|
||||||
@ -2303,6 +2322,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
prank_group_turntable = (TextView) findViewById(R.id.prank_group_turntable);//文字转盘整蛊(用户端已删除,主播端为待完成整蛊按钮)
|
prank_group_turntable = (TextView) findViewById(R.id.prank_group_turntable);//文字转盘整蛊(用户端已删除,主播端为待完成整蛊按钮)
|
||||||
prank_group_bottom_icon = (ImageView) findViewById(R.id.prank_group_bottom_icon);//收起icon
|
prank_group_bottom_icon = (ImageView) findViewById(R.id.prank_group_bottom_icon);//收起icon
|
||||||
prank_group_turntable_icon = (ImageView) findViewById(R.id.prank_group_turntable_icon);//转盘图标
|
prank_group_turntable_icon = (ImageView) findViewById(R.id.prank_group_turntable_icon);//转盘图标
|
||||||
|
tricky_layout_name = findViewById(R.id.tricky_layout_name);
|
||||||
prank_small_icon = (GifImageView) findViewById(R.id.prank_small_icon);//收起后图标
|
prank_small_icon = (GifImageView) findViewById(R.id.prank_small_icon);//收起后图标
|
||||||
zhengguTv = findViewById(R.id.zhengguTv);
|
zhengguTv = findViewById(R.id.zhengguTv);
|
||||||
try {
|
try {
|
||||||
@ -2373,6 +2393,9 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
prank_group_turntable_icon.setOnClickListener(v -> {
|
prank_group_turntable_icon.setOnClickListener(v -> {
|
||||||
Bus.get().post(new LiveAudienceEvent().setType(LiveAudienceEvent.LiveAudienceType.WE_CHEAT));
|
Bus.get().post(new LiveAudienceEvent().setType(LiveAudienceEvent.LiveAudienceType.WE_CHEAT));
|
||||||
});
|
});
|
||||||
|
tricky_layout_name.setOnClickListener(v -> {
|
||||||
|
Bus.get().post(new LiveAudienceEvent().setType(LiveAudienceEvent.LiveAudienceType.WE_CHEAT));
|
||||||
|
});
|
||||||
|
|
||||||
recycler_prank.setLayoutManager(new LinearLayoutManager(mContext));
|
recycler_prank.setLayoutManager(new LinearLayoutManager(mContext));
|
||||||
|
|
||||||
@ -2469,6 +2492,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
// prank_small_icon.setVisibility(View.GONE);
|
// prank_small_icon.setVisibility(View.GONE);
|
||||||
zhengguTv.setVisibility(View.GONE);
|
zhengguTv.setVisibility(View.GONE);
|
||||||
prank_group_turntable_icon.setVisibility(View.GONE);
|
prank_group_turntable_icon.setVisibility(View.GONE);
|
||||||
|
tricky_layout_name.setVisibility(View.GONE);
|
||||||
ToastUtil.show(WordUtil.isNewZh() ? "抱歉!出錯了!" : "i \\'m sorry! An error occurred");
|
ToastUtil.show(WordUtil.isNewZh() ? "抱歉!出錯了!" : "i \\'m sorry! An error occurred");
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -2495,8 +2519,10 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
}
|
}
|
||||||
if (Integer.parseInt(ctString.getString("prank_turntable_status")) == 0) {
|
if (Integer.parseInt(ctString.getString("prank_turntable_status")) == 0) {
|
||||||
prank_group_turntable_icon.setVisibility(View.GONE);
|
prank_group_turntable_icon.setVisibility(View.GONE);
|
||||||
|
tricky_layout_name.setVisibility(View.GONE);
|
||||||
} else {
|
} else {
|
||||||
prank_group_turntable_icon.setVisibility(View.VISIBLE);
|
prank_group_turntable_icon.setVisibility(View.VISIBLE);
|
||||||
|
setTrickyMsg();
|
||||||
//ZeusKt.visible(prank_group_turntable_icon);
|
//ZeusKt.visible(prank_group_turntable_icon);
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -2560,9 +2586,11 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
if (prankTurntableStatus == 1 && lt_trickery.getVisibility() == View.GONE) {
|
if (prankTurntableStatus == 1 && lt_trickery.getVisibility() == View.GONE) {
|
||||||
if (!CommonAppConfig.getInstance().getUid().equals(mLiveUid)) {
|
if (!CommonAppConfig.getInstance().getUid().equals(mLiveUid)) {
|
||||||
prank_group_turntable_icon.setVisibility(View.VISIBLE);
|
prank_group_turntable_icon.setVisibility(View.VISIBLE);
|
||||||
|
setTrickyMsg();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
prank_group_turntable_icon.setVisibility(View.GONE);
|
prank_group_turntable_icon.setVisibility(View.GONE);
|
||||||
|
tricky_layout_name.setVisibility(View.GONE);
|
||||||
}
|
}
|
||||||
// LogUtils.e("yqw=====>显示整蛊列表或者投票列表:"+status);
|
// LogUtils.e("yqw=====>显示整蛊列表或者投票列表:"+status);
|
||||||
if (status == 1) {
|
if (status == 1) {
|
||||||
@ -5909,6 +5937,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
name = jsonObject.getString("user_nicename");
|
name = jsonObject.getString("user_nicename");
|
||||||
lt_trickery.setVisibility(View.VISIBLE);
|
lt_trickery.setVisibility(View.VISIBLE);
|
||||||
prank_group_turntable_icon.setVisibility(View.GONE);
|
prank_group_turntable_icon.setVisibility(View.GONE);
|
||||||
|
tricky_layout_name.setVisibility(View.GONE);
|
||||||
lt_trickery.setBackground(mContext.getResources().getDrawable(R.mipmap.img_buoy));
|
lt_trickery.setBackground(mContext.getResources().getDrawable(R.mipmap.img_buoy));
|
||||||
isClose = false;
|
isClose = false;
|
||||||
starTimeloud(1, time);
|
starTimeloud(1, time);
|
||||||
@ -6995,8 +7024,13 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
contentTv.setText(data.getLivePreview().getContent());
|
contentTv.setText(data.getLivePreview().getContent());
|
||||||
// ImgLoader.display(mContext, preview.getStyleImage(), mAnchorSayImage);
|
// ImgLoader.display(mContext, preview.getStyleImage(), mAnchorSayImage);
|
||||||
if (preview.getIsShow() == 1) {
|
if (preview.getIsShow() == 1) {
|
||||||
mAnchorSay.setVisibility(View.VISIBLE);
|
if(isHinde){
|
||||||
newGodSayGroup.setVisibility(View.GONE);
|
mAnchorSay.setVisibility(View.GONE);
|
||||||
|
newGodSayGroup.setVisibility(View.GONE);
|
||||||
|
}else {
|
||||||
|
mAnchorSay.setVisibility(View.VISIBLE);
|
||||||
|
newGodSayGroup.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
mAnchorSay.setVisibility(View.INVISIBLE);
|
mAnchorSay.setVisibility(View.INVISIBLE);
|
||||||
newGodSayGroup.setVisibility(View.GONE);
|
newGodSayGroup.setVisibility(View.GONE);
|
||||||
|
@ -0,0 +1,9 @@
|
|||||||
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
|
<selector xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<item android:width="38dp" android:height="18dp">
|
||||||
|
<shape android:shape="rectangle">
|
||||||
|
<gradient android:type="linear" android:useLevel="true" android:startColor="#ffff4d53" android:endColor="#ffff797d" android:angle="180" />
|
||||||
|
<corners android:topLeftRadius="10dp" android:topRightRadius="10dp" android:bottomLeftRadius="10dp" android:bottomRightRadius="10dp" />
|
||||||
|
</shape>
|
||||||
|
</item>
|
||||||
|
</selector>
|
@ -3119,6 +3119,64 @@
|
|||||||
android:src="@mipmap/icon_live_notify_close1" />
|
android:src="@mipmap/icon_live_notify_close1" />
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
|
<!--整蛊消息-->
|
||||||
|
<RelativeLayout
|
||||||
|
android:id="@+id/tricky_layout_name"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="40dp"
|
||||||
|
android:layout_alignParentBottom="true"
|
||||||
|
android:layout_marginStart="13dp"
|
||||||
|
android:layout_marginTop="5dp"
|
||||||
|
android:background="@drawable/background_live_sud_hint"
|
||||||
|
android:visibility="gone"
|
||||||
|
tools:visibility="visible">
|
||||||
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/tricky_coin"
|
||||||
|
android:layout_width="22dp"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginStart="8dp"
|
||||||
|
android:layout_marginTop="2dp"
|
||||||
|
android:src="@mipmap/ic_live_rom_tricky" />
|
||||||
|
|
||||||
|
<com.yunbao.common.views.weight.MarqueeTextView
|
||||||
|
android:id="@+id/tricky_text_name"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginStart="5dp"
|
||||||
|
android:layout_toEndOf="@+id/tricky_coin"
|
||||||
|
android:ellipsize="marquee"
|
||||||
|
android:scrollHorizontally="true"
|
||||||
|
android:singleLine="true"
|
||||||
|
tools:text="主播發起了整蠱娛樂,點擊查看"
|
||||||
|
android:textColor="@color/black1"
|
||||||
|
android:textSize="12dp" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/tricky_join"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="18dp"
|
||||||
|
android:layout_toEndOf="@+id/tricky_text_name"
|
||||||
|
android:layout_centerVertical="true"
|
||||||
|
android:layout_marginLeft="10dp"
|
||||||
|
android:layout_marginEnd="14dp"
|
||||||
|
android:background="@drawable/bg_live_room_tricky_hint_join"
|
||||||
|
android:ellipsize="end"
|
||||||
|
android:fontFamily="sans-serif-condensed-medium"
|
||||||
|
android:gravity="center"
|
||||||
|
android:maxWidth="50dp"
|
||||||
|
android:paddingStart="10dp"
|
||||||
|
android:paddingEnd="10dp"
|
||||||
|
android:singleLine="true"
|
||||||
|
android:text="查看"
|
||||||
|
android:textColor="@color/white"
|
||||||
|
android:textSize="10sp"
|
||||||
|
android:visibility="visible"
|
||||||
|
tools:visibility="visible" />
|
||||||
|
|
||||||
|
</RelativeLayout>
|
||||||
<!--游戏消息-->
|
<!--游戏消息-->
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:id="@+id/sud_layout_name"
|
android:id="@+id/sud_layout_name"
|
||||||
@ -3151,7 +3209,7 @@
|
|||||||
android:scrollHorizontally="true"
|
android:scrollHorizontally="true"
|
||||||
android:singleLine="true"
|
android:singleLine="true"
|
||||||
tools:text="主播創建了【游戲名】房間"
|
tools:text="主播創建了【游戲名】房間"
|
||||||
android:textColor="#999999"
|
android:textColor="@color/black1"
|
||||||
android:textSize="12dp" />
|
android:textSize="12dp" />
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
|
BIN
live/src/main/res/mipmap-hdpi/ic_live_rom_tricky.png
Normal file
BIN
live/src/main/res/mipmap-hdpi/ic_live_rom_tricky.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 2.6 KiB |
BIN
live/src/main/res/mipmap-mdpi/ic_live_rom_tricky.png
Normal file
BIN
live/src/main/res/mipmap-mdpi/ic_live_rom_tricky.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 1.5 KiB |
BIN
live/src/main/res/mipmap-xhdpi/ic_live_rom_tricky.png
Normal file
BIN
live/src/main/res/mipmap-xhdpi/ic_live_rom_tricky.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 4.1 KiB |
BIN
live/src/main/res/mipmap-xxxhdpi/ic_live_rom_tricky.png
Normal file
BIN
live/src/main/res/mipmap-xxxhdpi/ic_live_rom_tricky.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 12 KiB |
Loading…
Reference in New Issue
Block a user