summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Abraham <andreas.abraham@egiz.gv.at>2021-06-18 16:44:05 +0200
committerAndreas Abraham <andreas.abraham@egiz.gv.at>2021-06-18 16:44:05 +0200
commit995742efd6130721f1ac559a61ceaf0b09727148 (patch)
tree2c6bec3cfc764f32f761d938622889bf0a0887c8
parent7a032cc75008748df505f2939984f6d33d24d58e (diff)
downloadpdf-over-995742efd6130721f1ac559a61ceaf0b09727148.tar.gz
pdf-over-995742efd6130721f1ac559a61ceaf0b09727148.tar.bz2
pdf-over-995742efd6130721f1ac559a61ceaf0b09727148.zip
fixed behaviour
-rw-r--r--pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SimpleConfigurationComposite.java14
1 files changed, 10 insertions, 4 deletions
diff --git a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SimpleConfigurationComposite.java b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SimpleConfigurationComposite.java
index 82468547..05efd217 100644
--- a/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SimpleConfigurationComposite.java
+++ b/pdf-over-gui/src/main/java/at/asit/pdfover/gui/composites/SimpleConfigurationComposite.java
@@ -728,9 +728,10 @@ public class SimpleConfigurationComposite extends BaseConfigurationComposite {
this.configurationContainer.setSignatureLocale(selected);
this.cmbSignatureLang.select(this.getLocaleElementIndex(selected));
if (previous != null) {
- String prev_default_note = getSignatureBlockNoteTextAccordingToProfile(this.configurationContainer.getSignatureProfile(), previous);
+ Profile profile = Profile.values()[this.cmbSignatureProfiles.getSelectionIndex()];
+ String prev_default_note = getSignatureBlockNoteTextAccordingToProfile(profile, previous);
if (this.txtSignatureNote.getText().equals(prev_default_note)) {
- this.txtSignatureNote.setText(getSignatureBlockNoteTextAccordingToProfile(this.configurationContainer.getSignatureProfile(), selected)); //$NON-NLS-1$);
+ this.txtSignatureNote.setText(getSignatureBlockNoteTextAccordingToProfile(profile, selected)); //$NON-NLS-1$);
processSignatureNoteChanged();
}
}
@@ -763,8 +764,13 @@ public class SimpleConfigurationComposite extends BaseConfigurationComposite {
}
boolean detectChanges(Profile profile){
- if (this.configurationContainer.getSignatureNote().equals(getSignatureBlockNoteTextAccordingToProfile(Profile.AMTSSIGNATURBLOCK)) ||
- this.configurationContainer.getSignatureNote().equals(getSignatureBlockNoteTextAccordingToProfile(Profile.SIGNATURBLOCK_SMALL))) {
+
+ String note = this.txtSignatureNote.getText();
+ note = note.replace("!","");
+ if (note.equals(getSignatureBlockNoteTextAccordingToProfile(Profile.AMTSSIGNATURBLOCK)) ||
+ note.equals(getSignatureBlockNoteTextAccordingToProfile(Profile.SIGNATURBLOCK_SMALL)) ||
+ note.equals(getSignatureBlockNoteTextAccordingToProfile(Profile.INVISIBLE)) ||
+ note.equals(getSignatureBlockNoteTextAccordingToProfile(Profile.BASE_LOGO))){
return false;
}
return true;