mirror of
https://github.com/Ranchero-Software/NetNewsWire
synced 2026-11-29 16:54:12 +00:00
Fixed bug where unread indicator took precedence over star.
This commit is contained in:
1 parent
b49adcd5c5
commit
50bd976b33
1 file changed
+10
-10
@@ -118,16 +118,7 @@ class MainTimelineCollectionViewCell: UICollectionViewCell {
|
||||
}
|
||||
|
||||
private func updateIndicatorView(_ state: UICellConfigurationState) {
|
||||
if cellData.read == false {
|
||||
if indicatorView.alpha == 0.0 {
|
||||
indicatorView.alpha = 1.0
|
||||
}
|
||||
UIView.animate(withDuration: Self.indicatorAnimationDuration) {
|
||||
self.indicatorView.iconImage = Assets.Images.unreadCellIndicator
|
||||
self.indicatorView.tintColor = (state.isSelected && !state.isSwiped) ? .white : Assets.Colors.secondaryAccent
|
||||
}
|
||||
return
|
||||
} else if cellData.starred {
|
||||
if cellData.starred {
|
||||
if indicatorView.alpha == 0.0 {
|
||||
indicatorView.alpha = 1.0
|
||||
}
|
||||
@@ -136,6 +127,15 @@ class MainTimelineCollectionViewCell: UICollectionViewCell {
|
||||
self.indicatorView.tintColor = (state.isSelected && !state.isSwiped) ? .white : Assets.Colors.star
|
||||
}
|
||||
return
|
||||
} else if cellData.read == false {
|
||||
if indicatorView.alpha == 0.0 {
|
||||
indicatorView.alpha = 1.0
|
||||
}
|
||||
UIView.animate(withDuration: Self.indicatorAnimationDuration) {
|
||||
self.indicatorView.iconImage = Assets.Images.unreadCellIndicator
|
||||
self.indicatorView.tintColor = (state.isSelected && !state.isSwiped) ? .white : Assets.Colors.secondaryAccent
|
||||
}
|
||||
return
|
||||
} else if indicatorView.alpha == 1.0 {
|
||||
UIView.animate(withDuration: Self.indicatorAnimationDuration) {
|
||||
self.indicatorView.alpha = 0.0
|
||||
|
||||
Reference in new issue
Block a user