Skip to content

Commit

Permalink
新增日期农历信息
Browse files Browse the repository at this point in the history
  • Loading branch information
loper7 committed Dec 6, 2021
1 parent 56cdd0b commit eef1882
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import android.content.Context
import android.graphics.Color
import android.graphics.drawable.GradientDrawable
import android.os.Bundle
import android.text.Html
import android.util.Log
import android.view.View
import android.widget.FrameLayout
Expand Down Expand Up @@ -225,7 +226,8 @@ class CardDatePickerDialog(context: Context) : BottomSheetDialog(context), View.
calendar.clear()
calendar.timeInMillis = millisecond
Lunar.getInstance(calendar)?.apply {
tv_choose_date?.text = "农历 $yearName $monthName $dayName ${StringUtils.getWeek(millisecond)}"
var str = "<font color='#999999'>农历</font>&nbsp;&nbsp;&nbsp;<font color='#333333'>$yearName $monthName $dayName<font/>&nbsp;&nbsp;&nbsp;<font color='#999999'>${StringUtils.getWeek(millisecond)}</font>"
tv_choose_date?.text = Html.fromHtml(str)
}
}
}
Expand Down

0 comments on commit eef1882

Please sign in to comment.