mirror of
https://github.com/trezor/trezor-firmware.git
synced 2025-01-12 00:10:58 +00:00
style(all): reformat with clang-format 13.0
This commit is contained in:
parent
0e505ec78b
commit
d656f88572
@ -288,15 +288,14 @@ void display_avatar(int x, int y, const void *data, uint32_t datalen,
|
||||
if (px >= x0 && px <= x1 && py >= y0 && py <= y1) {
|
||||
int d = (px - AVATAR_IMAGE_SIZE / 2) * (px - AVATAR_IMAGE_SIZE / 2) +
|
||||
(py - AVATAR_IMAGE_SIZE / 2) * (py - AVATAR_IMAGE_SIZE / 2);
|
||||
// inside border area
|
||||
if (d < AVATAR_BORDER_LOW) {
|
||||
// inside border area
|
||||
PIXELDATA((decomp_out[0] << 8) | decomp_out[1]);
|
||||
} else
|
||||
// outside border area
|
||||
if (d > AVATAR_BORDER_HIGH) {
|
||||
} else if (d > AVATAR_BORDER_HIGH) {
|
||||
// outside border area
|
||||
PIXELDATA(bgcolor);
|
||||
// border area
|
||||
} else {
|
||||
// border area
|
||||
#if AVATAR_ANTIALIAS
|
||||
d = 31 * (d - AVATAR_BORDER_LOW) /
|
||||
(AVATAR_BORDER_HIGH - AVATAR_BORDER_LOW);
|
||||
|
@ -223,9 +223,8 @@ int cryptoMessageVerify(const CoinInfo *coin, const uint8_t *message,
|
||||
len != address_prefix_bytes_len(coin->address_type) + 20) {
|
||||
return 2;
|
||||
}
|
||||
} else
|
||||
// segwit-in-p2sh
|
||||
if (signature[0] >= 35 && signature[0] <= 38) {
|
||||
} else if (signature[0] >= 35 && signature[0] <= 38) {
|
||||
// segwit-in-p2sh
|
||||
size_t len = base58_decode_check(address, coin->curve->hasher_base58,
|
||||
addr_raw, MAX_ADDR_RAW_SIZE);
|
||||
ecdsa_get_address_segwit_p2sh_raw(pubkey, coin->address_type_p2sh,
|
||||
@ -235,9 +234,8 @@ int cryptoMessageVerify(const CoinInfo *coin, const uint8_t *message,
|
||||
len != address_prefix_bytes_len(coin->address_type_p2sh) + 20) {
|
||||
return 2;
|
||||
}
|
||||
} else
|
||||
// segwit
|
||||
if (signature[0] >= 39 && signature[0] <= 42) {
|
||||
} else if (signature[0] >= 39 && signature[0] <= 42) {
|
||||
// segwit
|
||||
int witver = 0;
|
||||
size_t len = 0;
|
||||
if (!coin->bech32_prefix ||
|
||||
|
Loading…
Reference in New Issue
Block a user