chore: Apply code formatting on entire codebase for consistent style

This commit is contained in:
icex2
2023-04-06 15:39:53 +02:00
committed by icex2
parent a1a849aef3
commit 031836ef0e
186 changed files with 2446 additions and 1979 deletions
+4 -4
View File
@@ -65,8 +65,8 @@ bool hid_report_out_set_bit(
uint16_t usage_hi;
uint16_t usage_lo;
usage_hi = (uint16_t)(usage >> 16);
usage_lo = (uint16_t)(usage >> 0);
usage_hi = (uint16_t) (usage >> 16);
usage_lo = (uint16_t) (usage >> 0);
count = 1;
if (value) {
@@ -118,8 +118,8 @@ bool hid_report_out_set_value(
uint16_t usage_hi;
uint16_t usage_lo;
usage_hi = (uint16_t)(usage >> 16);
usage_lo = (uint16_t)(usage >> 0);
usage_hi = (uint16_t) (usage >> 16);
usage_lo = (uint16_t) (usage >> 0);
status = HidP_SetUsageValue(
HidP_Output,
+4 -4
View File
@@ -202,9 +202,9 @@ static void analog_mapping_update(struct analog_mapping *am)
if (am->absolute) {
tmp = (value - am->affine_bias) / am->affine_scale;
am->pos = (uint8_t)((tmp + 0.5) * 256.0);
am->pos = (uint8_t) ((tmp + 0.5) * 256.0);
} else {
am->pos += (int8_t)(value * exp(am->sensitivity / 256.0));
am->pos += (int8_t) (value * exp(am->sensitivity / 256.0));
}
}
@@ -306,7 +306,7 @@ static void light_mapping_send(struct light_mapping *lm, const struct mapper *m)
intensity = m->lights[lm->game_light];
tmp = (intensity / 256.0) * lm->affine_scale;
value = (int32_t)(tmp + 0.5) + lm->affine_bias;
value = (int32_t) (tmp + 0.5) + lm->affine_bias;
hid_stub_set_light(lm->dest.hid, lm->dest.light_no, value);
}
@@ -432,7 +432,7 @@ uint8_t mapper_impl_get_npages(struct mapper *m)
}
}
return (uint8_t)(max_page + 1);
return (uint8_t) (max_page + 1);
}
action_iter_t mapper_impl_iterate_actions(struct mapper *m)