中英文页面适配修改

This commit is contained in:
18401019693 2023-09-28 14:47:10 +08:00
parent e191fb82a3
commit 4b46c72f5a
23 changed files with 293 additions and 142 deletions

View File

@ -38,6 +38,17 @@ public class SudRoomListModel extends BaseModel {
private String liveUid;
@SerializedName("sex")
private String sex;
@SerializedName("sud_game_icon")
private String sudgameicon;
public String getSudgameicon() {
return sudgameicon;
}
public SudRoomListModel setSudgameicon(String sudgameicon) {
this.sudgameicon = sudgameicon;
return this;
}
public String getLiveUid() {
return liveUid;

View File

@ -109,7 +109,7 @@ public class SudGameListPopup extends BottomPopupView {
@Override
public void loadData(int p, HttpCallback callback) {
page = p;
LiveHttpUtil.getRoomList(id, mSill, roomHolderType, mLiveUid, p, callback);
LiveHttpUtil.getRoomList(id, mSill, roomHolderType, mLiveUid, p-1, callback);
}
@Override

View File

@ -8,7 +8,6 @@ import android.view.View;
import android.view.ViewTreeObserver;
import android.widget.Toast;
import com.yunbao.common.sud.decorator.SudFSMMGCache;
import com.yunbao.common.sud.decorator.SudFSMMGDecorator;
import com.yunbao.common.sud.decorator.SudFSMMGListener;
@ -178,7 +177,9 @@ public abstract class BaseGameViewModel implements SudFSMMGListener {
// region 生命周期相关
/** 页面销毁的时候调用 */
/**
* 页面销毁的时候调用
*/
public void onDestroy() {
isRunning = false;
destroyMG();
@ -186,7 +187,9 @@ public abstract class BaseGameViewModel implements SudFSMMGListener {
// endregion 生命周期相关
/** 销毁游戏 */
/**
* 销毁游戏
*/
private void destroyMG() {
if (playingGameId > 0) {
sudFSTAPPDecorator.destroyMG();
@ -197,7 +200,9 @@ public abstract class BaseGameViewModel implements SudFSMMGListener {
}
}
/** 获取当前游戏房id */
/**
* 获取当前游戏房id
*/
public String getGameRoomId() {
return gameRoomId;
}
@ -330,7 +335,9 @@ public abstract class BaseGameViewModel implements SudFSMMGListener {
// endregion 游戏侧回调
/** 处理code过期 */
/**
* 处理code过期
*/
public void processOnExpireCode(SudFSTAPPDecorator sudFSTAPPDecorator, ISudFSMStateHandle handle) {
// code过期刷新code
getCode(null, getUserId(), getAppId(), new GameGetCodeListener() {
@ -377,14 +384,16 @@ public abstract class BaseGameViewModel implements SudFSMMGListener {
});
}
/** 通知游戏,游戏视图信息 */
/**
* 通知游戏游戏视图信息
*/
private void notifyGameViewInfo(ISudFSMStateHandle handle, int gameViewWidth, int gameViewHeight) {
GameViewInfoModel gameViewInfoModel = new GameViewInfoModel();
gameViewInfoModel.ret_code = 0;
// 游戏View大小
gameViewInfoModel.view_size.width = gameViewWidth;
gameViewInfoModel.view_size.height = gameViewHeight;
gameViewInfoModel.view_game_rect.bottom = gameViewHeight / 10;
// 游戏安全操作区域
getGameRect(gameViewInfoModel);
@ -415,16 +424,24 @@ public abstract class BaseGameViewModel implements SudFSMMGListener {
handle.success(SudJsonUtils.toJson(gameConfigModel));
}
/** 游戏login(getCode)监听 */
/**
* 游戏login(getCode)监听
*/
public interface GameGetCodeListener {
/** 成功 */
/**
* 成功
*/
void onSuccess(String code);
/** 失败 */
/**
* 失败
*/
void onFailed();
}
/** 获取游戏状态缓存 */
/**
* 获取游戏状态缓存
*/
public SudFSMMGCache getSudFSMMGCache() {
return sudFSMMGDecorator.getSudFSMMGCache();
}

View File

@ -21,6 +21,7 @@ import com.yunbao.common.http.live.LiveNetManager;
import com.yunbao.common.manager.IMLoginManager;
import com.yunbao.common.sud.QuickStartGameViewModel;
import com.yunbao.common.sud.model.GameConfigModel;
import com.yunbao.common.sud.model.GameViewInfoModel;
import com.yunbao.common.utils.Bus;
import com.yunbao.common.utils.ToastUtil;
import com.yunbao.common.views.weight.ViewClicksAntiShake;
@ -105,6 +106,7 @@ public class LiveSudGamePopup extends BottomPopupView {
GameConfigModel gameConfigModel = gameViewModel.getGameConfigModel();
gameConfigModel.ui.ping.hide = true; // 配置不隐藏ping值
gameConfigModel.ui.level.hide = true; // 配置不隐藏ping值
// SudMGP平台64bit游戏ID
gameViewModel.switchGame((Activity) getContext(), mLiveUid, mInteractionID);
}

View File

@ -38,7 +38,8 @@ public class SudGameListViewHolder extends RecyclerView.ViewHolder {
private TextView roomName, playerWeAre, playerWeAre2, goldenBeanNumber;
private RoundedImageView avatarList1, avatarList2, avatarList3, avatarList4, avatarList5;
private GifImageView gifImageView;
private ImageView sex;
private ImageView sex,game_icon;
public SudGameListViewHolder(@NonNull View itemView) {
super(itemView);
@ -46,6 +47,7 @@ public class SudGameListViewHolder extends RecyclerView.ViewHolder {
roomName = itemView.findViewById(R.id.room_name);
playerWeAre = itemView.findViewById(R.id.player_we_are);
playerWeAre2 = itemView.findViewById(R.id.player_we_are_2);
game_icon = itemView.findViewById(R.id.game_icon);
goldenBeanNumber = itemView.findViewById(R.id.golden_bean_number);
gifImageView = itemView.findViewById(R.id.btn_live);
avatarList1 = itemView.findViewById(R.id.avatar_list1);
@ -73,31 +75,32 @@ public class SudGameListViewHolder extends RecyclerView.ViewHolder {
} else if (TextUtils.equals(model.getSex(), "2")) {
ImgLoader.display(itemView.getContext(), R.mipmap.icon_sex_woman, sex);
}
List<playerObject> playerObjects = model.getPlayerObjects();
for (int i = 0; i < playerObjects.size(); i++) {
switch (i) {
case 0:
avatarList1.setVisibility(View.VISIBLE);
ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList1);
break;
case 1:
avatarList2.setVisibility(View.VISIBLE);
ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList2);
break;
case 2:
avatarList3.setVisibility(View.VISIBLE);
ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList3);
break;
case 3:
avatarList4.setVisibility(View.VISIBLE);
ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList4);
break;
case 4:
avatarList5.setVisibility(View.VISIBLE);
ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList5);
break;
}
}
// List<playerObject> playerObjects = model.getPlayerObjects();
// for (int i = 0; i < playerObjects.size(); i++) {
// switch (i) {
// case 0:
// avatarList1.setVisibility(View.VISIBLE);
// ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList1);
// break;
// case 1:
// avatarList2.setVisibility(View.VISIBLE);
// ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList2);
// break;
// case 2:
// avatarList3.setVisibility(View.VISIBLE);
// ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList3);
// break;
// case 3:
// avatarList4.setVisibility(View.VISIBLE);
// ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList4);
// break;
// case 4:
// avatarList5.setVisibility(View.VISIBLE);
// ImgLoader.display(itemView.getContext(), playerObjects.get(i).getAvatar(), avatarList5);
// break;
// }
// }
ImgLoader.display(itemView.getContext(), model.getSudgameicon(), game_icon);
ViewClicksAntiShake.clicksAntiShake(itemView.findViewById(R.id.layout), new ViewClicksAntiShake.ViewClicksCallBack() {
@Override
public void onViewClicks() {

View File

@ -42,7 +42,7 @@
android:gravity="center"
android:text="@string/video_exit"
android:textColor="#FFFFFF"
android:textSize="12sp" />
android:textSize="8sp" />
</LinearLayout>
<RelativeLayout

View File

@ -45,7 +45,8 @@
android:gravity="center_vertical">
<TextView
android:layout_width="wrap_content"
android:layout_width="120dp"
android:gravity="end"
android:layout_height="wrap_content"
android:text="@string/interactive_game_create_room_name"
android:textColor="#000"
@ -73,7 +74,8 @@
android:gravity="center_vertical">
<TextView
android:layout_width="wrap_content"
android:layout_width="120dp"
android:gravity="end"
android:layout_height="wrap_content"
android:text="@string/interactive_game_create_game_type"
android:textColor="#000"
@ -100,7 +102,8 @@
android:gravity="center_vertical">
<TextView
android:layout_width="wrap_content"
android:layout_width="120dp"
android:gravity="end"
android:layout_height="wrap_content"
android:text="@string/interactive_game_create_game_sill"
android:textColor="#000"
@ -114,6 +117,7 @@
android:hint="@string/interactive_game_create_gold_bean_quantity"
android:inputType="numberDecimal"
android:paddingStart="12dp"
android:ellipsize="end"
android:paddingTop="9dp"
android:paddingBottom="9dp"
android:textColor="#E6000000"
@ -131,6 +135,6 @@
android:gravity="center"
android:text="@string/interactive_game_create_room"
android:textColor="#FFFFFF"
android:textSize="14sp"
android:textSize="12sp"
android:textStyle="bold" />
</LinearLayout>

View File

@ -49,10 +49,12 @@
android:layout_width="266dp"
android:layout_height="wrap_content"
android:background="@null"
android:ellipsize="end"
android:hint="@string/interactive_game_search_room_name_input"
android:paddingStart="5dp"
android:paddingTop="9dp"
android:paddingBottom="9dp"
android:singleLine="true"
android:textColor="#000"
android:textColorHint="#000"
android:textSize="10sp" />
@ -112,7 +114,7 @@
android:paddingTop="12dp"
android:paddingEnd="30dp"
android:paddingBottom="12dp"
android:text="暫未搜索結果~"
android:text="@string/interactive_game_search_room_have_been_found"
android:textColor="#CCFFFFFF"
android:textSize="14sp" />
</LinearLayout>

View File

@ -265,13 +265,13 @@
<ImageView
android:layout_width="40dp"
android:layout_height="40dp"
android:src="@mipmap/icon_live_qa" />
android:src="@mipmap/iconlive_tool_game" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:text="游戏房间"
android:text="@string/interactive_game"
android:textColor="#FF9A9A9A"
android:textSize="12sp" />
</LinearLayout>

View File

@ -42,7 +42,7 @@
android:gravity="center"
android:text="@string/video_exit"
android:textColor="#FFFFFF"
android:textSize="12sp" />
android:textSize="8sp" />
</LinearLayout>
<RelativeLayout

View File

@ -58,6 +58,8 @@
android:layout_width="266dp"
android:layout_height="match_parent"
android:background="@null"
android:ellipsize="end"
android:singleLine="true"
android:hint="@string/interactive_game_search_room_name_input"
android:paddingStart="5dp"
android:paddingTop="9dp"
@ -120,7 +122,7 @@
android:paddingTop="12dp"
android:paddingEnd="30dp"
android:paddingBottom="12dp"
android:text="暫未搜索結果~"
android:text="@string/interactive_game_search_room_have_been_found"
android:textColor="#CCFFFFFF"
android:textSize="14sp" />
</LinearLayout>

View File

@ -69,7 +69,7 @@
android:layout_marginStart="14dp"
android:text="@string/interactive_game_room_game"
android:textColor="#fff"
android:textSize="14sp" />
android:textSize="11sp" />
<LinearLayout
android:id="@+id/interactive_game_room_game"
@ -81,45 +81,54 @@
<TextView
android:id="@+id/game_title"
android:layout_width="wrap_content"
android:layout_width="35dp"
android:layout_height="wrap_content"
android:layout_marginStart="6dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_room_game_all"
android:textColor="#fff"
android:textSize="14sp" />
android:textSize="11sp" />
<View
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_weight="1" />
<ImageView
android:id="@+id/room_game_arrow"
android:layout_width="8dp"
android:layout_height="14dp"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:src="@mipmap/icon_interactive_game_arrow" />
</LinearLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginStart="10dp"
android:text="@string/interactive_game_room_sill"
android:textColor="#fff"
android:textSize="14sp" />
android:textSize="11sp" />
<FrameLayout
android:id="@+id/room_sill"
android:layout_width="74dp"
android:layout_width="82dp"
android:layout_height="28dp"
android:layout_marginStart="4dp"
android:background="@drawable/bg_live_sud_list_btn">
<TextView
android:id="@+id/room_sill_text"
android:layout_width="wrap_content"
android:layout_width="55dp"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="6dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_create_unlimited"
android:textColor="#fff"
android:textSize="14sp" />
android:textSize="11sp" />
<ImageView
android:id="@+id/room_sill_arrow"
@ -133,33 +142,41 @@
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginStart="20dp"
android:layout_marginStart="10dp"
android:text="@string/interactive_game_room_house_owner"
android:textColor="#fff"
android:textSize="14sp" />
android:textSize="11sp" />
<LinearLayout
android:id="@+id/house_owner"
android:layout_width="58dp"
android:layout_width="70dp"
android:layout_height="28dp"
android:layout_marginStart="4dp"
android:background="@drawable/bg_live_sud_list_btn"
android:gravity="center_vertical">
android:gravity="center_vertical"
android:orientation="horizontal">
<TextView
android:id="@+id/house_owner_text"
android:layout_width="wrap_content"
android:layout_width="55dp"
android:layout_height="wrap_content"
android:layout_marginStart="6dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_create_unlimited"
android:textColor="#fff"
android:textSize="14sp" />
android:textSize="11sp" />
<View
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_weight="1" />
<ImageView
android:id="@+id/house_owner_arrow"
android:layout_width="8dp"
android:layout_height="14dp"
android:layout_marginStart="8dp"
android:layout_marginEnd="5dp"
android:src="@mipmap/icon_interactive_game_arrow" />
</LinearLayout>
</LinearLayout>
@ -185,7 +202,7 @@
android:gravity="center"
android:text="@string/interactive_game_room_random_start"
android:textColor="#FF8100"
android:textSize="18sp" />
android:textSize="16sp" />
</FrameLayout>
</LinearLayout>

View File

@ -55,10 +55,19 @@
android:textColor="#000"
android:textSize="14sp" />
<View
android:layout_width="1dp"
android:layout_height="0dp"
android:layout_weight="1" />
<TextView
android:id="@+id/player_we_are"
android:layout_width="wrap_content"
android:layout_width="150dp"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_marginBottom="15dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_player_we_are"
android:textColor="#B3000000"
android:textSize="12sp" />
@ -71,7 +80,8 @@
<LinearLayout
android:layout_width="79dp"
android:layout_height="20dp">
android:layout_height="20dp"
android:visibility="gone">
<com.makeramen.roundedimageview.RoundedImageView
android:id="@+id/avatar_list1"
@ -119,13 +129,7 @@
android:layout_height="20dp"
android:visibility="gone" />
<TextView
android:id="@+id/player_we_are_2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/interactive_game_player_we_are_2"
android:textColor="#000"
android:textSize="12sp" />
</LinearLayout>
</LinearLayout>
@ -134,9 +138,16 @@
android:layout_height="1dp"
android:layout_weight="1" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:layout_marginEnd="3dp"
android:orientation="vertical">
<LinearLayout
android:layout_width="68dp"
android:layout_height="26dp"
android:layout_gravity="end"
android:background="@drawable/bg_home_sud_list_sill"
android:gravity="center_vertical">
@ -155,4 +166,32 @@
android:layout_marginStart="2dp"
android:background="@mipmap/gold_coin" />
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_marginTop="10dp"
android:gravity="bottom">
<TextView
android:id="@+id/player_we_are_2"
android:layout_width="70dp"
android:layout_height="wrap_content"
android:layout_marginEnd="3dp"
android:layout_marginBottom="10dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_player_we_are_2"
android:textColor="#000"
android:textSize="12sp" />
<ImageView
android:id="@+id/game_icon"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginEnd="5dp" />
</LinearLayout>
</LinearLayout>
</LinearLayout>

View File

@ -1,10 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/layout"
android:layout_width="match_parent"
android:layout_height="88dp"
android:layout_marginStart="15dp"
android:id="@+id/layout"
android:layout_marginTop="14dp"
android:layout_marginEnd="15dp"
android:background="@mipmap/background_sud_game_list"
@ -55,10 +55,20 @@
android:textColor="@color/white"
android:textSize="14sp" />
<View
android:layout_width="1dp"
android:layout_height="0dp"
android:layout_weight="1" />
<TextView
android:id="@+id/player_we_are"
android:layout_width="wrap_content"
android:layout_width="150dp"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:ellipsize="end"
android:singleLine="true"
android:layout_marginBottom="20dp"
android:text="@string/interactive_game_player_we_are"
android:textColor="#80ffffff"
android:textSize="12sp" />
@ -67,7 +77,8 @@
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginTop="6dp"
android:gravity="center_vertical">
android:gravity="center_vertical"
android:visibility="gone">
<LinearLayout
android:layout_width="79dp"
@ -119,13 +130,6 @@
android:layout_height="20dp"
android:visibility="gone" />
<TextView
android:id="@+id/player_we_are_2"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/interactive_game_player_we_are_2"
android:textColor="#ffffff"
android:textSize="12sp" />
</LinearLayout>
</LinearLayout>
@ -134,9 +138,16 @@
android:layout_height="1dp"
android:layout_weight="1" />
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="match_parent"
android:orientation="vertical">
<LinearLayout
android:layout_width="68dp"
android:layout_height="26dp"
android:layout_gravity="end"
android:background="@drawable/bg_live_sud_list_sill"
android:gravity="center_vertical">
@ -155,4 +166,31 @@
android:layout_marginStart="2dp"
android:background="@mipmap/gold_coin" />
</LinearLayout>
<LinearLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="bottom"
android:layout_marginTop="10dp"
android:gravity="bottom">
<TextView
android:id="@+id/player_we_are_2"
android:layout_width="70dp"
android:layout_height="wrap_content"
android:layout_marginEnd="3dp"
android:layout_marginBottom="10dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_player_we_are_2"
android:textColor="@color/white"
android:textSize="12sp" />
<ImageView
android:id="@+id/game_icon"
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_marginEnd="5dp" />
</LinearLayout>
</LinearLayout>
</LinearLayout>

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.7 KiB

View File

@ -1320,7 +1320,7 @@ Limited ride And limited avatar frame</string>
<string name="live_send_red_packge_fans_group">Join a fans club</string>
<string name="interactive_game">Interactive Games</string>
<string name="interactive_game_room_list">Room list</string>
<string name="interactive_game_room_game">Game</string>
<string name="interactive_game_room_game">Game:</string>
<string name="interactive_game_room_game_all">All</string>
<string name="interactive_game_room_sill">Threshold:</string>
<string name="interactive_game_room_house_owner">owner:</string>
@ -1345,5 +1345,6 @@ Limited ride And limited avatar frame</string>
<string name="interactive_game_search_room">Search for room</string>
<string name="interactive_game_search_history">Search History</string>
<string name="interactive_game_search_room_name_input">Search for room: Please enter the owner\'s name, owner ID, or room name you want to search for.</string>
<string name="interactive_game_search_room_have_been_found">No search results have been found</string>
</resources>

View File

@ -1341,4 +1341,5 @@
<string name="interactive_game_search_room">搜索房間</string>
<string name="interactive_game_search_history">搜索历史</string>
<string name="interactive_game_search_room_name_input">請輸入您要搜索的房主昵稱、房主ID或房間名</string>
<string name="interactive_game_search_room_have_been_found">暫未搜索結果~</string>
</resources>

View File

@ -1340,4 +1340,5 @@
<string name="interactive_game_search_room">搜索房間</string>
<string name="interactive_game_search_history">搜索历史</string>
<string name="interactive_game_search_room_name_input">請輸入您要搜索的房主昵稱、房主ID或房間名</string>
<string name="interactive_game_search_room_have_been_found">暫未搜索結果~</string>
</resources>

View File

@ -1341,5 +1341,6 @@
<string name="interactive_game_search_room">搜索房間</string>
<string name="interactive_game_search_history">搜索历史</string>
<string name="interactive_game_search_room_name_input">請輸入您要搜索的房主昵稱、房主ID或房間名</string>
<string name="interactive_game_search_room_have_been_found">暫未搜索結果~</string>
</resources>

View File

@ -1322,7 +1322,7 @@ Limited ride And limited avatar frame</string>
<string name="live_send_red_packge_fans_group">Join a fans club</string>
<string name="interactive_game">Interactive Games</string>
<string name="interactive_game_room_list">Room list</string>
<string name="interactive_game_room_game">Game</string>
<string name="interactive_game_room_game">Game:</string>
<string name="interactive_game_room_game_all">All</string>
<string name="interactive_game_room_sill">Threshold:</string>
<string name="interactive_game_room_house_owner">owner:</string>
@ -1347,4 +1347,5 @@ Limited ride And limited avatar frame</string>
<string name="interactive_game_search_room">Search for room</string>
<string name="interactive_game_search_history">Search History</string>
<string name="interactive_game_search_room_name_input">Search for room: Please enter the owner\'s name, owner ID, or room name you want to search for.</string>
<string name="interactive_game_search_room_have_been_found">No search results have been found</string>
</resources>

View File

@ -1117,16 +1117,16 @@ public class PortraitLiveManager implements LivePlayListener, SocketMessageListe
}
}, 3000);
}
String jsonCreateSudRoom = IMLoginManager.get(mContext).getSudGame();
if (!TextUtils.isEmpty(jsonCreateSudRoom)) {
CreateSudRoomModel createSudRoomModel = new Gson().fromJson(jsonCreateSudRoom, CreateSudRoomModel.class);
new XPopup.Builder(mContext)
.enableDrag(false)
.dismissOnTouchOutside(false)
.dismissOnBackPressed(false)
.asCustom(new LiveSudGamePopup(mContext, createSudRoomModel))
.show();
}
// String jsonCreateSudRoom = IMLoginManager.get(mContext).getSudGame();
// if (!TextUtils.isEmpty(jsonCreateSudRoom)) {
// CreateSudRoomModel createSudRoomModel = new Gson().fromJson(jsonCreateSudRoom, CreateSudRoomModel.class);
// new XPopup.Builder(mContext)
// .enableDrag(false)
// .dismissOnTouchOutside(false)
// .dismissOnBackPressed(false)
// .asCustom(new LiveSudGamePopup(mContext, createSudRoomModel))
// .show();
// }
} else {
enterRoomLeaveHandler.postDelayed(enterRoomLeaveRunnable, 200);
}

View File

@ -101,7 +101,7 @@ public class MainHomeGameViewHolder extends AbsMainHomeChildViewHolder implement
@Override
public void loadData(int p, com.yunbao.common.http.HttpCallback callback) {
LiveHttpUtil.getRoomList(id, mSill, roomHolderType, "0", p, callback);
LiveHttpUtil.getRoomList(id, mSill, roomHolderType, "0", p-1, callback);
}
@Override

View File

@ -62,7 +62,7 @@
android:layout_marginStart="14dp"
android:text="@string/interactive_game_room_game"
android:textColor="#000"
android:textSize="14sp"
android:textSize="11sp"
android:textStyle="bold" />
<LinearLayout
@ -75,18 +75,20 @@
<TextView
android:id="@+id/game_title"
android:layout_width="wrap_content"
android:layout_width="35dp"
android:layout_height="wrap_content"
android:layout_marginStart="6dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_room_game_all"
android:textColor="#000"
android:textSize="14sp" />
android:textSize="11sp" />
<ImageView
android:id="@+id/room_game_arrow"
android:layout_width="8dp"
android:layout_height="14dp"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:src="@mipmap/icon_home_interactive_game_arrow" />
</LinearLayout>
@ -96,7 +98,7 @@
android:layout_marginStart="20dp"
android:text="@string/interactive_game_room_sill"
android:textColor="#000"
android:textSize="14sp"
android:textSize="11sp"
android:textStyle="bold" />
<FrameLayout
@ -108,13 +110,15 @@
<TextView
android:id="@+id/room_sill_text"
android:layout_width="wrap_content"
android:layout_width="55dp"
android:layout_height="wrap_content"
android:layout_gravity="center_vertical"
android:layout_marginStart="6dp"
android:ellipsize="end"
android:singleLine="true"
android:text="@string/interactive_game_create_unlimited"
android:textColor="#000"
android:textSize="14sp" />
android:textSize="11sp" />
<ImageView
android:id="@+id/room_sill_arrow"
@ -131,12 +135,12 @@
android:layout_marginStart="20dp"
android:text="@string/interactive_game_room_house_owner"
android:textColor="#000"
android:textSize="14sp"
android:textSize="11sp"
android:textStyle="bold" />
<LinearLayout
android:id="@+id/house_owner"
android:layout_width="58dp"
android:layout_width="70dp"
android:layout_height="28dp"
android:layout_marginStart="4dp"
android:background="@drawable/bg_home_sud_list_btn"
@ -144,19 +148,26 @@
<TextView
android:id="@+id/house_owner_text"
android:layout_width="wrap_content"
android:layout_width="50dp"
android:layout_height="wrap_content"
android:layout_marginStart="6dp"
android:text="@string/interactive_game_create_unlimited"
android:singleLine="true"
android:ellipsize="end"
android:textColor="#000"
android:textSize="14sp" />
android:textSize="11sp" />
<View
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_weight="1" />
<ImageView
android:id="@+id/house_owner_arrow"
android:layout_width="8dp"
android:layout_height="14dp"
android:layout_marginStart="8dp"
android:src="@mipmap/icon_home_interactive_game_arrow" />
android:layout_marginEnd="5dp"
android:src="@mipmap/icon_interactive_game_arrow" />
</LinearLayout>
</LinearLayout>
@ -183,7 +194,7 @@
android:gravity="center"
android:text="@string/interactive_game_room_random_start"
android:textColor="#FF8100"
android:textSize="18sp"
android:textSize="16sp"
app:layout_constraintBottom_toBottomOf="@+id/refreshView"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" />