Skip to content

Commit

Permalink
Enable German translations. Fix dictionary swapping problems so it is
Browse files Browse the repository at this point in the history
reliable.
  • Loading branch information
biddster committed Apr 21, 2014
1 parent 4c45526 commit cdcf07a
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 7 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<groupId>uk.co.biddell</groupId>
<artifactId>DiceWare</artifactId>
<packaging>jar</packaging>
<version>1.1.1</version>
<version>1.1.2</version>
<name>DiceWare</name>
<url>http://maven.apache.org</url>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,7 @@ public LengthType getLengthType() {
public DiceWare() throws IOException, NoSuchAlgorithmException {
dictionaries.add(new Dictionary("DiceWare - United Kingdon", "/beale.txt"));
dictionaries.add(new Dictionary("DiceWare - United States", "/diceware.txt"));
// dictionaries.add(new Dictionary("DiceWare - German",
// "/diceware_german.txt"));
dictionaries.add(new Dictionary("DiceWare - German", "/diceware_german.txt"));
dictionaries.add(new Dictionary("DiceWare - Spanish", "/DW-Espanol-1.txt"));
dictionaries.add(new Dictionary("DiceWare - Japanese", "/diceware_jp.txt"));
dictionaries.add(new Dictionary("DiceWare - Dutch", "/DicewareDutch.txt"));
Expand Down
6 changes: 2 additions & 4 deletions src/main/java/uk/co/biddell/diceware/ui/DiceWarePanel.java
Original file line number Diff line number Diff line change
Expand Up @@ -170,15 +170,13 @@ public final void stateChanged(final ChangeEvent changeEvent) {

@Override
public final void actionPerformed(final ActionEvent actionEvent) {
if (actionEvent.getSource() == dictionaryCombo || actionEvent.getSource() == typeCombo) {
create();
} else if (actionEvent.getSource() == nextButton) {
if (actionEvent.getSource() == typeCombo || actionEvent.getSource() == nextButton) {
create();
} else if (actionEvent.getSource() == copyButton) {
clipboard.setContents(new StringSelection(diceWords.toString()), this);
} else if (actionEvent.getSource() == dictionaryCombo) {
diceWare.setDictionary((Dictionary) dictionaryCombo.getSelectedItem());
nextButton.doClick();
create();
}
}

Expand Down
Binary file modified src/main/resources/diceware_german.txt
Binary file not shown.

0 comments on commit cdcf07a

Please sign in to comment.