-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature/store_album_cover] 앨범커버 이미지 리소스 변경 로직 #99
Conversation
val albumCover = when (albumItem.albumCover) { | ||
1 -> R.drawable.ic_album_cover_friends | ||
2 -> R.drawable.ic_album_cover_love | ||
3 -> R.drawable.ic_album_cover_myalbum | ||
4 -> R.drawable.ic_album_cover_collectbook | ||
else -> R.drawable.ic_album_cover_myalbum | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이거 구현한거 있어 유틸쪽에 구현되어있음
fun Int.toCoverDrawable() = when (this) {
0 -> R.drawable.ic_album_cover_friends
1 -> R.drawable.ic_album_cover_love
2 -> R.drawable.ic_album_cover_myalbum
3 -> R.drawable.ic_album_cover_collectbook
else -> throw IllegalArgumentException("Invalid album cover id $this")
}
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
와우 감사합니다!!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
리뷰만 반영해주고 바로 머지
이슈 코드
📸 스크린샷
🍀 관련 이슈