-
Notifications
You must be signed in to change notification settings - Fork 2
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
[REFACTOR/#185] OurTodo, MyTodo 뷰 / 코드 리팩토링만 #186
Conversation
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.
확장함수로 바꿔준 거 너무 깔꼼하고 보기 좋습니당 리팩까지 최고~!
MyTodoCreateActivity.createIntent( | ||
requireContext(), | ||
viewModel.tripId, | ||
viewModel.participantId | ||
).apply { startActivity(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.
저도 이 방법 알고는 감탄했는데 아주 굿이에요
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.
...미쳤다!!>...저도 이거 이용해서 리팩해볼게요 역시 그는 김상호...
title = todo.value.orEmpty(), | ||
endDate = endDate.value.orEmpty(), |
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.
아하 이렇게 바꿔줄 수 있군여
when { | ||
isCompleted -> { | ||
setTextColor(binding.root.context.colorOf(R.color.gray_300)) | ||
setBackgroundResource(R.drawable.shape_rect_2_gray300_line) | ||
} | ||
|
||
item.isOwner -> { | ||
setTextColor(binding.root.context.colorOf(R.color.red_500)) | ||
isSelected = true | ||
} |
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.
if문 말고 이렇게 바꿀 수도 있군용
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.
아주 굿이에요~
MyTodoCreateActivity.createIntent( | ||
requireContext(), | ||
viewModel.tripId, | ||
viewModel.participantId | ||
).apply { startActivity(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.
저도 이 방법 알고는 감탄했는데 아주 굿이에요
tvOurTodoItemTitle.setTextColor(binding.root.context.colorOf(R.color.gray_300)) | ||
tvOurTodoItemDate.setTextColor(binding.root.context.colorOf(R.color.gray_200)) | ||
} else { | ||
tvOurTodoItemTitle.setTextColor(ContextCompat.getColor(binding.root.context,R.color.black_000)) | ||
tvOurTodoItemDate.setTextColor(ContextCompat.getColor(binding.root.context,R.color.gray_300)) | ||
tvOurTodoItemTitle.setTextColor(binding.root.context.colorOf(R.color.black_000)) | ||
tvOurTodoItemDate.setTextColor(binding.root.context.colorOf(R.color.gray_300)) |
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.
...멋지다....앱잼 끝난 지 이틀도 안됐는데 리팩하는 그.........멋지다 배워갑니다 👍👍👍👍👍👍👍👍👍👍
MyTodoCreateActivity.createIntent( | ||
requireContext(), | ||
viewModel.tripId, | ||
viewModel.participantId | ||
).apply { startActivity(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.
...미쳤다!!>...저도 이거 이용해서 리팩해볼게요 역시 그는 김상호...
tvMyTodoItemTitle.setTextColor(binding.root.context.colorOf(R.color.gray_300)) | ||
tvMyTodoItemDate.setTextColor(binding.root.context.colorOf(R.color.gray_200)) |
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.
확장함수 야무지다!!
…into refactor/#185-todo
⛳️ Work Description
val inflater by lazy { LayoutInflater.from(parent.context) }
활용📢 To Reviewers