Fix a couple UI inconsistencies

This commit is contained in:
Michael Schättgen 2024-03-15 22:12:55 +01:00
parent dfd720b406
commit f1e14e6645
2 changed files with 8 additions and 2 deletions

View File

@ -375,6 +375,7 @@ public class EntryAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
}
sortShownEntries();
checkPeriodUniformity();
_view.onListChange();
notifyDataSetChanged();
}
@ -669,6 +670,10 @@ public class EntryAdapter extends RecyclerView.Adapter<RecyclerView.ViewHolder>
return -1;
}
if (infos.size() == 1) {
return infos.get(0).getPeriod();
}
Map<Integer, Integer> occurrences = new HashMap<>();
for (TotpInfo info : infos) {
int period = info.getPeriod();

View File

@ -98,7 +98,7 @@
</LinearLayout>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_height="match_parent"
android:orientation="horizontal"
android:layout_marginTop="10dp"
android:layout_marginStart="44.5dp">
@ -110,8 +110,9 @@
android:layout_weight="1">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/text_issuer"
android:maxLines="1"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_height="wrap_content"
android:inputType="text"/>
</com.google.android.material.textfield.TextInputLayout>
<com.google.android.material.textfield.TextInputLayout