egui_extras date picker: fix Feb 29 crash (#1571)
This commit is contained in:
parent
32b4781da2
commit
d3af3a6de1
1 changed files with 6 additions and 0 deletions
|
@ -86,6 +86,9 @@ impl<'a> DatePickerPopup<'a> {
|
||||||
)
|
)
|
||||||
.changed()
|
.changed()
|
||||||
{
|
{
|
||||||
|
popup_state.day = popup_state
|
||||||
|
.day
|
||||||
|
.min(popup_state.last_day_of_month());
|
||||||
ui.memory()
|
ui.memory()
|
||||||
.data
|
.data
|
||||||
.insert_persisted(id, popup_state.clone());
|
.insert_persisted(id, popup_state.clone());
|
||||||
|
@ -106,6 +109,9 @@ impl<'a> DatePickerPopup<'a> {
|
||||||
)
|
)
|
||||||
.changed()
|
.changed()
|
||||||
{
|
{
|
||||||
|
popup_state.day = popup_state
|
||||||
|
.day
|
||||||
|
.min(popup_state.last_day_of_month());
|
||||||
ui.memory()
|
ui.memory()
|
||||||
.data
|
.data
|
||||||
.insert_persisted(id, popup_state.clone());
|
.insert_persisted(id, popup_state.clone());
|
||||||
|
|
Loading…
Reference in a new issue