diff options
author | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2012-11-13 14:32:10 +0100 |
---|---|---|
committer | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2012-11-13 14:32:10 +0100 |
commit | 6422e0c67c1c48f5e79ba4dbbf1839f0c40a8f94 (patch) | |
tree | 3872f098ef64fa1603b73c68d169ba9548f9e951 /trunk/pdf-over-gui | |
parent | 3a13674cd84ec733bf76537514d8aaa390b97627 (diff) | |
download | pdf-over-6422e0c67c1c48f5e79ba4dbbf1839f0c40a8f94.tar.gz pdf-over-6422e0c67c1c48f5e79ba4dbbf1839f0c40a8f94.tar.bz2 pdf-over-6422e0c67c1c48f5e79ba4dbbf1839f0c40a8f94.zip |
+ fixed last TODOs
Diffstat (limited to 'trunk/pdf-over-gui')
6 files changed, 151 insertions, 10 deletions
diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/ConfigurationComposite.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/ConfigurationComposite.java index f9ff5b7f..63372f63 100644 --- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/ConfigurationComposite.java +++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/ConfigurationComposite.java @@ -193,7 +193,7 @@ public class ConfigurationComposite extends StateComposite { this.simpleConfigComposite.setSigner(getSigner()); } if (this.advancedConfigComposite != null) { - // TODO: not needed + // not needed at the moment this.advancedConfigComposite.setSigner(getSigner()); } } diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/OutputState.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/OutputState.java index 64df41f6..34b52a21 100644 --- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/OutputState.java +++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/OutputState.java @@ -23,8 +23,13 @@ import org.eclipse.swt.SWT; import at.asit.pdfover.gui.MainWindow.Buttons; import at.asit.pdfover.gui.MainWindowBehavior; import at.asit.pdfover.gui.composites.OutputComposite; +import at.asit.pdfover.gui.controls.ErrorDialog; +import at.asit.pdfover.gui.controls.Dialog.BUTTONS; +import at.asit.pdfover.gui.utils.Messages; import at.asit.pdfover.gui.workflow.StateMachine; import at.asit.pdfover.gui.workflow.Status; +import at.asit.pdfover.signator.SignatureException; +import at.knowcenter.wag.egov.egiz.exceptions.ConnectorException; /** * Procduces the output of the signature process. (save file, open file) @@ -64,7 +69,13 @@ public class OutputState extends State { Status status = this.stateMachine.getStatus(); if (status.getSignResult() == null) { - // TODO + ErrorDialog error = new ErrorDialog(this.stateMachine.getGUIProvider().getMainShell(), + Messages.getString("error.Signatur"), BUTTONS.RETRY_CANCEL); //$NON-NLS-1$ + if(error.open() == SWT.RETRY) { + this.setNextState(new PrepareSigningState(this.stateMachine)); + } else { + this.setNextState(new BKUSelectionState(this.stateMachine)); + } return; } diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PositioningState.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PositioningState.java index 0c6b2c8b..2d610f24 100644 --- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PositioningState.java +++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PositioningState.java @@ -102,8 +102,7 @@ public class PositioningState extends State { PositioningComposite position = null; try { position = this.getPositioningComposite(); - } catch (IOException e) { - // FIXME + } catch (IOException e) { this.positionComposite = null; log.error("Failed to display PDF document", e); //$NON-NLS-1$ String message = e.getLocalizedMessage(); diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java index 803590e7..c58417ac 100644 --- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java +++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/PrepareSigningState.java @@ -167,8 +167,6 @@ public class PrepareSigningState extends State { if(error.open() == SWT.RETRY) { this.stateMachine.update(); } else { - // FIXME: exit? - //this.stateMachine.exit(); this.setNextState(new BKUSelectionState(this.stateMachine)); } return; diff --git a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/SigningState.java b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/SigningState.java index 70a5a9d0..87201e2f 100644 --- a/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/SigningState.java +++ b/trunk/pdf-over-gui/src/main/java/at/asit/pdfover/gui/workflow/states/SigningState.java @@ -100,10 +100,9 @@ public class SigningState extends State { message, BUTTONS.RETRY_CANCEL); this.threadException = null; if(error.open() == SWT.RETRY) { - this.setNextState(new BKUSelectionState(this.stateMachine)); + this.setNextState(new PrepareSigningState(this.stateMachine)); } else { - // FIXME: Exit? - this.stateMachine.exit(); + this.setNextState(new BKUSelectionState(this.stateMachine)); } return; } diff --git a/trunk/pdf-over-gui/src/main/resources/at/asit/pdfover/gui/messages_en.properties b/trunk/pdf-over-gui/src/main/resources/at/asit/pdfover/gui/messages_en.properties index 31a92d3b..3f86ed1d 120000..100644 --- a/trunk/pdf-over-gui/src/main/resources/at/asit/pdfover/gui/messages_en.properties +++ b/trunk/pdf-over-gui/src/main/resources/at/asit/pdfover/gui/messages_en.properties @@ -1 +1,135 @@ -messages.properties
\ No newline at end of file +#Eclipse messages class +#Tue Oct 23 16:04:42 CEST 2012 +BKU.LOCAL=Local CCE +BKU.MOBILE=Mobile CCE +BKU.NONE=no default +BKUSelectionComposite.btnMobile.text=MOBILE +TrustedSocketFactory.FailedToCreateSecureConnection=Failed to create secure network connection +advanced_config.AutoPosition=Automatic positioning +advanced_config.AutoPosition_ToolTip=Activate this option to automatically position the signature +advanced_config.BKUSelection_Title=CC&E Selection +advanced_config.BKUSelection_ToolTip=Select the default CCE to use during signature +advanced_config.LocaleSelection_Title=Interface &language selection +advanced_config.LocaleSelection_ToolTip=Select the interface language for PDF-Over +advanced_config.OutputFolder=Default output folder: +advanced_config.OutputFolder.Dialog=Select a folder +advanced_config.OutputFolder.Dialog_Title=Select Output folder +advanced_config.OutputFolder_Title=&Output location +advanced_config.OutputFolder_ToolTip=Select the folder where the signed document will be saved automatically (clear this field to disable automatic saving, enter a single dot (".") to denote the input document directory) +advanced_config.Signature_Title=Si&gnature +advanced_config.SigPHTransparency=Signature placeholder transparency +advanced_config.SigPHTransparencyMax=Opaque +advanced_config.SigPHTransparencyMin=Invisible +advanced_config.SigPHTransparencyTooltip=Set the transparency of the signature placeholder in the positioning step +argument.error.output=is not a directory +argument.help.bku=Select the CCE to use. Values are: LOCAL, MOBILE. Example: -b <option> +argument.help.config=Defines which configuration file to use. Example: -c <config file> +argument.help.emblem=Sets the signature logo file to use for the signature. Example: -e <emblem file> +argument.help.help=Shows this help message +argument.help.input=Sets the document to sign. Example: -i <input document> +argument.help.number=Sets the telephone number to use for mobile CCE. Example: -n <number> +argument.help.output=Sets the output folder to use. Example: -o <folder> +argument.help.password=Sets the password to use for mobile CCE. Example: -p <password> +argument.help.proxyhost=Sets the proxy host to use. Example: -proxy <hostname/IP> +argument.help.proxyport=Sets the proxy port to use. Example: -proxyport <port> +argument.info.help=The following options are available: +argument.invalid.bku=CCE argument invalid! Use: +argument.invalid.config=Configuration file argument invalid! Use: +argument.invalid.emblem=Signature logo argument invalid! Use: +argument.invalid.input=Document to sign argument invalid! Use: +argument.invalid.number=Phone number argument invalid! Use: +argument.invalid.output=Output folder argument invalid! Use: +argument.invalid.password=Mobile CCE password invalid! Use: +argument.invalid.proxyhost=Proxy host argument invalid! Use: +argument.invalid.proxyport=Proxy port argument invalid! Use: +bku_selection.card=&Card +bku_selection.mobile=&Mobile +common.AllExtension_Description=All files +common.Cancel=C&ancel +common.GIFExtension_Description=GIF files +common.ImageExtension_Description=All supported image files +common.JPGExtension_Description=JPG files +common.Ok=O&K +common.PDFExtension_Description=PDF documents +common.PNGExtension_Description=PNG files +common.Save=&Save +common.browse=&Browse +common.open=Open +config.Advanced=Ad&vanced +config.Simple=Basi&c +dataSourceSelection.DropLabel=Drag document here +dataSourceSelection.DropLabel2=Or, if you prefer... +dataSourceSelection.browse=&Browse for PDF on your computer +error.Details=Details +error.EnteredReferenceValue=You entered the reference value! +error.FailedToGetSignedDocument=Failed to get signed document. +error.FailedToLoadEmblem=Failed to load the signature logo +error.FailedToSaveSettings=Failed to save configuration file! +error.FileNotExist=File %s does not exist! +error.Initialization=Initialization failed. Please check your configuration. +error.InvalidBKU=Invalid CCE selection. Please check. +error.InvalidLocale=Locale not valid +error.InvalidPhoneNumber=Given phone number is invalid! Example: +43664123456789 +error.InvalidSettings=Invalid settings are still present. Please check your input. +error.IOError=Input/Output Error +error.LocalBKU=Please check if a local CCE is running +error.MayNotBeAPDF=This may not be a PDF File +error.PositioningNotPossible=Manual positioning currently not possible due to a Java Bug. Using automatic positioning. +error.PrepareDocument=Failed to prepare document for signature. +error.Retry=Retry +error.SaveOutputFolder=Failed to save signed document to configured output folder. +error.Signatur=Signature error +error.SignaturePanel.NoPage=No page selected +error.SignaturePanel.NoRender=Could not render page +error.SWTLib=Error loading SWT library +error.TanTooLong=Entered TAN too long +error.Title=Error +error.TitleFatal=Fatal Error +error.Unexpected=Unexpected Error +exception.InvalidEmblemFile=%s is an invalid signature logo file! +exception.InvalidPort=%s is invalid: has to be a number between %d and %d +exception.PasswordTooLong=Given password is too long! +exception.PasswordTooShort=Given password is too short! +exception.PathNotDirectory=Path %s does not denote a directory! +exception.PathNotExist=Path %s does not exist! +main.configuration=Configuration +main.done=Finish +main.position=Positioning +main.signature=Signing +main.title=PDF-Over +mobileBKU.number=Number: +mobileBKU.password=Password: +output.file_ask_overwrite=File %s already exists, do you want to overwrite it? +output.link_open_message=You can open the signed file <a>here</a> +output.link_save_message=You can save the signed file +output.success_message=Signature was successful +positioning.newPage=Create &new Page +positioning.page=Page %d of %d +positioning.removeNewPage=Undo &new Page +positioning.sign=&Sign +positioning.signature=Signature +simple_config.ClearEmblem=Clea&r +simple_config.EmblemEmpty=Drag and Drop an image here\nor use the browse button \nto select a signature logo. +simple_config.Emblem_Title=Signature &logo +simple_config.ExampleNumber=+43676123456789 +simple_config.ExampleNumber_ToolTip=To use a default mobile phone number enter it here +simple_config.MobileBKU_Title=&Mobile signature +simple_config.Note=Text: +simple_config.Note_Default=This document is signed with a qualified electronic signature. According to §\u00A04 art.\u00A01 of the Signature Act it in principle is legally equivalent to a handwritten signature. +simple_config.Note_SetDefault=Restore default +simple_config.Note_Title=Signature &Note +simple_config.Note_Tooltip=Add an optional note to display on your Signature +simple_config.PhoneNumber=Mobile number: +simple_config.ProxyHost=Host: +simple_config.ProxyHostTemplate=Hostname or IP of the proxy server +simple_config.ProxyPort=Port: +simple_config.ProxyPortTemplate=Port of the proxy server [1-65535] +simple_config.Proxy_Title=&Proxy +simple_config.ProxyHost_ToolTip=To use a proxy server enter the hostname or the IP here +simple_config.ProxyPort_ToolTip=To use a proxy server enter the port number here +simple_config.SigBlockLang_Title=Signature block lan&guage: +simple_config.SigBlockLang_ToolTip=Select the language to be used in the signature block displayed on the signed document +tanEnter.ReferenceValue=Reference value: +tanEnter.TAN=TAN: +tanEnter.tries=%d tries left! +waiting.message=Signature creation in progress... |