Commit ecf3d303 authored by topjohnwu's avatar topjohnwu

Only show expansion when necessary

parent 15ddd0e2
......@@ -124,9 +124,14 @@ public class ApplicationAdapter extends SectionedAdapter
Shell.su(cmd).submit();
p.hidden = status;
}
if (app.expanded)
notifyItemRangeChanged(index, app.processList.size());
}
});
if (app.processList.size() > 1) {
holder.arrow.setVisibility(View.VISIBLE);
holder.trigger.setOnClickListener((v) -> {
if (app.expanded) {
app.expanded = false;
......@@ -138,6 +143,11 @@ public class ApplicationAdapter extends SectionedAdapter
holder.ex.expand();
}
});
} else {
holder.arrow.setVisibility(View.GONE);
holder.trigger.setOnClickListener(null);
}
}
@Override
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment