Skip to content

Commit 8ddaa48

Browse files
committed
remove: 남은 시간 복구
1 parent d49a74e commit 8ddaa48

File tree

4 files changed

+26
-26
lines changed

4 files changed

+26
-26
lines changed

domain/usagestats/src/main/java/com/hmh/hamyeonham/usagestats/usecase/AddUsageGoalsUseCase.kt

Whitespace-only changes.

feature/main/src/main/java/com/hmh/hamyeonham/feature/main/home/UsageStaticsTotalViewHolder.kt

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -26,15 +26,15 @@ class UsageStaticsTotalViewHolder(
2626

2727
private fun bindUsageStaticsInfo(totalModel: HomeItem.TotalModel) {
2828
binding.run {
29-
// val totalTimeLeft =
30-
// if (totalModel.totalGoalTime > totalModel.totalTimeInForeground) totalModel.totalGoalTime - totalModel.totalTimeInForeground else 0
31-
//
32-
// tvTotalTimeLeft.text =
33-
// context.getSecondStrColoredString(
34-
// firstStr = convertMillisecondToString(totalTimeLeft),
35-
// secondStr = getString(context, R.string.all_left),
36-
// color = com.hmh.hamyeonham.core.designsystem.R.color.gray1,
37-
// )
29+
val totalTimeLeft =
30+
if (totalModel.totalGoalTime > totalModel.totalTimeInForeground) totalModel.totalGoalTime - totalModel.totalTimeInForeground else 0
31+
32+
tvTotalTimeLeft.text =
33+
context.getSecondStrColoredString(
34+
firstStr = convertMillisecondToString(totalTimeLeft),
35+
secondStr = getString(context, R.string.all_left),
36+
color = com.hmh.hamyeonham.core.designsystem.R.color.gray1,
37+
)
3838

3939
tvTotalUsage.text =
4040
context.getString(

feature/main/src/main/java/com/hmh/hamyeonham/feature/main/home/UsageStaticsViewHolder.kt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,12 @@ class UsageStaticsViewHolder(
4040
binding.run {
4141
pbAppUsage.progress = usageStatusAndGoal.usedPercentage
4242
tvGoalTime.text = convertTimeToString(usageStatusAndGoal.goalTimeInMinute)
43-
// tvAppTimeLeft.text =
44-
// context.getSecondStrColoredString(
45-
// firstStr = convertTimeToString(usageStatusAndGoal.timeLeftInMinute),
46-
// secondStr = getString(context, R.string.all_left),
47-
// color = com.hmh.hamyeonham.core.designsystem.R.color.gray1,
48-
// )
43+
tvAppTimeLeft.text =
44+
context.getSecondStrColoredString(
45+
firstStr = convertTimeToString(usageStatusAndGoal.timeLeftInMinute),
46+
secondStr = getString(context, R.string.all_left),
47+
color = com.hmh.hamyeonham.core.designsystem.R.color.gray1,
48+
)
4949
}
5050
}
5151
}

feature/main/src/main/res/layout/item_usagestatic.xml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -53,16 +53,16 @@
5353
app:layout_constraintBottom_toBottomOf="@id/iv_appicon"
5454
app:layout_constraintStart_toStartOf="@id/tv_appname" />
5555

56-
<!-- <TextView-->
57-
<!-- android:id="@+id/tv_app_time_left"-->
58-
<!-- android:layout_width="wrap_content"-->
59-
<!-- android:layout_height="wrap_content"-->
60-
<!-- android:layout_marginEnd="20dp"-->
61-
<!-- tools:text="1시간 남음"-->
62-
<!-- android:textAppearance="?textAppearanceTitleMedium"-->
63-
<!-- android:textColor="?white_text"-->
64-
<!-- app:layout_constraintBottom_toBottomOf="@id/pb_app_usage"-->
65-
<!-- app:layout_constraintEnd_toEndOf="@id/pb_app_usage"-->
66-
<!-- app:layout_constraintTop_toTopOf="@id/pb_app_usage" />-->
56+
<TextView
57+
android:id="@+id/tv_app_time_left"
58+
android:layout_width="wrap_content"
59+
android:layout_height="wrap_content"
60+
android:layout_marginEnd="20dp"
61+
tools:text="1시간 남음"
62+
android:textAppearance="?textAppearanceTitleMedium"
63+
android:textColor="?white_text"
64+
app:layout_constraintBottom_toBottomOf="@id/pb_app_usage"
65+
app:layout_constraintEnd_toEndOf="@id/pb_app_usage"
66+
app:layout_constraintTop_toTopOf="@id/pb_app_usage" />
6767

6868
</androidx.constraintlayout.widget.ConstraintLayout>

0 commit comments

Comments
 (0)