底部间隔修改实现
This commit is contained in:
parent
1caa595e00
commit
4f9c671e86
@ -278,7 +278,7 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
private GifImageView mGifImageView;
|
private GifImageView mGifImageView;
|
||||||
public static SVGAImageView mSVGAImageView;
|
public static SVGAImageView mSVGAImageView;
|
||||||
private ViewGroup mLiveGiftPrizePoolContainer;
|
private ViewGroup mLiveGiftPrizePoolContainer;
|
||||||
|
private LinearLayout live_bottom_layout;
|
||||||
private View mBtnPrizePool;//奖池按钮
|
private View mBtnPrizePool;//奖池按钮
|
||||||
private TextView mPrizePoolLevel;//奖池等级
|
private TextView mPrizePoolLevel;//奖池等级
|
||||||
private int forAct;
|
private int forAct;
|
||||||
@ -1000,15 +1000,15 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
});
|
});
|
||||||
sudNameHandler.removeCallbacks(sudNameRunnable);
|
sudNameHandler.removeCallbacks(sudNameRunnable);
|
||||||
sudNameHandler.postDelayed(sudNameRunnable, 10000);
|
sudNameHandler.postDelayed(sudNameRunnable, 10000);
|
||||||
sud_layout_name.post(new Runnable() {
|
// sud_layout_name.post(new Runnable() {
|
||||||
@Override
|
// @Override
|
||||||
public void run() {
|
// public void run() {
|
||||||
//TODO 这里报了类型错误 android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.RelativeLayout$LayoutParams
|
// //TODO 这里报了类型错误 android.widget.LinearLayout$LayoutParams cannot be cast to android.widget.RelativeLayout$LayoutParams
|
||||||
ViewGroup.LayoutParams params1 = sud_layout_name.getLayoutParams();
|
//// ViewGroup.LayoutParams params1 = sud_layout_name.getLayoutParams();
|
||||||
params1.width = mChatRecyclerView.getWidth() - DpUtil.dp2px(85);
|
//// params1.width = mChatRecyclerView.getWidth() - DpUtil.dp2px(85);
|
||||||
sud_layout_name.setLayoutParams(params1);
|
//// sud_layout_name.setLayoutParams(params1);
|
||||||
}
|
// }
|
||||||
});
|
// });
|
||||||
|
|
||||||
new Handler().postDelayed(new Runnable() {
|
new Handler().postDelayed(new Runnable() {
|
||||||
@Override
|
@Override
|
||||||
@ -5637,15 +5637,20 @@ public class LiveRoomViewHolder extends AbsViewHolder implements View.OnClickLis
|
|||||||
fastMsgRecyclerView.setVisibility(View.VISIBLE);
|
fastMsgRecyclerView.setVisibility(View.VISIBLE);
|
||||||
fastMessageRecyclerViewAdapter.setMessage(greetings);
|
fastMessageRecyclerViewAdapter.setMessage(greetings);
|
||||||
RelativeLayout.LayoutParams params1 = (RelativeLayout.LayoutParams) mChatRecyclerView.getLayoutParams();
|
RelativeLayout.LayoutParams params1 = (RelativeLayout.LayoutParams) mChatRecyclerView.getLayoutParams();
|
||||||
|
live_bottom_layout = findViewById(R.id.live_bottom_layout);
|
||||||
|
RelativeLayout.LayoutParams params2 = (RelativeLayout.LayoutParams) live_bottom_layout.getLayoutParams();
|
||||||
if (greetings.size() > 0) {
|
if (greetings.size() > 0) {
|
||||||
params1.bottomMargin = 100;
|
params1.bottomMargin = DpUtil.dp2px(38);
|
||||||
|
params2.bottomMargin = DpUtil.dp2px(38);
|
||||||
} else if(isAnchorLive()){
|
} else if(isAnchorLive()){
|
||||||
params1.bottomMargin = 0;
|
params1.bottomMargin = 0;
|
||||||
|
params2.bottomMargin = 0;
|
||||||
}else {
|
}else {
|
||||||
params1.bottomMargin = DpUtil.dp2px(10);
|
params1.bottomMargin = DpUtil.dp2px(10);
|
||||||
|
params2.bottomMargin = DpUtil.dp2px(10);
|
||||||
}
|
}
|
||||||
|
|
||||||
mChatRecyclerView.setLayoutParams(params1);
|
mChatRecyclerView.setLayoutParams(params1);
|
||||||
|
live_bottom_layout.setLayoutParams(params2);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setManager(FaceManager manager) {
|
public void setManager(FaceManager manager) {
|
||||||
|
@ -2537,7 +2537,6 @@
|
|||||||
android:layout_alignParentBottom="true"
|
android:layout_alignParentBottom="true"
|
||||||
android:layout_marginStart="10dp"
|
android:layout_marginStart="10dp"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
android:layout_marginEnd="70dp"
|
|
||||||
tools:visibility="visible"/>
|
tools:visibility="visible"/>
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
@ -2559,6 +2558,7 @@
|
|||||||
android:layout_below="@id/live_video" />
|
android:layout_below="@id/live_video" />
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
android:id="@+id/live_bottom_layout"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_alignParentRight="true"
|
android:layout_alignParentRight="true"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user