小游戏麦位大小适配模拟器平板模式
This commit is contained in:
@@ -93,6 +93,9 @@ class GameRoomFragment : BaseRoomFragment<IGameRoomView?, GameRoomPresenter?>(),
|
||||
gameBinding.microView.bindAdapter(GameMiniMicroViewAdapter(context).apply {
|
||||
setOnClick { gameBinding.ivShowMic.callOnClick() }
|
||||
})
|
||||
gameBinding.llMicView.updateLayoutParams<LinearLayout.LayoutParams> {
|
||||
width = LinearLayout.LayoutParams.WRAP_CONTENT
|
||||
}
|
||||
gameBinding.tvShowMiniMic.isVisible = false
|
||||
gameBinding.microView.postDelayed({
|
||||
gameBinding.ivShowMic.isVisible = true
|
||||
@@ -106,6 +109,9 @@ class GameRoomFragment : BaseRoomFragment<IGameRoomView?, GameRoomPresenter?>(),
|
||||
marginStart = ScreenUtil.dip2px(10f)
|
||||
marginEnd = ScreenUtil.dip2px(10f)
|
||||
}
|
||||
gameBinding.llMicView.updateLayoutParams<LinearLayout.LayoutParams> {
|
||||
width = LinearLayout.LayoutParams.MATCH_PARENT
|
||||
}
|
||||
gameBinding.microView.bindAdapter(GameMicroViewAdapter(context))
|
||||
gameBinding.tvShowMiniMic.isVisible = true
|
||||
gameBinding.llMicView.background = null
|
||||
|
@@ -362,10 +362,12 @@ public class MicroView extends FrameLayout implements View.OnLayoutChangeListene
|
||||
if (adapter instanceof GameMicroViewAdapter) {
|
||||
giftWidth = UIUtil.dip2px(mContext, 60);
|
||||
giftHeight = UIUtil.dip2px(mContext, 60);
|
||||
}
|
||||
if (adapter instanceof GameMiniMicroViewAdapter) {
|
||||
} else if (adapter instanceof GameMiniMicroViewAdapter) {
|
||||
giftWidth = UIUtil.dip2px(mContext, 16);
|
||||
giftHeight = UIUtil.dip2px(mContext, 16);
|
||||
} else {
|
||||
giftWidth = UIUtil.dip2px(mContext, 80);
|
||||
giftHeight = UIUtil.dip2px(mContext, 80);
|
||||
}
|
||||
if (adapter instanceof DatingMicroViewAdapter) {
|
||||
if (datingItemDecoration == null) datingItemDecoration = new DatingItemDecoration();
|
||||
|
@@ -209,7 +209,9 @@ public class DynamicFaceDialog extends BottomSheetDialog
|
||||
* @return 返回格式是 List<List<FaceInfo>>, 子元素是一个个的列表,每一个子列表代表的是表情面板上看到的每一页
|
||||
*/
|
||||
private List<List<FaceInfo>> resolveData(List<FaceInfo> faceInfos) {
|
||||
int size = faceInfos.size();
|
||||
if (ListUtils.isListEmpty(faceInfos)){
|
||||
return new ArrayList<>();
|
||||
}
|
||||
List<List<FaceInfo>> results = new ArrayList<>();
|
||||
// 动画完成后直接消失的表情
|
||||
List<FaceInfo> normalFaceList = new ArrayList<>();
|
||||
|
@@ -74,7 +74,7 @@
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/ll_mic_view"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_gravity="end"
|
||||
android:gravity="end|center_vertical"
|
||||
|
Reference in New Issue
Block a user