[UI] Fix semester grades overlapping when scrolling.

This commit is contained in:
Kuba Szczodrzyński 2020-04-19 21:37:39 +02:00
parent 9b13552b73
commit 97e0f36f09
2 changed files with 5 additions and 1 deletions

3
.gitignore vendored
View File

@ -86,4 +86,5 @@ app/schemas/
signatures/ signatures/
app/.cxx app/.cxx
/i18n/

View File

@ -112,6 +112,9 @@ class SubjectViewHolder(
)) ))
} }
// remove previously added grades from year preview
if (b.yearContainer.childCount > 1)
b.yearContainer.removeViews(1, b.yearContainer.childCount - 1)
// add the yearly grades to summary container (expanded) // add the yearly grades to summary container (expanded)
item.proposedGrade?.let { item.proposedGrade?.let {
b.yearContainer.addView(GradeView( b.yearContainer.addView(GradeView(