Merge pull request #4957 from jkho/5262-Blank-error-message-when-saving-config-file-fails

Fix message format and status label
This commit is contained in:
Richard Cordovano 2019-06-26 15:53:40 -04:00 committed by GitHub
commit 887bfa7c47
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -50,7 +50,7 @@ ConfigVisualPanel3.description.text=Press Save to write the imaging tool and con
ConfigVisualPanel3.failedToSaveConfigMsg=Failed to save configuration file: {0}
ConfigVisualPanel3.failedToSaveExeMsg=Failed to save tsk_logical_imager.exe file
# {0} - reason
ConfigVisualPanel3.reason=\nReason:
ConfigVisualPanel3.reason=\nReason: {0}
ConfigVisualPanel3.saveConfigurationFile=Save imager
CreateLogicalImagerAction.title=Create Logical Imager
CTL_CreateLogicalImagerAction=Create Logical Imager

View File

@ -91,7 +91,7 @@ class ConfigVisualPanel3 extends javax.swing.JPanel {
"# {0} - configFilename",
"ConfigVisualPanel3.failedToSaveConfigMsg=Failed to save configuration file: {0}",
"# {0} - reason",
"ConfigVisualPanel3.reason=\nReason: ",
"ConfigVisualPanel3.reason=\nReason: {0}",
"ConfigVisualPanel3.failedToSaveExeMsg=Failed to save tsk_logical_imager.exe file",})
void saveConfigFile() {
boolean saveSuccess = true;
@ -111,8 +111,8 @@ class ConfigVisualPanel3 extends javax.swing.JPanel {
configStatusLabel.setText(Bundle.ConfigVisualPanel3_copyStatus_saved());
} catch (IOException ex) {
saveSuccess = false;
executableStatusLabel.setText(Bundle.ConfigVisualPanel3_copyStatus_error());
executableStatusLabel.setForeground(Color.RED);
configStatusLabel.setText(Bundle.ConfigVisualPanel3_copyStatus_error());
configStatusLabel.setForeground(Color.RED);
JOptionPane.showMessageDialog(this, Bundle.ConfigVisualPanel3_failedToSaveConfigMsg(configFilename)
+ Bundle.ConfigVisualPanel3_reason(ex.getMessage()));
} catch (JsonIOException jioe) {