From 23ae1caefcf0cc99c2b90327afaff6376ecc552a Mon Sep 17 00:00:00 2001 From: tkellner Date: Wed, 10 Apr 2013 18:53:41 +0000 Subject: PDF-AS signature working with local BKU git-svn-id: https://joinup.ec.europa.eu/svn/pdf-over/trunk@26 174cde9d-5d70-4d2a-aa98-46368bc2aaf7 --- .../at/asit/pdfover/gui/workflow/StateMachineImpl.java | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachineImpl.java') diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachineImpl.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachineImpl.java index 5ad800e9..cf764a73 100644 --- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachineImpl.java +++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/StateMachineImpl.java @@ -80,7 +80,14 @@ public class StateMachineImpl implements StateMachine, GUIProvider { State next = null; while (this.status.getCurrentState() != null) { State current = this.status.getCurrentState(); - current.run(); + try + { + current.run(); + } + catch(Exception e) { + log.error("StateMachine update: ", e); //$NON-NLS-1$ + // TODO: GOTO generic error state! + } if (this.mainWindow != null && !this.mainWindow.getShell().isDisposed()) { log.debug("Allowing MainWindow to update its state for " //$NON-NLS-1$ @@ -98,11 +105,13 @@ public class StateMachineImpl implements StateMachine, GUIProvider { + next.toString()); this.status.setCurrentState(next); } + + // TODO: Remove following line when releasing ... if (this.status.getCurrentState() != null) { this.setCurrentStateMessage(this.status.getCurrentState() .toString()); } else { - this.setCurrentStateMessage(""); + this.setCurrentStateMessage(""); //$NON-NLS-1$ } } @@ -197,7 +206,7 @@ public class StateMachineImpl implements StateMachine, GUIProvider { composite = constructor.newInstance(getComposite(), style, state); } catch (Exception e) { log.error( - "Could not create Composite for Class " + "Could not create Composite for Class " //$NON-NLS-1$ + compositeClass.getName(), e); } return composite; -- cgit v1.2.3