|
21 | 21 | import org.quiltmc.enigma.gui.docker.ObfuscatedClassesDocker; |
22 | 22 | import org.quiltmc.enigma.gui.util.GridBagConstraintsBuilder; |
23 | 23 | import org.quiltmc.enigma.gui.util.ScaleUtil; |
| 24 | +import org.quiltmc.enigma.util.I18n; |
24 | 25 | import org.quiltmc.enigma.util.Utils; |
25 | 26 |
|
26 | 27 | import javax.annotation.Nullable; |
@@ -230,7 +231,10 @@ public void mousePressed(MouseEvent e) { |
230 | 231 | { |
231 | 232 | final Box parentLabelRow = Box.createHorizontalBox(); |
232 | 233 |
|
233 | | - final JLabel from = labelOf(inherited ? "inherited from" : "from", italEditorFont); |
| 234 | + final JLabel from = labelOf( |
| 235 | + I18n.translate(inherited ? "editor.tooltip.label.inherited_from" : "editor.tooltip.label.from"), |
| 236 | + italEditorFont |
| 237 | + ); |
234 | 238 | // the italics cause it to overlap with the colon if it has no right padding |
235 | 239 | from.setBorder(createEmptyBorder(0, 0, 0, 1)); |
236 | 240 | parentLabelRow.add(from); |
@@ -389,13 +393,15 @@ public void mouseClicked(MouseEvent e) { |
389 | 393 | .build() |
390 | 394 | ); |
391 | 395 |
|
392 | | - mainContent.add(labelOf("No source available", italEditorFont), GridBagConstraintsBuilder.create() |
393 | | - .pos(0, mainGridY++) |
394 | | - .weightX(1) |
395 | | - .fill(GridBagConstraints.HORIZONTAL) |
396 | | - .anchor(GridBagConstraints.LINE_START) |
397 | | - .insets(ROW_INNER_INSET, ROW_OUTER_INSET) |
398 | | - .build() |
| 396 | + mainContent.add( |
| 397 | + labelOf(I18n.translate("editor.tooltip.message.no_source"), italEditorFont), |
| 398 | + GridBagConstraintsBuilder.create() |
| 399 | + .pos(0, mainGridY++) |
| 400 | + .weightX(1) |
| 401 | + .fill(GridBagConstraints.HORIZONTAL) |
| 402 | + .anchor(GridBagConstraints.LINE_START) |
| 403 | + .insets(ROW_INNER_INSET, ROW_OUTER_INSET) |
| 404 | + .build() |
399 | 405 | ); |
400 | 406 | } |
401 | 407 | } |
|
0 commit comments