diff --git a/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/CalendarView.kt b/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/CalendarView.kt index 48a76578..21694ca3 100644 --- a/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/CalendarView.kt +++ b/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/CalendarView.kt @@ -137,9 +137,7 @@ class CalendarView( } private fun createDateTextView(dateModel: DateModel) = DateTextView( - context, - tmpHorizontal, - textHeight + context ).apply { text = dateModel.day setTextColor(ContextCompat.getColor(this.context, R.color.OnSurface)) @@ -151,9 +149,7 @@ class CalendarView( private fun createDateImgView(dateModel: DateModel) = DateImgView( context, dateModel, - requestManager, - tmpHorizontal, - tmpVertical - textHeight + requestManager ).apply { setPadding(IMG_PADDING) } diff --git a/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateImgView.kt b/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateImgView.kt index bfcc851a..ff6df057 100644 --- a/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateImgView.kt +++ b/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateImgView.kt @@ -13,17 +13,10 @@ import com.bumptech.glide.request.transition.DrawableCrossFadeFactory class DateImgView constructor( context: Context, var dateModel: DateModel, - private val requestManager: RequestManager, - private val staticWidth: Int, - private val staticHeight: Int + private val requestManager: RequestManager ) : AppCompatImageView(context) { private val factory = DrawableCrossFadeFactory.Builder().setCrossFadeEnabled(true).build() - - override fun onMeasure(widthMeasureSpec: Int, heightMeasureSpec: Int) { - setMeasuredDimension(staticWidth, staticHeight) - } - fun setVideoUrl(dateModel: DateModel) { this.dateModel = dateModel load(dateModel.videoUrl) diff --git a/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateTextView.kt b/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateTextView.kt index d40f0175..33c41a13 100644 --- a/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateTextView.kt +++ b/app/src/main/java/com/boostcamp/dailyfilm/presentation/calendar/custom/DateTextView.kt @@ -4,12 +4,5 @@ import android.content.Context import androidx.appcompat.widget.AppCompatTextView class DateTextView constructor( - context: Context, - private val staticWidth: Int, - private val staticHeight: Int, -) : AppCompatTextView(context) { - - override fun onMeasure(widthMeasureSpec: Int, heightMeasureSpec: Int) { - setMeasuredDimension(staticWidth, staticHeight) - } -} + context: Context +) : AppCompatTextView(context)