1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2024-12-30 19:56:10 +00:00

Prevent crash

This commit is contained in:
M66B 2019-10-21 09:16:33 +02:00
parent 8f23b74d2b
commit 6a237304a0

View file

@ -474,7 +474,8 @@ public class FragmentMessages extends FragmentBase implements SharedPreferences.
DividerItemDecoration itemDecorator = new DividerItemDecoration(getContext(), llm.getOrientation()) { DividerItemDecoration itemDecorator = new DividerItemDecoration(getContext(), llm.getOrientation()) {
@Override @Override
public void getItemOffsets(Rect outRect, View view, RecyclerView parent, RecyclerView.State state) { public void getItemOffsets(Rect outRect, View view, RecyclerView parent, RecyclerView.State state) {
if (view.findViewById(R.id.clItem).getVisibility() == View.GONE) View clItem = view.findViewById(R.id.clItem);
if (clItem == null || clItem.getVisibility() == View.GONE)
outRect.setEmpty(); outRect.setEmpty();
else else
super.getItemOffsets(outRect, view, parent, state); super.getItemOffsets(outRect, view, parent, state);