}
- // report errors
- Console.warn(
- "The following errors and warnings occurred whilst processing files:\n"
- + errorsToString());
+ // report errors - if any
+ String errorsRaised = errorsToString();
+ if (errorsRaised.trim().length() > 0)
+ {
+ Console.warn(
+ "The following errors and warnings occurred whilst processing files:\n"
+ + errorsRaised);
+ }
// gui errors reported in Jalview
if (argParser.getBoolean(Arg.QUIT))
// RESTORE SESSION AFTER EXPORT IF NEED BE
if (sessionToRestore != null)
{
- sview.getBinding().openSession(sessionToRestore.getCanonicalPath());
+ Console.debug("Restoring session from "
+ + sessionToRestore);
+
+ sview.getBinding().restoreSession(sessionToRestore.getAbsolutePath());
+
}
} catch (ImageOutputException ioexc)
{
isError = true;
continue;
}
- catch (IOException ioexec)
- {
- addError("Unexpected error when restoring structure viewer session after custom view operations.");
- isError = true;
- continue;
- }
finally
{
- this.colourAlignFrame(af, originalColourScheme);
+ try {
+ this.colourAlignFrame(af, originalColourScheme);
+ } catch (Exception t)
+ {
+ addError("Unexpected error when restoring colourscheme to alignment after temporary change for export.",t);
+ }
}
}
}