1
0
Fork 0
mirror of https://github.com/M66B/FairEmail.git synced 2025-01-01 04:35:57 +00:00

Update folder expander

This commit is contained in:
M66B 2021-05-12 21:49:35 +02:00
parent 45d81115c0
commit 7acfc93fd3

View file

@ -391,7 +391,7 @@ public class AdapterFolder extends RecyclerView.Adapter<AdapterFolder.ViewHolder
int id = view.getId();
if (id == R.id.ibExpander) {
onCollapse(folder);
onCollapse(folder, pos);
} else if (id == R.id.tvFlagged || id == R.id.ibFlagged) {
onFlagged(folder);
} else {
@ -416,9 +416,10 @@ public class AdapterFolder extends RecyclerView.Adapter<AdapterFolder.ViewHolder
}
}
private void onCollapse(TupleFolderEx folder) {
private void onCollapse(TupleFolderEx folder, int pos) {
if (listener != null) {
folder.collapsed = !folder.collapsed;
notifyItemChanged(pos); // Update expander
set(all);
return;
}