What changed, and why it matters
This commit changes several Bitcoin-related user-interface labels from translated text to fixed English strings. It removes translation entries for technical terms like 'Outpoint', 'Input Reference', 'Unknown', 'Input Ref', and 'Sighash' so they always display in English regardless of the user's language setting. This is a localization/usability fix, not a security patch.
No security action required. Treat as a routine localization change.
Security signals we found
No strong security signals were identified.
Evidence from the diff
The patch replaces _() (internationalization macro) calls in src/ui/gui_chain/gui_btc.c with hard-coded English strings for Bitcoin UI labels. It also removes the corresponding rows from src/ui/lv_i18n/data.csv and updates the compiled translation tables in src/ui/lv_i18n/lv_i18n.c so that non-English locales now map these keys to the English words. No cryptographic, parsing, or transaction-handling code is modified.
Changed components
src/ui/gui_chain/gui_btc.csrc/ui/lv_i18n/data.csvsrc/ui/lv_i18n/lv_i18n.cInspect captured patch +12 / −17
diff --git a/src/ui/gui_chain/gui_btc.c b/src/ui/gui_chain/gui_btc.c
index 46aa4ca..baecf50 100644
--- a/src/ui/gui_chain/gui_btc.c
+++ b/src/ui/gui_chain/gui_btc.c
@@ -792,10 +792,10 @@ static void OpenInputRefQrCode(lv_event_t *e)
char url[128] = {0};
char outpoint[160] = {0};
snprintf_s(url, sizeof(url), "https://mempool.space/tx/%s", inputData->input_txid);
- snprintf_s(outpoint, sizeof(outpoint), "%s:\n%s:%u", _("btc_outpoint"), inputData->input_txid,
+ snprintf_s(outpoint, sizeof(outpoint), "%s:\n%s:%u", "Outpoint", inputData->input_txid,
inputData->input_vout);
- GuiQRCodeHintBoxOpenCompact(url, _("btc_input_reference"), outpoint);
+ GuiQRCodeHintBoxOpenCompact(url, "Input Reference", outpoint);
}
static bool IsAvalancheTx(DisplayTx *data)
@@ -856,7 +856,7 @@ static bool isSat = false;
static void FormatFeeText(char *out, size_t outLen, const char *feeText, bool isLowerBound, bool isUnknown)
{
if (isUnknown) {
- strcpy_s(out, outLen, _("btc_fee_unknown"));
+ strcpy_s(out, outLen, "Unknown");
} else if (isLowerBound) {
snprintf_s(out, outLen, ">= %s", feeText);
} else {
@@ -936,7 +936,7 @@ static lv_obj_t *CreateSighashWarningView(lv_obj_t *parent, lv_obj_t *lastView,
lv_obj_t *warningIcon = GuiCreateImg(warningView, &imgWarningRed);
lv_obj_align(warningIcon, LV_ALIGN_TOP_LEFT, 24, 24);
- lv_obj_t *titleLabel = GuiCreateTextLabel(warningView, _("Warning"));
+ lv_obj_t *titleLabel = GuiCreateTextLabel(warningView, "Warning");
lv_obj_set_style_text_color(titleLabel, lv_color_hex(0xF55831), LV_PART_MAIN);
lv_obj_align_to(titleLabel, warningIcon, LV_ALIGN_OUT_RIGHT_MID, 8, 0);
@@ -962,7 +962,7 @@ static lv_obj_t *CreateInputRefView(lv_obj_t *parent, lv_obj_t *lastView, Displa
lv_obj_align_to(inputRefContainer, lastView, LV_ALIGN_OUT_BOTTOM_LEFT, 0, 12);
lv_obj_add_event_cb(inputRefContainer, OpenInputRefQrCode, LV_EVENT_CLICKED, inputData);
- lv_obj_t *inputRefLabel = GuiCreateIllustrateLabel(inputRefContainer, _("btc_input_ref"));
+ lv_obj_t *inputRefLabel = GuiCreateIllustrateLabel(inputRefContainer, "Input Ref");
lv_obj_set_style_text_color(inputRefLabel, lv_color_hex(0x1BE0C6), LV_PART_MAIN);
lv_obj_align(inputRefLabel, LV_ALIGN_LEFT_MID, 0, 0);
lv_obj_clear_flag(inputRefLabel, LV_OBJ_FLAG_CLICKABLE);
@@ -1062,7 +1062,7 @@ static lv_obj_t *CreateSighashView(lv_obj_t *parent, char *sighashType, lv_obj_t
}
char *displayText = (char *)GetSighashDisplayText(sighashType);
- return CreateTransactionItemView(parent, _("btc_sighash"), displayText, lastView);
+ return CreateTransactionItemView(parent, "Sighash", displayText, lastView);
}
static lv_obj_t *CreateOverviewFromView(lv_obj_t *parent, DisplayTxOverview *overviewData, lv_obj_t *lastView)
diff --git a/src/ui/lv_i18n/data.csv b/src/ui/lv_i18n/data.csv
index d548c74..ce48022 100644
--- a/src/ui/lv_i18n/data.csv
+++ b/src/ui/lv_i18n/data.csv
@@ -1063,8 +1063,3 @@ Wallet Profile,24,wallet_profile_mid_btn,Wallet Profile,Профиль коше
,20,btc_check_input_value_hint,"Please confirm each input value is correct.","Пожалуйста, проверьте корректность суммы каждого входа.","각 입력 금액이 올바른지 확인해 주세요.","请确认每个输入金额都正确。","Confirma que el valor de cada entrada sea correcto.","Bitte bestätigen Sie, dass jeder Eingabewert korrekt ist.","各入力金額が正しいことを確認してください。"
,20,btc_sighash_single_warning,"Only the corresponding output is locked. Other outputs may be changed after signing.","Зафиксирован только соответствующий выход. Другие выходы могут быть изменены после подписания.","해당 출력만 고정됩니다. 서명 후 다른 출력은 변경될 수 있습니다.","只有对应的输出被锁定。签名后其他输出仍可能被更改。","Solo la salida correspondiente está bloqueada. Las otras salidas pueden cambiarse después de firmar.","Nur der entsprechende Output ist festgelegt. Andere Outputs können nach dem Signieren geändert werden.","対応する出力のみが固定されます。署名後に他の出力が変更される可能性があります。"
,20,btc_sighash_none_warning,"Outputs are not locked and this signature may be reused with different outputs.","Выходы не зафиксированы и эта подпись может быть повторно использована с другими выходами.","출력이 고정되지 않으며 이 서명은 다른 출력과 함께 재사용될 수 있습니다.","输出未被锁定,此签名可能被复用于不同的输出。","Las salidas no están bloqueadas y esta firma puede reutilizarse con salidas diferentes.","Outputs sind nicht festgelegt und diese Signatur kann mit anderen Outputs wiederverwendet werden.","出力は固定されておらず、この署名は別の出力で再利用される可能性があります。"
-,24,btc_input_reference,"Input Reference","Ссылка на вход","입력 참조","输入引用","Referencia de entrada","Input-Referenz","入力参照"
-,24,btc_input_ref,"Input Ref","Ссылка входа","입력 참조","输入引用","Ref. entrada","Input-Ref.","入力参照"
-,24,btc_sighash,"Sighash","Sighash","Sighash","签名哈希","Sighash","Sighash","Sighash"
-,24,btc_outpoint,"Outpoint","Выходная точка","아웃포인트","输出点","Outpoint","Outpoint","アウトポイント"
-,24,btc_fee_unknown,"Unknown","Неизвестно","알 수 없음","未知","Desconocido","Unbekannt","不明"
diff --git a/src/ui/lv_i18n/lv_i18n.c b/src/ui/lv_i18n/lv_i18n.c
index 8b4e405..269e1a5 100644
--- a/src/ui/lv_i18n/lv_i18n.c
+++ b/src/ui/lv_i18n/lv_i18n.c
@@ -1120,7 +1120,7 @@ const static lv_i18n_phrase_t de_singulars[] = {
{"boot_version_not_match_title", "Sicherheitsbenachrichtigung"},
{"btc_avalanche_notice", "Diese Transaktion verwendet eine Avalanche BTC-Adresse. Überprüfen Sie alle Details sorgfältig, um Fehler oder Vermögensverluste zu vermeiden."},
{"btc_check_input_value_hint", "Bitte bestätigen Sie, dass jeder Eingabewert korrekt ist."},
- {"btc_fee_unknown", "Unbekannt"},
+ {"btc_fee_unknown", "Unknown"},
{"btc_input_ref", "Input-Ref."},
{"btc_input_reference", "Input-Referenz"},
{"btc_outpoint", "Outpoint"},
@@ -2076,7 +2076,7 @@ const static lv_i18n_phrase_t es_singulars[] = {
{"boot_version_not_match_title", "Aviso de seguridad"},
{"btc_avalanche_notice", "Esta transacción utiliza una dirección BTC de Avalanche. Verifique cuidadosamente todos los detalles para evitar errores o pérdida de activos."},
{"btc_check_input_value_hint", "Confirma que el valor de cada entrada sea correcto."},
- {"btc_fee_unknown", "Desconocido"},
+ {"btc_fee_unknown", "Unknown"},
{"btc_input_ref", "Ref. entrada"},
{"btc_input_reference", "Referencia de entrada"},
{"btc_outpoint", "Outpoint"},
@@ -3029,7 +3029,7 @@ const static lv_i18n_phrase_t ja_singulars[] = {
{"boot_version_not_match_title", "セキュリティ通知"},
{"btc_avalanche_notice", "このトランザクションはAvalanche BTCアドレスを使用しています。エラーや資産の損失を避けるため、すべての詳細を慎重に確認してください。"},
{"btc_check_input_value_hint", "各入力金額が正しいことを確認してください。"},
- {"btc_fee_unknown", "不明"},
+ {"btc_fee_unknown", "Unknown"},
{"btc_input_ref", "入力参照"},
{"btc_input_reference", "入力参照"},
{"btc_outpoint", "アウトポイント"},
@@ -3980,7 +3980,7 @@ const static lv_i18n_phrase_t ko_singulars[] = {
{"boot_version_not_match_title", "보안 알림"},
{"btc_avalanche_notice", "이 트랜잭션은 Avalanche BTC 주소를 사용합니다. 오류나 자산 손실을 방지하기 위해 모든 세부 사항을 주의 깊게 확인하십시오."},
{"btc_check_input_value_hint", "각 입력 금액이 올바른지 확인해 주세요."},
- {"btc_fee_unknown", "알 수 없음"},
+ {"btc_fee_unknown", "Unknown"},
{"btc_input_ref", "입력 참조"},
{"btc_input_reference", "입력 참조"},
{"btc_outpoint", "아웃포인트"},
@@ -4931,7 +4931,7 @@ const static lv_i18n_phrase_t ru_singulars[] = {
{"boot_version_not_match_title", "Безопасность уведомление"},
{"btc_avalanche_notice", "Эта транзакция использует адрес Avalanche BTC. Внимательно проверьте все детали, чтобы избежать ошибок или потери активов."},
{"btc_check_input_value_hint", "Пожалуйста, проверьте корректность суммы каждого входа."},
- {"btc_fee_unknown", "Неизвестно"},
+ {"btc_fee_unknown", "Unknown"},
{"btc_input_ref", "Ссылка входа"},
{"btc_input_reference", "Ссылка на вход"},
{"btc_outpoint", "Выходная точка"},
@@ -5890,7 +5890,7 @@ const static lv_i18n_phrase_t zh_cn_singulars[] = {
{"boot_version_not_match_title", "安全通知"},
{"btc_avalanche_notice", "此交易使用Avalanche BTC地址。请仔细验证所有详细信息,以避免错误或资产损失。"},
{"btc_check_input_value_hint", "请确认每个输入金额都正确。"},
- {"btc_fee_unknown", "未知"},
+ {"btc_fee_unknown", "Unknown"},
{"btc_input_ref", "输入引用"},
{"btc_input_reference", "输入引用"},
{"btc_outpoint", "输出点"},
Why this scored 19/100
Community notes
Notes can correct, qualify, or add evidence to the AI analysis. Every note shown here has been validated by a human moderator.
The AI analysis stands alone for now. Submit a note if you can add evidence or important context.