Fix: Restore the behaviour when entering numbers in query windows: clamp integers out of range to the maximum valid value.
This commit is contained in:
@@ -748,7 +748,7 @@ struct TimetableWindow : Window {
|
||||
if (!str.has_value()) return;
|
||||
|
||||
const Vehicle *v = this->vehicle;
|
||||
uint64_t val = ParseInteger<uint64_t>(*str).value_or(0);
|
||||
uint64_t val = ParseInteger<uint64_t>(*str, 10, true).value_or(0);
|
||||
auto [order_id, mtf] = PackTimetableArgs(v, this->sel_index, query_widget == WID_VT_CHANGE_SPEED);
|
||||
|
||||
switch (query_widget) {
|
||||
|
||||
Reference in New Issue
Block a user