From scm@users.codelutin.com Thu Nov 12 11:09:28 2015 From: "codelutin.com scm" To: observe-commits@list.forge.codelutin.com Subject: [Observe-commits] 01/01: Cacher la barre d'actions une fois l'action d'ouverture de base =?utf-8?q?lanc=C3=A9e?= (fixes #7703) Date: Thu, 12 Nov 2015 11:09:29 +0100 Message-ID: <20151112100928.BCBF45CFBD6@goh.codelutin.com> In-Reply-To: <20151112100928.23154.7114@bihar.codelutin.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============8580077870795648242==" --===============8580077870795648242== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable This is an automated email from the git hooks/post-receive script. New commit to branch feature/7703 in repository observe. See http://git.codelutin.com/observe.git commit f0ef937fca32290bcac4c1f1cf7c9b70e313868d Author: Kevin Morin Date: Thu Nov 12 11:08:02 2015 +0100 Cacher la barre d'actions une fois l'action d'ouverture de base lanc=C3= =A9e (fixes #7703) --- .../java/fr/ird/observe/ui/storage/StorageUI.css | 4 ++++ .../java/fr/ird/observe/ui/storage/StorageUI.jaxx | 2 +- .../ird/observe/ui/storage/StorageUIHandler.java | 2 ++ .../fr/ird/observe/ui/storage/StorageUIModel.java | 25 ++++++++++++++++++++= +- 4 files changed, 31 insertions(+), 2 deletions(-) diff --git a/observe-application-swing/src/main/java/fr/ird/observe/ui/storag= e/StorageUI.css b/observe-application-swing/src/main/java/fr/ird/observe/ui/s= torage/StorageUI.css index 1fb9545..173ea78 100644 --- a/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUI.css +++ b/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUI.css @@ -69,3 +69,7 @@ enabled:{getModel().isValidStep()}; visible:{getModel().getNextStep() =3D=3D null}; } + +#actions { + visible:{!getModel().isAlreadyApplied()}; +} \ No newline at end of file diff --git a/observe-application-swing/src/main/java/fr/ird/observe/ui/storag= e/StorageUI.jaxx b/observe-application-swing/src/main/java/fr/ird/observe/ui/= storage/StorageUI.jaxx index b46f1d1..404516d 100644 --- a/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUI.jaxx +++ b/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUI.jaxx @@ -161,7 +161,7 @@ void $afterCompleteSetup() { onStateChanged=3D'if (getSelectedStep() !=3D null) { getModel= ().gotoStep(getSelectedStep()); }'/> =20 - +
diff --git a/observe-application-swing/src/main/java/fr/ird/observe/ui/storag= e/StorageUIHandler.java b/observe-application-swing/src/main/java/fr/ird/obse= rve/ui/storage/StorageUIHandler.java index 3fd86d7..1a6fcb0 100644 --- a/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUIHandler.java +++ b/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUIHandler.java @@ -294,6 +294,8 @@ public class StorageUIHandler { =20 public void launchApply(final StorageUI ui) { =20 + ui.getModel().setAlreadyApplied(true); + Runnable action =3D WizardUILancher.APPLY_DEF.getContextValue(ui); =20 if (action =3D=3D null) { diff --git a/observe-application-swing/src/main/java/fr/ird/observe/ui/storag= e/StorageUIModel.java b/observe-application-swing/src/main/java/fr/ird/observ= e/ui/storage/StorageUIModel.java index 3b6657e..520fb3c 100644 --- a/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUIModel.java +++ b/observe-application-swing/src/main/java/fr/ird/observe/ui/storage/Stora= geUIModel.java @@ -132,6 +132,8 @@ public class StorageUIModel extends WizardModel { =20 public static final String VALID_PROPERTY_NAME =3D "valid"; =20 + public static final String ALREADY_APPLIED_PROPERTY_NAME =3D "alreadyApp= lied"; + private static final char[] EMPTY_PASSWORD =3D new char[0]; =20 private static final String LOGIN_REFERENTIEL =3D "referentiel"; @@ -156,6 +158,12 @@ public class StorageUIModel extends WizardModel { protected boolean doBackup; =20 /** + * Un drapeau pour savoir si on a d=C3=A9j=C3=A0 lanc=C3=A9 l'action App= liquer (pour =C3=A9viter le code r=C3=A9-entrant). + * @since 4.0.4 + */ + protected boolean alreadyApplied; + + /** * le fichier ou effectuer la sauvegarde de la base locale si le drapeau * doBackup est active. */ @@ -205,7 +213,6 @@ public class StorageUIModel extends WizardModel { /** le fichier d'import des donn=C3=A9 */ protected File dumpFile; =20 - /** le mode de creation d'une base */ protected CreationMode creationMode; =20 @@ -300,6 +307,12 @@ public class StorageUIModel extends WizardModel { addPropertyChangeListener(USE_SSL_PROPERTY_NAME, clearStatus); } =20 + @Override + public void setStep(StorageStep step) { + setAlreadyApplied(false); + super.setStep(step); + } + /** * La m=C3=A9thode pour initialiser le mod=C3=A8le =C3=A0 partir du cont= ext applicatif et * d'un service existant. @@ -1071,6 +1084,16 @@ public class StorageUIModel extends WizardModel { return result; } =20 + public boolean isAlreadyApplied() { + return alreadyApplied; + } + + public void setAlreadyApplied(boolean alreadyApplied) { + boolean oldValue =3D isAlreadyApplied(); + this.alreadyApplied =3D alreadyApplied; + firePropertyChange(ALREADY_APPLIED_PROPERTY_NAME, oldValue, alreadyA= pplied); + } + public boolean isUseSelectData() { return getSteps() !=3D null && getSteps().contains(StorageStep.SELECT_DATA); --=20 To stop receiving notification emails like this one, please contact codelutin.com SCM administrator . --===============8580077870795648242==-- From scm@users.codelutin.com Thu Nov 12 11:09:28 2015 From: "codelutin.com scm" To: observe-commits@list.forge.codelutin.com Subject: [Observe-commits] branch feature/7703 created (now f0ef937) Date: Thu, 12 Nov 2015 11:09:28 +0100 Message-ID: <20151112100928.23154.7114@bihar.codelutin.com> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3628451747682416982==" --===============3628451747682416982== Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable This is an automated email from the git hooks/post-receive script. New change to branch feature/7703 in repository observe. See http://git.codelutin.com/observe.git at f0ef937 Cacher la barre d'actions une fois l'action d'ouverture= de base lanc=C3=A9e (fixes #7703) This branch includes the following new commits: new f0ef937 Cacher la barre d'actions une fois l'action d'ouverture= de base lanc=C3=A9e (fixes #7703) The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "adds" were already present in the repository and have only been added to this reference. Detailed log of new commits: commit f0ef937fca32290bcac4c1f1cf7c9b70e313868d Author: Kevin Morin Date: Thu Nov 12 11:08:02 2015 +0100 Cacher la barre d'actions une fois l'action d'ouverture de base lanc=C3= =A9e (fixes #7703) --=20 To stop receiving notification emails like this one, please contact codelutin.com SCM administrator . --===============3628451747682416982==--