Skip to content

Commit

Permalink
Fixed text input on 24hour time picker (#5723)
Browse files Browse the repository at this point in the history
  • Loading branch information
FloVanGH authored Jul 31, 2024
1 parent 34f1a99 commit 9b7397f
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions internal/compiler/widgets/common/time-picker-base.slint
Original file line number Diff line number Diff line change
Expand Up @@ -511,11 +511,8 @@ export component TimePickerBase {
if !root.selection-mode {
return;
}
if root.use-24-hour-format {
root.update-time(root.time-picker-hour <= 23 ? root.time-picker-hour : 23, root.time-picker-minute <= 59 ? root.time-picker-minute : 59);
}

root.update-time(root.time-picker-hour <= 12 ? root.time-picker-hour : 12, root.time-picker-minute <= 59 ? root.time-picker-minute : 59);
root.update-time(min(root.time-picker-hour, root.use-24-hour-format ? 23 : 12), min(root.time-picker-minute, 59));
}

changed time => {
Expand Down

0 comments on commit 9b7397f

Please sign in to comment.