mirror of
https://github.com/eried/portapack-mayhem.git
synced 2025-06-27 16:17:31 -04:00
Remove a lot of static_cast<>s involving UI structs.
Also starting to get religion on using unsigned integers only when I want their wrapping/modulus behavior.
This commit is contained in:
parent
4c8550bb7d
commit
3f94591083
11 changed files with 28 additions and 76 deletions
|
@ -523,9 +523,9 @@ bool ImageButton::on_touch(const TouchEvent event) {
|
|||
|
||||
OptionsField::OptionsField(
|
||||
Point parent_pos,
|
||||
size_t length,
|
||||
int length,
|
||||
options_t options
|
||||
) : Widget { { parent_pos, { static_cast<ui::Dim>(8 * length), 16 } } },
|
||||
) : Widget { { parent_pos, { 8 * length, 16 } } },
|
||||
length_ { length },
|
||||
options { options }
|
||||
{
|
||||
|
@ -594,11 +594,11 @@ bool OptionsField::on_touch(const TouchEvent event) {
|
|||
|
||||
NumberField::NumberField(
|
||||
Point parent_pos,
|
||||
size_t length,
|
||||
int length,
|
||||
range_t range,
|
||||
int32_t step,
|
||||
char fill_char
|
||||
) : Widget { { parent_pos, { static_cast<ui::Dim>(8 * length), 16 } } },
|
||||
) : Widget { { parent_pos, { 8 * length, 16 } } },
|
||||
range { range },
|
||||
step { step },
|
||||
length_ { length },
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue