Skip to content

Commit

Permalink
Issue #22: Add l10n to application
Browse files Browse the repository at this point in the history
* Add new keys.
  • Loading branch information
ottlinger committed Feb 4, 2016
1 parent c5fc2b2 commit 53775b5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 7 deletions.
8 changes: 4 additions & 4 deletions src/main/java/de/aikiit/spamprotector/GUI.java
Original file line number Diff line number Diff line change
Expand Up @@ -84,13 +84,13 @@ private void init(final boolean isApplet) {
output.setPreferredSize(BOX_DIMENSION);

// read input field
final JButton start = new JButton("--->");
start.setMnemonic('U');
final JButton start = new JButton(getBundleString("spamschutz.ui.button.rtl"));
start.setMnemonic(getBundleString("spamschutz.ui.button.rtl.mnemonic").charAt(0));
start.addActionListener(e -> output.setText(SpamProtector.toEncoded(input.getText())));

// read output field
final JButton revert = new JButton("<---");
revert.setMnemonic('v');
final JButton revert = new JButton(getBundleString("spamschutz.ui.button.ltr"));
revert.setMnemonic(getBundleString("spamschutz.ui.button.ltr.mnemonic").charAt(0));
revert.addActionListener(e -> input.setText(SpamProtector.toPlain(output.getText())));

final JButton reset = new JButton(getBundleString("spamschutz.ui.reset"));
Expand Down
9 changes: 6 additions & 3 deletions src/main/resources/spamprotector.properties
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,11 @@ spamschutz.ui.output.mnemonic=2
spamschutz.ui.input=1: Eingabe:
spamschutz.ui.input.mnemonic=1
spamschutz.ui.default.output=Bitte Text eingeben und Button bet\u00e4tigen!
spamschutz.ui.button.rtl=---\u003e
spamschutz.ui.button.rtl.mnemonic=>
spamschutz.ui.button.ltr=\u003e---
spamschutz.ui.button.ltr.mnemonic=-

# ProgressBar.java
fotorenamer.ui.progress=Fortschritt
fotorenamer.ui.progress.title=Dateien werden umbenannt...

# ImageDirectorySelector.java
fotorenamer.ui.selector.title=Verzeichnisauswahl
Expand Down Expand Up @@ -74,4 +75,6 @@ spamschutz.test.umlauts=\u00df\u00e4\u00fc
# szett = \u00df
# ae = \u00e4
# ue = \u00fc
# > = \u003e
# < = \u003c

0 comments on commit 53775b5

Please sign in to comment.