Skip to content

Commit bdb5965

Browse files
AvamanderJF002
authored andcommitted
static_cast cleanup
1 parent 2f479e5 commit bdb5965

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/components/battery/BatteryController.cpp

+1-1
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ Battery::Battery() {
1414
}
1515

1616
void Battery::Init() {
17-
nrf_gpio_cfg_input(chargingPin, (nrf_gpio_pin_pull_t) GPIO_PIN_CNF_PULL_Pullup);
17+
nrf_gpio_cfg_input(chargingPin, static_cast<nrf_gpio_pin_pull_t> GPIO_PIN_CNF_PULL_Pullup);
1818
}
1919

2020
void Battery::Update() {

src/displayapp/screens/SystemInfo.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -203,11 +203,11 @@ std::unique_ptr<Screen> SystemInfo::CreateScreen3() {
203203
bleAddr[2],
204204
bleAddr[1],
205205
bleAddr[0],
206-
(int) mon.total_size - mon.free_size,
206+
static_cast<int>(mon.total_size - mon.free_size),
207207
mon.used_pct,
208208
mon.max_used,
209209
mon.frag_pct,
210-
(int) mon.free_biggest_size,
210+
static_cast<int>(mon.free_biggest_size),
211211
0);
212212
lv_obj_align(label, lv_scr_act(), LV_ALIGN_CENTER, 0, 0);
213213
return std::make_unique<Screens::Label>(2, 5, app, label);

0 commit comments

Comments
 (0)