[Modify]修復公會消息bug
This commit is contained in:
@@ -966,21 +966,25 @@ public class MessageListPanelEx {
|
||||
messageListView.post(() -> {
|
||||
RecyclerView.LayoutManager layoutManager = messageListView.getLayoutManager();
|
||||
if (layoutManager != null) {
|
||||
View view = layoutManager.findViewByPosition(index);
|
||||
RelativeLayout relativeLayout = (RelativeLayout) view; //获取布局中任意控件对象
|
||||
FrameLayout frameLayout = null;
|
||||
if (relativeLayout != null) {
|
||||
frameLayout = relativeLayout.findViewById(R.id.message_item_content);
|
||||
}
|
||||
if (frameLayout != null) {
|
||||
//透明度起始为1,结束时为0
|
||||
ObjectAnimator animator = ObjectAnimator.ofFloat(frameLayout, "alpha", 0f, 1f);
|
||||
animator.setDuration(1000);//时间1s
|
||||
animator.setRepeatCount(1);
|
||||
animator.setRepeatMode(ValueAnimator.RESTART);
|
||||
animator.start();
|
||||
try {
|
||||
View view = layoutManager.findViewByPosition(index);
|
||||
RelativeLayout relativeLayout = (RelativeLayout) view; //获取布局中任意控件对象
|
||||
FrameLayout frameLayout = null;
|
||||
if (relativeLayout != null) {
|
||||
frameLayout = relativeLayout.findViewById(R.id.message_item_content);
|
||||
}
|
||||
if (frameLayout != null) {
|
||||
//透明度起始为1,结束时为0
|
||||
ObjectAnimator animator = ObjectAnimator.ofFloat(frameLayout, "alpha", 0f, 1f);
|
||||
animator.setDuration(1000);//时间1s
|
||||
animator.setRepeatCount(1);
|
||||
animator.setRepeatMode(ValueAnimator.RESTART);
|
||||
animator.start();
|
||||
|
||||
isShowAnim = true;
|
||||
isShowAnim = true;
|
||||
}
|
||||
}catch (Exception e){
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
Reference in New Issue
Block a user