From 77f96d1955a52a65dd6b8f1b0b37930fbe90b898 Mon Sep 17 00:00:00 2001 From: Phillip Hsu Date: Sat, 6 May 2017 15:48:52 -0700 Subject: [PATCH] Refresh day picker view when min or max date is set. --- .../bottomsheetpickers/date/DatePickerDialog.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/bottomsheetpickers/src/main/java/com/philliphsu/bottomsheetpickers/date/DatePickerDialog.java b/bottomsheetpickers/src/main/java/com/philliphsu/bottomsheetpickers/date/DatePickerDialog.java index d1ce469..91b61c7 100644 --- a/bottomsheetpickers/src/main/java/com/philliphsu/bottomsheetpickers/date/DatePickerDialog.java +++ b/bottomsheetpickers/src/main/java/com/philliphsu/bottomsheetpickers/date/DatePickerDialog.java @@ -620,6 +620,10 @@ public void setYearRange(int startYear, int endYear) { */ public void setMinDate(Calendar calendar) { mMinDate = calendar; + + if (mDayPickerView != null) { + mDayPickerView.onChange(); + } } /** @@ -639,6 +643,10 @@ public Calendar getMinDate() { */ public void setMaxDate(Calendar calendar) { mMaxDate = calendar; + + if (mDayPickerView != null) { + mDayPickerView.onChange(); + } } /**