summaryrefslogtreecommitdiff
path: root/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku
diff options
context:
space:
mode:
authorTobias Kellner <tobias.kellner@iaik.tugraz.at>2014-12-03 18:10:46 +0100
committerTobias Kellner <tobias.kellner@iaik.tugraz.at>2014-12-03 18:10:46 +0100
commit8e56cd2c9a300f7f9251263d6aceb2b00453324b (patch)
tree3bef62c79d46a87324634402d0d44b14691129c4 /pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku
parent942b27169ce8b38f780a9a2de912b2efec94ebea (diff)
downloadpdf-over-8e56cd2c9a300f7f9251263d6aceb2b00453324b.tar.gz
pdf-over-8e56cd2c9a300f7f9251263d6aceb2b00453324b.tar.bz2
pdf-over-8e56cd2c9a300f7f9251263d6aceb2b00453324b.zip
Add cancel button to Mobile BKU dialogs
Diffstat (limited to 'pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku')
-rw-r--r--pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java14
1 files changed, 11 insertions, 3 deletions
diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
index f08c885e..828a23ac 100644
--- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
+++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/bku/MobileBKUConnector.java
@@ -76,11 +76,15 @@ public class MobileBKUConnector implements BkuSlConnector {
do {
// Check if credentials are available, get them from user if not
this.state.checkCredentials();
-
+
+ if (this.state.getStatus().getErrorMessage() != null &&
+ this.state.getStatus().getErrorMessage().equals("cancel")) //$NON-NLS-1$
+ throw new SignatureException(new IllegalStateException());
+
// Post credentials
try {
String responseData = handler.postCredentials();
-
+
// Now we have received some data lets check it:
log.debug("Response from mobile BKU: " + responseData); //$NON-NLS-1$
@@ -103,7 +107,11 @@ public class MobileBKUConnector implements BkuSlConnector {
do {
// Get TAN
this.state.checkTAN();
-
+
+ if (this.state.getStatus().getErrorMessage() != null &&
+ this.state.getStatus().getErrorMessage().equals("cancel")) //$NON-NLS-1$
+ throw new SignatureException(new IllegalStateException());
+
// Post TAN
try {
String responseData = handler.postTAN();