Skip to content

Commit

Permalink
Update configuration parsing
Browse files Browse the repository at this point in the history
  • Loading branch information
emmanue1 committed Dec 25, 2019
1 parent 7bca465 commit a0fa89c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public ClassFileDecompilerPreferencesProvider() {
@Override
public void loadPreferences(Map<String, String> preferences) {
escapeUnicodeCharactersCheckBox.setSelected("true".equals(preferences.get(ESCAPE_UNICODE_CHARACTERS)));
realignLineNumbersCheckBox.setSelected(!"false".equals(preferences.get(REALIGN_LINE_NUMBERS)));
realignLineNumbersCheckBox.setSelected("true".equals(preferences.get(REALIGN_LINE_NUMBERS)));
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ public void decompile(Map<String, String> preferences) {
strings.clear();

// Init preferences
boolean realignmentLineNumbers = getPreferenceValue(preferences, REALIGN_LINE_NUMBERS, true);
boolean realignmentLineNumbers = getPreferenceValue(preferences, REALIGN_LINE_NUMBERS, false);
boolean unicodeEscape = getPreferenceValue(preferences, ESCAPE_UNICODE_CHARACTERS, false);

Map<String, Object> configuration = new HashMap<>();
Expand Down Expand Up @@ -116,7 +116,7 @@ public void save(API api, OutputStream os) {
try {
// Init preferences
Map<String, String> preferences = api.getPreferences();
boolean realignmentLineNumbers = getPreferenceValue(preferences, REALIGN_LINE_NUMBERS, true);
boolean realignmentLineNumbers = getPreferenceValue(preferences, REALIGN_LINE_NUMBERS, false);
boolean unicodeEscape = getPreferenceValue(preferences, ESCAPE_UNICODE_CHARACTERS, false);
boolean showLineNumbers = getPreferenceValue(preferences, WRITE_LINE_NUMBERS, true);

Expand Down

0 comments on commit a0fa89c

Please sign in to comment.