Merge branch 'v1.5.0/room' into v1.5.0/test

This commit is contained in:
Max
2023-11-07 15:46:54 +08:00
5 changed files with 23 additions and 8 deletions

View File

@@ -889,7 +889,10 @@ public class AVRoomActivity extends BaseMvpActivity<IAvRoomView, AvRoomPresenter
if (AvRoomDataManager.get().haveStartDragon) { if (AvRoomDataManager.get().haveStartDragon) {
giveUpDragonBar(); giveUpDragonBar();
} }
if (singleRoomTipDialog != null && singleRoomTipDialog.isAdded()) {
singleRoomTipDialog.dismissAllowingStateLoss();
singleRoomTipDialog = null;
}
// 避免 ISE // 避免 ISE
if (mPwdDialogFragment != null && mPwdDialogFragment.isAdded() if (mPwdDialogFragment != null && mPwdDialogFragment.isAdded()
&& !isFinishing()) { && !isFinishing()) {

View File

@@ -535,7 +535,9 @@ public class RoomSettingActivity extends BaseMvpActivity<IRoomSettingView, RoomS
} }
List<String> labels = new ArrayList<>(); List<String> labels = new ArrayList<>();
for (RoomSettingTabInfo tabInfo : tabInfoList) { for (RoomSettingTabInfo tabInfo : tabInfoList) {
labels.add(tabInfo.getName()); if (tabInfo.getName() != null) {
labels.add(tabInfo.getName());
}
} }
new SelectLabelDialog(this, "房间标签", labels, roomInfo.getRoomTag(), (label, data, position) -> { new SelectLabelDialog(this, "房间标签", labels, roomInfo.getRoomTag(), (label, data, position) -> {
mSelectTabInfo = tabInfoList.get(position); mSelectTabInfo = tabInfoList.get(position);
@@ -565,7 +567,9 @@ public class RoomSettingActivity extends BaseMvpActivity<IRoomSettingView, RoomS
} }
List<String> labels = new ArrayList<>(); List<String> labels = new ArrayList<>();
for (SingleRoomSortInfo tabInfo : tabInfoList) { for (SingleRoomSortInfo tabInfo : tabInfoList) {
labels.add(tabInfo.getSortName()); if (tabInfo.getSortName() != null) {
labels.add(tabInfo.getSortName());
}
} }
new SelectLabelDialog(this, "房间分类", labels, roomInfo.getRoomTag(), (label, data, position) -> { new SelectLabelDialog(this, "房间分类", labels, roomInfo.getRoomTag(), (label, data, position) -> {
singleRoomSortId = tabInfoList.get(position).getId(); singleRoomSortId = tabInfoList.get(position).getId();

View File

@@ -8,6 +8,7 @@ import android.widget.ImageView;
import android.widget.TextView; import android.widget.TextView;
import com.nnbc123.app.R; import com.nnbc123.app.R;
import com.opensource.svgaplayer.SVGAImageView;
/** /**
* @author jack * @author jack
@@ -19,7 +20,7 @@ public class CommonLoadingDialog extends BaseDialog {
private String msg = "加载中..."; private String msg = "加载中...";
private TextView tvTip; private TextView tvTip;
private ImageView ivLoading; private SVGAImageView ivLoading;
public CommonLoadingDialog(Context context, String tip) { public CommonLoadingDialog(Context context, String tip) {
super(context, R.style.dialog); super(context, R.style.dialog);
@@ -36,8 +37,7 @@ public class CommonLoadingDialog extends BaseDialog {
protected void onCreate(Bundle savedInstanceState) { protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
setContentView(R.layout.layout_progress_dialog); setContentView(R.layout.layout_progress_dialog);
ivLoading = findViewById(R.id.iv_loading); ivLoading = findViewById(R.id.iv_loading_icon);
((AnimationDrawable) ivLoading.getDrawable()).start();
tvTip = (TextView) findViewById(R.id.tv_tip); tvTip = (TextView) findViewById(R.id.tv_tip);
tvTip.setText(msg); tvTip.setText(msg);
} }
@@ -60,4 +60,11 @@ public class CommonLoadingDialog extends BaseDialog {
super.show(); super.show();
return this; return this;
} }
@Override
public void onDetachedFromWindow() {
super.onDetachedFromWindow();
ivLoading.stopAnimation();
ivLoading.clear();
}
} }

View File

@@ -117,12 +117,13 @@
android:layout_width="34dp" android:layout_width="34dp"
android:layout_height="15dp" android:layout_height="15dp"
android:layout_centerHorizontal="true" android:layout_centerHorizontal="true"
android:layout_marginTop="67dp" android:layout_marginTop="45dp"
android:background="@drawable/shape_pk_mic_queue_mark_red" android:background="@drawable/shape_pk_mic_queue_mark_red"
android:gravity="center" android:gravity="center"
android:textColor="@color/color_FFFFFF" android:textColor="@color/color_FFFFFF"
android:textSize="9dp" android:textSize="9dp"
android:visibility="gone" android:visibility="gone"
tools:visibility="visible"
tools:text="红队" /> tools:text="红队" />
<LinearLayout <LinearLayout

View File

@@ -107,7 +107,7 @@
android:layout_width="34dp" android:layout_width="34dp"
android:layout_height="15dp" android:layout_height="15dp"
android:layout_centerHorizontal="true" android:layout_centerHorizontal="true"
android:layout_marginTop="55dp" android:layout_marginTop="45dp"
android:background="@drawable/shape_pk_mic_queue_mark_red" android:background="@drawable/shape_pk_mic_queue_mark_red"
android:gravity="center" android:gravity="center"
android:textColor="@color/color_FFFFFF" android:textColor="@color/color_FFFFFF"