Scrobbling fixes
This commit is contained in:
@@ -152,11 +152,11 @@ class ScrobblingSelectorViewModel @Inject constructor(
|
|||||||
val history = historyRepository.getOne(manga)
|
val history = historyRepository.getOne(manga)
|
||||||
currentScrobbler.updateScrobblingInfo(
|
currentScrobbler.updateScrobblingInfo(
|
||||||
mangaId = manga.id,
|
mangaId = manga.id,
|
||||||
rating = prevInfo?.rating ?: manga.rating,
|
rating = prevInfo?.rating ?: 0f,
|
||||||
status = prevInfo?.status ?: if (history == null) {
|
status = prevInfo?.status ?: when {
|
||||||
ScrobblingStatus.PLANNED
|
history == null -> ScrobblingStatus.PLANNED
|
||||||
} else {
|
history.percent == 1f -> ScrobblingStatus.COMPLETED
|
||||||
ScrobblingStatus.READING
|
else -> ScrobblingStatus.READING
|
||||||
},
|
},
|
||||||
comment = prevInfo?.comment,
|
comment = prevInfo?.comment,
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -79,14 +79,16 @@
|
|||||||
|
|
||||||
<RatingBar
|
<RatingBar
|
||||||
android:id="@+id/ratingBar"
|
android:id="@+id/ratingBar"
|
||||||
android:layout_width="0dp"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_marginStart="16dp"
|
android:layout_marginStart="16dp"
|
||||||
android:layout_marginTop="6dp"
|
android:layout_marginTop="6dp"
|
||||||
android:layout_marginEnd="16dp"
|
android:layout_marginEnd="16dp"
|
||||||
android:numStars="5"
|
android:numStars="5"
|
||||||
android:stepSize="0.5"
|
android:stepSize="0.5"
|
||||||
|
app:layout_constrainedWidth="true"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
|
app:layout_constraintHorizontal_bias="0"
|
||||||
app:layout_constraintStart_toEndOf="@id/imageView_cover"
|
app:layout_constraintStart_toEndOf="@id/imageView_cover"
|
||||||
app:layout_constraintTop_toBottomOf="@id/textView_title"
|
app:layout_constraintTop_toBottomOf="@id/textView_title"
|
||||||
tools:rating="3.5"
|
tools:rating="3.5"
|
||||||
|
|||||||
Reference in New Issue
Block a user