Skip to content

Commit

Permalink
Use localized algorithm names in encryption tooltip
Browse files Browse the repository at this point in the history
  • Loading branch information
Aizistral committed Oct 29, 2024
1 parent e3a0dbd commit c3273aa
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,10 @@ public String getName() {
return this.name;
}

public String getNameLocalizationKey() {
return "algorithm.nochatreports." + this.id + ".name";
}

public abstract String getRandomKey();

public abstract String getDefaultKey();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ private GuiMessage modifyGUIMessage(GuiMessage msg) {

if (NCRConfig.getEncryption().showEncryptionIndicators()) {
Component tooltip = Component.empty().append(Component.translatable("tag.nochatreports.encrypted",
Component.literal(NCRConfig.getEncryption().getAlgorithm().getName())
Component.translatable(NCRConfig.getEncryption().getAlgorithm().getNameLocalizationKey())
.withStyle(ChatFormatting.BOLD))).append(CommonComponents.NEW_LINE).append(
Component.translatable("tag.nochatreports.encrypted_original",
this.lastMessageOriginal));
Expand Down

0 comments on commit c3273aa

Please sign in to comment.