From d06a916f5fec72b61f5d31b4c1bea69802fe5f3e Mon Sep 17 00:00:00 2001 From: tkellner Date: Wed, 10 Apr 2013 19:39:53 +0000 Subject: Avoid widget cleanup problem git-svn-id: https://joinup.ec.europa.eu/svn/pdf-over/trunk@440 174cde9d-5d70-4d2a-aa98-46368bc2aaf7 --- .../gui/workflow/states/PrepareSigningState.java | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'pdf-over-gui/src') diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java index 5f731470..d0e9bdfe 100644 --- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java +++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java @@ -144,34 +144,34 @@ public class PrepareSigningState extends State { WaitingComposite waiting = this.getSelectionComposite(); this.stateMachine.getGUIProvider().display(waiting); - + this.signer = this.stateMachine.getPDFSigner().getPDFSigner(); - + Status status = this.stateMachine.getStatus(); - + if(this.signatureParameter == null) { this.signatureParameter = this.signer.newParameter(); } - + if(this.signingState == null && this.threadException == null) { Thread t = new Thread(new PrepareDocumentThread(this)); t.start(); return; - } - + } + if(this.threadException != null) { ErrorDialog error = new ErrorDialog(this.stateMachine.getGUIProvider().getMainShell(), Messages.getString("error.PrepareDocument"), //$NON-NLS-1$ BUTTONS.RETRY_CANCEL); this.threadException = null; if(error.open() == SWT.RETRY) { - this.stateMachine.update(); + run(); } else { this.setNextState(new BKUSelectionState(this.stateMachine)); } return; } - + // We got the Request set it into status and move on to next state ... status.setSigningState(this.signingState); @@ -207,7 +207,7 @@ public class PrepareSigningState extends State { } @Override - public String toString() { + public String toString() { return this.getClass().getName(); } } -- cgit v1.2.3