chat_recyclerView 间距加在父类而不是子类
This commit is contained in:
parent
4f9c671e86
commit
cc48c7c2e8
@ -8,7 +8,7 @@
|
|||||||
</item>
|
</item>
|
||||||
<item android:state_selected="false">
|
<item android:state_selected="false">
|
||||||
<shape android:shape="rectangle">
|
<shape android:shape="rectangle">
|
||||||
<solid android:color="#33ffffff" />
|
<solid android:color="#48FFF026" />
|
||||||
<corners android:bottomLeftRadius="17dp" android:bottomRightRadius="17dp" android:topLeftRadius="17dp" android:topRightRadius="17dp" />
|
<corners android:bottomLeftRadius="17dp" android:bottomRightRadius="17dp" android:topLeftRadius="17dp" android:topRightRadius="17dp" />
|
||||||
</shape>
|
</shape>
|
||||||
</item>
|
</item>
|
||||||
|
@ -292,14 +292,14 @@ public class LiveChatAdapter extends RecyclerView.Adapter {
|
|||||||
automatic_chat.setTextSize(fountSize);
|
automatic_chat.setTextSize(fountSize);
|
||||||
itemView.setTag(bean);
|
itemView.setTag(bean);
|
||||||
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
LinearLayout.LayoutParams params = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
||||||
params.setMargins(0, 0, DpUtil.dp2px(80), 0);
|
params.setMargins(0, 0, 0, 0);
|
||||||
params.gravity = Gravity.CENTER_VERTICAL;
|
params.gravity = Gravity.CENTER_VERTICAL;
|
||||||
mBg.setLayoutParams(params);
|
mBg.setLayoutParams(params);
|
||||||
if (bean.getType() == 6) {//大作战活动
|
if (bean.getType() == 6) {//大作战活动
|
||||||
view_action_game.setVisibility(View.VISIBLE);
|
view_action_game.setVisibility(View.VISIBLE);
|
||||||
bean.setHeart(position);
|
bean.setHeart(position);
|
||||||
params = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
params = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
||||||
params.setMargins(0, 0, 80, 12);
|
params.setMargins(0, 0, 0, 12);
|
||||||
mBg.setLayoutParams(params);
|
mBg.setLayoutParams(params);
|
||||||
|
|
||||||
mTextView.setVisibility(View.GONE);
|
mTextView.setVisibility(View.GONE);
|
||||||
@ -452,7 +452,7 @@ public class LiveChatAdapter extends RecyclerView.Adapter {
|
|||||||
// }
|
// }
|
||||||
else if (bean.getType() == -2) {//自动消息,点击发言
|
else if (bean.getType() == -2) {//自动消息,点击发言
|
||||||
LinearLayout.LayoutParams params3 = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
LinearLayout.LayoutParams params3 = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
||||||
params3.setMargins(0, 8, DpUtil.dp2px(80), 8);
|
params3.setMargins(0, 8, 0, 8);
|
||||||
params3.gravity = Gravity.CENTER_VERTICAL;
|
params3.gravity = Gravity.CENTER_VERTICAL;
|
||||||
mBg.setLayoutParams(params3);
|
mBg.setLayoutParams(params3);
|
||||||
mBg.setBackground(null);
|
mBg.setBackground(null);
|
||||||
@ -555,7 +555,7 @@ public class LiveChatAdapter extends RecyclerView.Adapter {
|
|||||||
new LoadDian9TuUtil().loadDian9TuAssets(mContext, mBg, 1);*/
|
new LoadDian9TuUtil().loadDian9TuAssets(mContext, mBg, 1);*/
|
||||||
|
|
||||||
LinearLayout.LayoutParams params3 = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
LinearLayout.LayoutParams params3 = new LinearLayout.LayoutParams(ViewGroup.LayoutParams.MATCH_PARENT, ViewGroup.LayoutParams.WRAP_CONTENT);
|
||||||
params3.setMargins(0, 8, DpUtil.dp2px(80), 8);
|
params3.setMargins(0, 8, 0, 8);
|
||||||
params3.gravity = Gravity.CENTER_VERTICAL;
|
params3.gravity = Gravity.CENTER_VERTICAL;
|
||||||
mBg.setLayoutParams(params3);
|
mBg.setLayoutParams(params3);
|
||||||
prank_open_live_layout.setVisibility(View.VISIBLE);
|
prank_open_live_layout.setVisibility(View.VISIBLE);
|
||||||
|
@ -204,6 +204,7 @@
|
|||||||
android:layout_alignParentBottom="true"
|
android:layout_alignParentBottom="true"
|
||||||
android:layout_marginTop="385dp"
|
android:layout_marginTop="385dp"
|
||||||
android:overScrollMode="never"
|
android:overScrollMode="never"
|
||||||
|
android:layout_marginEnd="80dp"
|
||||||
android:scrollbars="none" />
|
android:scrollbars="none" />
|
||||||
|
|
||||||
<LinearLayout
|
<LinearLayout
|
||||||
|
Loading…
Reference in New Issue
Block a user