mirror of
https://github.com/beemdevelopment/Aegis.git
synced 2025-05-14 14:02:49 +00:00
Hide divider in compact mode when progressbar is visible
This commit is contained in:
parent
8b9ec5f976
commit
ee8fd2e9f2
2 changed files with 9 additions and 0 deletions
|
@ -27,6 +27,8 @@ public class EntryHolder extends RecyclerView.ViewHolder {
|
|||
private DatabaseEntry _entry;
|
||||
private ImageView _buttonRefresh;
|
||||
|
||||
private View _entryDivider;
|
||||
|
||||
private View _currentView;
|
||||
|
||||
private boolean _hidden;
|
||||
|
@ -47,6 +49,8 @@ public class EntryHolder extends RecyclerView.ViewHolder {
|
|||
_profileDrawable = view.findViewById(R.id.ivTextDrawable);
|
||||
_buttonRefresh = view.findViewById(R.id.buttonRefresh);
|
||||
|
||||
_entryDivider = view.findViewById(R.id.entryDivider);
|
||||
|
||||
_progressBar = view.findViewById(R.id.progressBar);
|
||||
int primaryColorId = view.getContext().getResources().getColor(R.color.colorPrimary);
|
||||
_progressBar.getProgressDrawable().setColorFilter(primaryColorId, PorterDuff.Mode.SRC_IN);
|
||||
|
@ -78,6 +82,10 @@ public class EntryHolder extends RecyclerView.ViewHolder {
|
|||
_progressBar.setVisibility(showProgress ? View.VISIBLE : View.GONE);
|
||||
if (showProgress) {
|
||||
_progressBar.setPeriod(((TotpInfo)entry.getInfo()).getPeriod());
|
||||
|
||||
if (_entryDivider != null) {
|
||||
_entryDivider.setVisibility(View.GONE);
|
||||
}
|
||||
}
|
||||
|
||||
// only show the button if this entry is of type HotpInfo
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue