|
From: <de...@us...> - 2014-02-03 10:42:57
|
Revision: 8595
http://sourceforge.net/p/fudaa/svn/8595
Author: deniger
Date: 2014-02-03 10:42:53 +0000 (Mon, 03 Feb 2014)
Log Message:
-----------
CRUE-594, CRUE-604
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
trunk/soft/fudaa-crue/crue-io/src/main/java/org/fudaa/dodico/crue/io/neuf/DCFileReader.java
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu40.java
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu50.java
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu70.java
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-0.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-1.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-2.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-3.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-4.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-5.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu4-0.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu4-1.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu5-0.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu6-0.zip
trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu7-0.zip
trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/TestValidatorForValuesAndContents.java
trunk/soft/fudaa-crue/ui-options/src/main/resources/org/fudaa/fudaa/crue/options/layer.xml
trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/ScenarioBuilderForTests.java
trunk/soft/fudaa-crue/ui-study/src/main/java/org/fudaa/fudaa/crue/study/actions/CloseProjectAction.java
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/modules/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/modules/options/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/modules/options/keymap/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/modules/options/keymap/Bundle_fr_FR.properties
Modified: trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
===================================================================
--- trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-02-03 10:42:53 UTC (rev 8595)
@@ -892,8 +892,8 @@
externConfig.geo.NoFormatFound.error=Ressource {0}: le format du fichier n''est pas pr\u00e9sent dans le fichier
externConfig.geo.FormatUnknown.error=Ressource {0}: le format {1} du fichier n''est pas support\u00e9 par Fudaa-Crue
externConfig.geo.NoDataFound.error=Ressource {0}: le fichier {1} ne contient pas de donn\u00e9es ou est erron\u00e9
-create.SectionAval={0}_Aval
-create.SectionAmont={0}_Amont
+create.SectionAval={0}_Av
+create.SectionAmont={0}_Am
deleteEMH.SectionUsedByBranche.Title=Des sections ne sont pas supprim\u00e9es car utilis\u00e9es par des branches
deleteEMH.SectionUsedByBranche.Item=La section {0} est utilis\u00e9e par une branche
deleteEMH.SectionUsedBySectionIdem.Title=Des sections ne sont pas supprim\u00e9es car r\u00e9f\u00e9renc\u00e9es par des SectionIdem
Modified: trunk/soft/fudaa-crue/crue-io/src/main/java/org/fudaa/dodico/crue/io/neuf/DCFileReader.java
===================================================================
--- trunk/soft/fudaa-crue/crue-io/src/main/java/org/fudaa/dodico/crue/io/neuf/DCFileReader.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/crue-io/src/main/java/org/fudaa/dodico/crue/io/neuf/DCFileReader.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -301,11 +301,11 @@
final EMHSectionSansGeometrie amont = new EMHSectionSansGeometrie(CruePrefix.changePrefix(branche.getNom(),
CruePrefix.P_BRANCHE,
CruePrefix.P_SECTION)
- + "_Amont");
+ + "_Am");
final EMHSectionSansGeometrie aval = new EMHSectionSansGeometrie(CruePrefix.changePrefix(branche.getNom(),
CruePrefix.P_BRANCHE,
CruePrefix.P_SECTION)
- + "_Aval");
+ + "_Av");
metier.add(amont);
metier.add(aval);
branche.addListeSections(Arrays.asList(EMHRelationFactory.createSectionDansBrancheAndSetBrancheContientSection(branche, amont, 0,
Modified: trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu40.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu40.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu40.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -45,26 +45,26 @@
@Test
public void testSc_M40_c9c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M4-0_c9", "Sc_M4-0_c9c9", "M4-0_c9c9", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_M4-0_c9c9", new ErrorBilanTester(0, 0, 4, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_c9c9", new ErrorBilanTester(0, 0, 3, 2));
}
@Test
public void testSc_M40_c10c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M4-0_c10", "Sc_M4-0_c10c9", "M4-0_c10c9",
Arrays.asList("COM5", "COM1", "COM3", "DLHY1", "DCLM4", "PNUM1", "OPTR1"));
- IntegrationHelper.testScenario(projet, "Sc_M4-0_c10c9", new ErrorBilanTester(0, 0, 4, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_c10c9", new ErrorBilanTester(0, 0, 3, 2));
}
@Test
public void testSc_M40_c10c10() {
IntegrationHelper.exportToCrue10(getEtuFile().getParentFile(), projet, "Sc_M4-0_c10", "Sc_M4-0_c10c10", "M4-0_c10c10", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_M4-0_c10c10", new ErrorBilanTester(0, 0, 3, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_c10c10", new ErrorBilanTester(0, 0, 2, 1));
}
@Test
public void testSc_Poub_c10() {
IntegrationHelper.exportToCrue10(getEtuFile().getParentFile(), projet, "Sc_M4-0_c10", "Sc_Poub_c10", "Poub_c10", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_Poub_c10", new ErrorBilanTester(0, 0, 3, 1));
+ IntegrationHelper.testScenario(projet, "Sc_Poub_c10", new ErrorBilanTester(0, 0, 2, 1));
}
@Test
@@ -74,17 +74,17 @@
"COM5", "OCAL4",
"OPTI6", "OPTG4",
"OPTR1"));// différences
- IntegrationHelper.testScenario(projet, "Sc_M4-0_c9c10", new ErrorBilanTester(0, 0, 3, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_c9c10", new ErrorBilanTester(0, 0, 2, 2));
}
@Test
public void testSc_M40_c9() {
- IntegrationHelper.testScenario(projet, "Sc_M4-0_c9", new ErrorBilanTester(0, 0, 4, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_c9", new ErrorBilanTester(0, 0, 3, 2));
}
@Test
public void testSc_M40_v1c9() {
- IntegrationHelper.testScenario(projet, "Sc_M4-0_v1c9", new ErrorBilanTester(0, 0, 4, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_v1c9", new ErrorBilanTester(0, 0, 3, 1));
}
@Test
@@ -94,12 +94,12 @@
@Test
public void testSc_M40_c10() {
- IntegrationHelper.testScenario(projet, "Sc_M4-0_c10", new ErrorBilanTester(0, 0, 3, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_c10", new ErrorBilanTester(0, 0, 2, 1));
}
@Test
public void testSc_M40_v1c10() {
- IntegrationHelper.testScenario(projet, "Sc_M4-0_v1c10", new ErrorBilanTester(0, 0, 3, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M4-0_v1c10", new ErrorBilanTester(0, 0, 2, 1));
}
private File getEtuFile() {
Modified: trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -51,7 +51,7 @@
@Test
public void testSc_Poub_c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M4-1_c9", "Sc_Poub_c9", "Poub_c9", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_Poub_c9", new ErrorBilanTester(0, 0, 6, 2));
+ IntegrationHelper.testScenario(projet, "Sc_Poub_c9", new ErrorBilanTester(0, 0, 5, 2));
}
@Test
Modified: trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu50.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu50.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu50.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -46,13 +46,13 @@
public void testSc_M50_c10c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M5-0_c10", "Sc_M5-0_c10c9", "M5-0_c10c9",
Arrays.asList("COM1", "COM3", "COM5", "PNUM1", "OPTR1"));
- IntegrationHelper.testScenario(projet, "Sc_M5-0_c10c9", new ErrorBilanTester(0, 0, 7, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M5-0_c10c9", new ErrorBilanTester(0, 0, 5, 1));
}
@Test
public void testSc_M50_c9c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M5_c9", "Sc_M5_c9c9", "M5_c9c9", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_M5_c9c9", new ErrorBilanTester(0, 0, 7, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M5_c9c9", new ErrorBilanTester(0, 0, 5, 1));
}
@Test
@@ -61,13 +61,13 @@
"COM5", "OCAL4",
"OPTI6", "OPTG4",
"OPTR1"));// différences
- IntegrationHelper.testScenario(projet, "Sc_M5-0_c9c10", new ErrorBilanTester(0, 0, 6, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M5-0_c9c10", new ErrorBilanTester(0, 0, 4, 1));
}
@Test
public void testSc_M50_c10c10() {
IntegrationHelper.exportToCrue10(getEtuFile().getParentFile(), projet, "Sc_M5-0_c10", "Sc_M5-0_c10c10", "M5-0_c10c10", true, 0);// différences
- IntegrationHelper.testScenario(projet, "Sc_M5-0_c10c10", new ErrorBilanTester(0, 0, 6, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M5-0_c10c10", new ErrorBilanTester(0, 0, 4, 1));
}
@Test
@@ -75,22 +75,22 @@
IntegrationHelper.exportToCrue10(getEtuFile().getParentFile(), projet, "Sc_M5-0_c9", "Sc_Poub_c10", "Poub_c10", Arrays.asList("COM1", "COM3", "COM5",
"OCAL4", "OPTI6",
"OPTG4", "OPTR1"));// différences
- IntegrationHelper.testScenario(projet, "Sc_Poub_c10", new ErrorBilanTester(0, 0, 6, 1));
+ IntegrationHelper.testScenario(projet, "Sc_Poub_c10", new ErrorBilanTester(0, 0, 4, 1));
}
@Test
public void testSc_M5_c9() {
- IntegrationHelper.testScenario(projet, "Sc_M5_c9", new ErrorBilanTester(0, 0, 7, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M5_c9", new ErrorBilanTester(0, 0, 5, 1));
}
@Test
public void testSc_M50_c9() {
- IntegrationHelper.testScenario(projet, "Sc_M5-0_c9", new ErrorBilanTester(0, 0, 7, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M5-0_c9", new ErrorBilanTester(0, 0, 5, 1));
}
@Test
public void testSc_M50_c10() {
- IntegrationHelper.testScenario(projet, "Sc_M5-0_c10", new ErrorBilanTester(0, 0, 6, 1));
+ IntegrationHelper.testScenario(projet, "Sc_M5-0_c10", new ErrorBilanTester(0, 0, 4, 1));
}
private File getEtuFile() {
Modified: trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu70.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu70.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu70.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -46,14 +46,14 @@
public void testSc_M70_c9c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M7-0_c9", "Sc_M7-0_c9c9", "M7-0_c9c9", true,
0);
- IntegrationHelper.testScenario(projet, "Sc_M7-0_c9c9", new ErrorBilanTester(0, 0, 261, 0));
+ IntegrationHelper.testScenario(projet, "Sc_M7-0_c9c9", new ErrorBilanTester(0, 0, 249, 0));
}
@Test
public void testSc_M70_c10c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M7-0_c10", "Sc_M7-0_c10c9", "M7-0_c10c9",
Arrays.asList("COM5", "COM1", "COM3", "OPTR1"));
- IntegrationHelper.testScenario(projet, "Sc_M7-0_c10c9", new ErrorBilanTester(0, 0, 261, 0));
+ IntegrationHelper.testScenario(projet, "Sc_M7-0_c10c9", new ErrorBilanTester(0, 0, 249, 0));
}
@Test
@@ -62,23 +62,23 @@
Arrays.asList("COM5", "COM1",
"COM3", "OPTI6",
"OPTG4", "OPTR1"));// différences
- IntegrationHelper.testScenario(projet, "Sc_M7-0_c9c10", new ErrorBilanTester(0, 0, 260, 0));
+ IntegrationHelper.testScenario(projet, "Sc_M7-0_c9c10", new ErrorBilanTester(0, 0, 248, 0));
}
@Test
public void testSc_M70_c10c10() {
IntegrationHelper.exportToCrue10(getEtuFile().getParentFile(), projet, "Sc_M7-0_c10", "Sc_M7-0_c10c10", "M7-0_c10c10", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_M7-0_c10c10", new ErrorBilanTester(0, 0, 260, 0));
+ IntegrationHelper.testScenario(projet, "Sc_M7-0_c10c10", new ErrorBilanTester(0, 0, 248, 0));
}
@Test
public void testSc_M70_c10() {
- IntegrationHelper.testScenario(projet, "Sc_M7-0_c10", new ErrorBilanTester(0, 0, 260, 0));
+ IntegrationHelper.testScenario(projet, "Sc_M7-0_c10", new ErrorBilanTester(0, 0, 248, 0));
}
@Test
public void testSc_M70_c9() {
- IntegrationHelper.testScenario(projet, "Sc_M7-0_c9", new ErrorBilanTester(0, 1, 261, 0));
+ IntegrationHelper.testScenario(projet, "Sc_M7-0_c9", new ErrorBilanTester(0, 1, 249, 0));
}
private File getEtuFile() {
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-0.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-1.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-2.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-3.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-4.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu3-5.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu4-0.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu4-1.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu5-0.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu6-0.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-project/src/test/resources/integration/v1_1_1/Etu7-0.zip
===================================================================
(Binary files differ)
Modified: trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/TestValidatorForValuesAndContents.java
===================================================================
--- trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/TestValidatorForValuesAndContents.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/TestValidatorForValuesAndContents.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -55,20 +55,20 @@
assertFalse(log.containsErrorOrSevereError());
ValidationContentSectionDansBrancheExecutor executor = new ValidationContentSectionDansBrancheExecutor(CrueConfigMetierLoaderDefaultTest.DEFAULT);
- executor.validContent(log, pdc, Arrays.asList(new EMHSectionSansGeometrie("Test_Amont"), new EMHSectionSansGeometrie(
- "Test_Aval")));
+ executor.validContent(log, pdc, Arrays.asList(new EMHSectionSansGeometrie("Test_Am"), new EMHSectionSansGeometrie(
+ "Test_Av")));
contents.validateBranche(pdc, new EMHModeleBase(), log);
assertFalse(log.containsErrorOrSevereError());
- executor.validContent(log, pdc, Arrays.asList(new EMHSectionSansGeometrie("Test_Amont"), new EMHSectionSansGeometrie(
- "Test_Amont"),
- new EMHSectionSansGeometrie("Test_Aval")));
+ executor.validContent(log, pdc, Arrays.asList(new EMHSectionSansGeometrie("Test_Am"), new EMHSectionSansGeometrie(
+ "Test_Am"),
+ new EMHSectionSansGeometrie("Test_Av")));
assertTrue(log.containsErrorOrSevereError());
assertEquals(1, log.getRecords().size());
assertEquals("validation.branche.nbSectionNotEqualsTo", log.getRecords().iterator().next().getMsg());
log.clear();
- executor.validContent(log, pdc, Arrays.asList(new EMHSectionIdem("titi"), new EMHSectionSansGeometrie("Test_Amont"),
+ executor.validContent(log, pdc, Arrays.asList(new EMHSectionIdem("titi"), new EMHSectionSansGeometrie("Test_Am"),
new EMHSectionSansGeometrie(
- "Test_Amont"), new EMHSectionSansGeometrie("Test_Aval")));
+ "Test_Am"), new EMHSectionSansGeometrie("Test_Av")));
assertTrue(log.containsErrorOrSevereError());
assertEquals(2, log.getRecords().size());
Iterator<CtuluLogRecord> iterator = log.getRecords().iterator();
@@ -85,8 +85,8 @@
EMHBranchePdc pdc = new EMHBranchePdc("test");
EMHRelationFactory.addRelationContientEMH(sousModele, pdc);
pdc.setUserActive(true);
- final EMHSectionSansGeometrie amont = new EMHSectionSansGeometrie("Test_Amont");
- final EMHSectionSansGeometrie aval = new EMHSectionSansGeometrie("Test_Aval");
+ final EMHSectionSansGeometrie amont = new EMHSectionSansGeometrie("Test_Am");
+ final EMHSectionSansGeometrie aval = new EMHSectionSansGeometrie("Test_Av");
pdc.addListeSections(Arrays.asList(
EMHRelationFactory.createSectionDansBrancheAndSetBrancheContientSection(pdc, amont, 0, EnumPosSection.AMONT,
CrueConfigMetierLoaderDefaultTest.DEFAULT),
Added: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/modules/options/keymap/Bundle_fr_FR.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/modules/options/keymap/Bundle_fr_FR.properties (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-options-keymap.jar/org/netbeans/modules/options/keymap/Bundle_fr_FR.properties 2014-02-03 10:42:53 UTC (rev 8595)
@@ -0,0 +1,60 @@
+AD_Add_Shortcut=Ajouter
+AD_Clear=Effacer le raccourci
+AD_Delete=Effacer
+AD_Duplicate=Dupliquer
+AD_Profiles=Profils
+AD_Remove_Shortcut=Supprimer
+AD_Restore=Restaurer
+AD_Shortcut=raccourci
+AD_Shortcuts=Raccourcis
+AD_ShortcutsDialog=Entrer un nouveau raccourci
+AD_Show_Shortcuts=Raccourcis
+AD_Tab=Ins\u00e9rer un caract\u00e8re TAB
+Add_Alternative=Ajouter un raccourci alternatif
+Add_Shortcut_Dialog=Ajouter un raccourci
+Alternative_Shortcut=(raccourci alternatif)
+AN_Add_Shortcut=Ajouter
+AN_Clear=Effacer le raccourci bouton
+AN_Delete=Supprimer
+AN_Duplicate=Dupliquer
+AN_Profiles=Profils
+AN_Remove_Shortcut=Supprimer
+AN_Restore=Restaurer
+AN_Shortcut=Raccourci
+AN_Shortcuts=Raccourcis
+AN_ShortcutsDialog=Entrer un nouveau raccourci
+AN_Show_Shortcuts=Raccourcis
+AN_Tab=Ins\u00e9rer un caract\u00e8re TAB
+Category=Cat\u00e9gorie
+Clear=Effacer
+Conflicting_Shortcut_Dialog=Dialogue des conflits de raccourcis
+CTL_Add_Shortcut=A&jouter ...
+CTL_Clear=&Effacer
+CTL_Create_New_Profile_Message=&Nom du profil:
+CTL_Create_New_Profile_Title=Nouveau profil
+CTL_Delete=Supprimer
+CTL_Duplicate=&Configurer les profiles...
+CTL_Duplicate_Profile_Name=Un profil avec le nom donn\u00e9 existe d\u00e9j\u00e0. Veuillez proposer un autre nom
+CTL_Export_Editor_Shortcuts_Action=Exporter les raccourcis dans un format XML
+CTL_Export_IDE_Actions_Action=Exporter les raccourcis de l'IDE dans un format XML
+CTL_Export_IDE_Shortcuts_Action=Exporter les raccourcis de l'IDE dans un format XML
+CTL_Export_Shortcuts_to_HTML_Action=Exporter les raccourcis dans un format HTML
+CTL_Files=Fichiers
+CTL_Keymap_Name=&Profil:
+CTL_Keymap_Options=&Raccourcis
+CTL_Keymap_Options_Description=Raccourci
+CTL_Keymap_Options_Title=Raccourcis
+CTL_Manage_Keymap_Profiles=Configurer les profils de raccourcis
+CTL_Other=Autre
+CTL_Remove_Shortcut=Supprimer
+CTL_Restore=&Restaurer
+CTL_Shortcuts=&Raccourcis:
+CTL_Show_Shortcuts=&Raccourcis
+Edit=Editer...
+KeymapPanel.searchLabel.text=&Chercher:
+KeymapPanel.searchSCLabel.text=Chercher dans les raccou&rcis:
+Keymaps=&Raccourcis
+Keymaps.Options.Export.Category.displayName=Raccourcis
+ProfilesPanel.profilesList.AccessibleContext.accessibleDescription=Liste des profils de raccourcis clavier
+Reset_to_Default=R\u00e9initialiser
+Shortcut=Raccourci
Modified: trunk/soft/fudaa-crue/ui-options/src/main/resources/org/fudaa/fudaa/crue/options/layer.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-options/src/main/resources/org/fudaa/fudaa/crue/options/layer.xml 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/ui-options/src/main/resources/org/fudaa/fudaa/crue/options/layer.xml 2014-02-03 10:42:53 UTC (rev 8595)
@@ -27,7 +27,6 @@
<folder name="OptionsDialog">
<file name="Advanced.instance_hidden"/>
<file name="General.instance_hidden"/>
- <file name="Keymaps.instance_hidden"/>
</folder>
<file name="OptionsExport_hidden"/>
</filesystem>
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/ScenarioBuilderForTests.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/ScenarioBuilderForTests.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/ScenarioBuilderForTests.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -109,8 +109,8 @@
}
private static void addSections(EMHSousModele sousModele, CatEMHBranche br, double length, int nbSection) {
- EMHSectionSansGeometrie sectionAmont = new EMHSectionSansGeometrie("St_" + br.getNom() + "_Amont");
- EMHSectionSansGeometrie sectionAval = new EMHSectionSansGeometrie("St_" + br.getNom() + "_Aval");
+ EMHSectionSansGeometrie sectionAmont = new EMHSectionSansGeometrie("St_" + br.getNom() + "_Am");
+ EMHSectionSansGeometrie sectionAval = new EMHSectionSansGeometrie("St_" + br.getNom() + "_Av");
RelationEMHSectionDansBranche sectionAmontRelation = EMHRelationFactory.createSectionDansBrancheAndSetBrancheContientSection(br,
false, sectionAmont,
CrueConfigMetierLoaderDefaultTest.DEFAULT);
Modified: trunk/soft/fudaa-crue/ui-study/src/main/java/org/fudaa/fudaa/crue/study/actions/CloseProjectAction.java
===================================================================
--- trunk/soft/fudaa-crue/ui-study/src/main/java/org/fudaa/fudaa/crue/study/actions/CloseProjectAction.java 2014-01-31 20:53:28 UTC (rev 8594)
+++ trunk/soft/fudaa-crue/ui-study/src/main/java/org/fudaa/fudaa/crue/study/actions/CloseProjectAction.java 2014-02-03 10:42:53 UTC (rev 8595)
@@ -13,9 +13,10 @@
import org.openide.awt.ActionRegistration;
import org.openide.util.Lookup;
import org.openide.util.NbBundle;
+import org.openide.windows.WindowManager;
@ActionID(category = "View",
-id = "org.fudaa.fudaa.crue.study.actions.CloseStudy")
+ id = "org.fudaa.fudaa.crue.study.actions.CloseStudy")
@ActionRegistration(displayName = "#CloseStudy.Name")
@ActionReferences({
@ActionReference(path = "Actions/Study", position = 10)
@@ -37,5 +38,7 @@
@Override
public void actionPerformed(ActionEvent e) {
crueService.closeAll();
+ WindowManager.getDefault().getMainWindow().repaint(0);
+
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-03 13:33:32
|
Revision: 8596
http://sourceforge.net/p/fudaa/svn/8596
Author: deniger
Date: 2014-02-03 13:33:27 +0000 (Mon, 03 Feb 2014)
Log Message:
-----------
correction erreurs de report
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-emh/src/main/java/org/fudaa/dodico/crue/metier/emh/ResultatTimeKey.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatTimeKeySimpleToStringTransformer.java
trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ReportRunVariableTimeKeyMultiToStringTransformerTest.java
trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatKeySimpleToStringTransformerTest.java
Modified: trunk/soft/fudaa-crue/crue-emh/src/main/java/org/fudaa/dodico/crue/metier/emh/ResultatTimeKey.java
===================================================================
--- trunk/soft/fudaa-crue/crue-emh/src/main/java/org/fudaa/dodico/crue/metier/emh/ResultatTimeKey.java 2014-02-03 10:42:53 UTC (rev 8595)
+++ trunk/soft/fudaa-crue/crue-emh/src/main/java/org/fudaa/dodico/crue/metier/emh/ResultatTimeKey.java 2014-02-03 13:33:27 UTC (rev 8596)
@@ -18,6 +18,7 @@
* Pour les calcul Permanents sera égal à 0
*/
private final long duree;
+ private final boolean useDay;
private final String temps;
private final boolean transitoire;
public static final ResultatTimeKey NULL_VALUE = new ResultatTimeKey("<NULL>");
@@ -27,6 +28,7 @@
this.duree = -1;
temps = StringUtils.EMPTY;
transitoire = false;
+ useDay = false;
}
public ResultatTimeKey(String nomCalcul, long duree, boolean useDay) {
@@ -34,8 +36,13 @@
this.duree = duree;
temps = DateDurationConverter.durationToDDHHMMSS(new Duration(duree), useDay);
transitoire = true;
+ this.useDay = useDay;
}
+ public boolean isUseDay() {
+ return useDay;
+ }
+
public boolean isTransitoire() {
return transitoire;
}
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatTimeKeySimpleToStringTransformer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatTimeKeySimpleToStringTransformer.java 2014-02-03 10:42:53 UTC (rev 8595)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatTimeKeySimpleToStringTransformer.java 2014-02-03 13:33:27 UTC (rev 8596)
@@ -13,16 +13,23 @@
*/
public class ResultatTimeKeySimpleToStringTransformer extends AbstractPropertyToStringTransformer<ResultatTimeKey> {
+ public static final String DAY_YES = "DAY";
+ private static final String DAY_NO = "NO_DAY";
+
public ResultatTimeKeySimpleToStringTransformer() {
super(ResultatTimeKey.class);
}
+ private static String getDay(ResultatTimeKey key) {
+ return key.isUseDay() ? DAY_YES : DAY_NO;
+ }
+
@Override
public String toStringSafe(ResultatTimeKey in) {
if (in.isPermanent()) {
return in.getNomCalcul();
}
- return in.getNomCalcul() + KeysToStringConverter.MINOR_SEPARATOR + in.getDuree();
+ return in.getNomCalcul() + KeysToStringConverter.MINOR_SEPARATOR + in.getDuree() + KeysToStringConverter.MINOR_SEPARATOR + getDay(in);
}
@Override
@@ -43,10 +50,14 @@
if (split.length == 1) {
return new ResultatTimeKey(nomCalcul);
}
- if (split.length == 2) {
+ if (split.length >= 2) {
+ boolean day = false;
+ if (split.length == 3) {
+ day = DAY_YES.equals(split[2]);
+ }
try {
Long duree = Long.valueOf(split[1]);
- return new ResultatTimeKey(nomCalcul, duree);
+ return new ResultatTimeKey(nomCalcul, duree, day);
} catch (NumberFormatException numberFormatException) {
}
}
Modified: trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ReportRunVariableTimeKeyMultiToStringTransformerTest.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ReportRunVariableTimeKeyMultiToStringTransformerTest.java 2014-02-03 10:42:53 UTC (rev 8595)
+++ trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ReportRunVariableTimeKeyMultiToStringTransformerTest.java 2014-02-03 13:33:27 UTC (rev 8596)
@@ -23,7 +23,7 @@
@Test
public void testReadWrite() {
ReportRunKey current = new ReportRunKey();
- ResultatTimeKey currentKey = new ResultatTimeKey("calcul", 1234);
+ ResultatTimeKey currentKey = new ResultatTimeKey("calcul", 1234, false);
KeysToStringConverter converter = new KeysToStringConverter(current);
AbstractPropertyToStringTransformer<ReportRunVariableTimeKey> transformer = converter.getReportRunVariableTimeKeyConverter();
ReportRunVariableTimeKey key = new ReportRunVariableTimeKey(current, ReportVariableTypeEnum.READ, "variable", currentKey);
@@ -36,10 +36,11 @@
ReportRunKey reportRunKeyAlternatif = new ReportRunKey("manager", "run");
key = new ReportRunVariableTimeKey(reportRunKeyAlternatif, ReportVariableTypeEnum.READ, "variable", currentKey);
toString = transformer.toString(key);
- assertEquals("manager;run|variable;read|calcul;1234", toString);
+ assertEquals("manager;run|variable;read|calcul;1234;NO_DAY", toString);
fromKey = transformer.fromString(toString);
assertEquals(key, fromKey);
+
}
}
Modified: trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatKeySimpleToStringTransformerTest.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatKeySimpleToStringTransformerTest.java 2014-02-03 10:42:53 UTC (rev 8595)
+++ trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/transformer/ResultatKeySimpleToStringTransformerTest.java 2014-02-03 13:33:27 UTC (rev 8596)
@@ -28,14 +28,28 @@
}
@Test
+ public void testForTransitoireOldFormat() {
+ String old = "calcul;1234";
+ ResultatTimeKeySimpleToStringTransformer transformer = new ResultatTimeKeySimpleToStringTransformer();
+ final ResultatTimeKey fromString = transformer.fromString(old);
+ assertFalse(fromString.isUseDay());
+ assertEquals("calcul", fromString.getNomCalcul());
+ assertEquals(1234L, fromString.getDuree());
+
+ }
+
+ @Test
public void testForTransitoire() {
ResultatTimeKeySimpleToStringTransformer transformer = new ResultatTimeKeySimpleToStringTransformer();
final long duree = 12345L;
- ResultatTimeKey key = new ResultatTimeKey("transitoire", duree);
+ ResultatTimeKey key = new ResultatTimeKey("transitoire", duree, true);
final String toString = transformer.toString(key);
- assertEquals(key.getNomCalcul() + KeysToStringConverter.MINOR_SEPARATOR + duree, toString);
+ assertEquals(
+ key.getNomCalcul() + KeysToStringConverter.MINOR_SEPARATOR + duree + KeysToStringConverter.MINOR_SEPARATOR + ResultatTimeKeySimpleToStringTransformer.DAY_YES,
+ toString);
ResultatTimeKey readKey = transformer.fromString(toString);
assertEquals(readKey, key);
+ assertTrue(key.isUseDay());
assertEquals(duree, readKey.getDuree());
assertTrue(readKey.isTransitoire());
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-03 14:34:39
|
Revision: 8597
http://sourceforge.net/p/fudaa/svn/8597
Author: deniger
Date: 2014-02-03 14:34:34 +0000 (Mon, 03 Feb 2014)
Log Message:
-----------
CRUE-594
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionChangeBranche.java
trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionRename.java
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/emh/ModellingEMHBrancheTopComponent.java
trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/emh/Bundle.properties
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java
Modified: trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionChangeBranche.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionChangeBranche.java 2014-02-03 13:33:27 UTC (rev 8596)
+++ trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionChangeBranche.java 2014-02-03 14:34:34 UTC (rev 8597)
@@ -41,11 +41,11 @@
this.defaultValues = defaultValues;
}
- public CtuluLog changeBranche(CatEMHBranche initBranche, BrancheEditionContent newContent, CrueConfigMetier ccm) {
+ public CtuluLog changeBranche(CatEMHBranche initBranche, BrancheEditionContent newContent, CrueConfigMetier ccm, boolean renameSection) {
Map<String, CatEMHNoeud> noeudsByIds = TransformerHelper.toMapOfNom(initBranche.getParent().getNoeuds());
CatEMHNoeud noeudAmont = (CatEMHNoeud) noeudsByIds.get(newContent.getNoeudAmont());
CatEMHNoeud noeudAval = (CatEMHNoeud) noeudsByIds.get(newContent.getNoeudAval());
- CtuluLog log = prevalidate(newContent, initBranche, noeudAmont, noeudAval, ccm);
+ CtuluLog log = prevalidate(newContent, initBranche, noeudAmont, noeudAval, ccm, renameSection);
//on s'arrête:
if (log.containsErrorOrSevereError()) {
return log;
@@ -67,16 +67,17 @@
if (!newType.equals(branche.getBrancheType())) {
branche = changeType(ccm, sousModele, initBranche, newContent, newType);
}
- applyModifications(branche, newContent, sousModele, ccm, noeudAmont, noeudAval);
+ applyModifications(branche, newContent, sousModele, ccm, noeudAmont, noeudAval, renameSection);
return log;
}
- private void applyModifications(CatEMHBranche branche, BrancheEditionContent newContent, final EMHSousModele sousModele, CrueConfigMetier ccm, CatEMHNoeud noeudAmont, CatEMHNoeud noeudAval) {
+ private void applyModifications(CatEMHBranche branche, BrancheEditionContent newContent, final EMHSousModele sousModele, CrueConfigMetier ccm,
+ CatEMHNoeud noeudAmont, CatEMHNoeud noeudAval, boolean renameSection) {
EnumBrancheType newType = branche.getBrancheType();
branche.setCommentaire(newContent.getCommentaire());
- new EditionRename().rename(branche, newContent.getNom());
+ new EditionRename().rename(branche, newContent.getNom(), renameSection);
if (newContent.isActive() != branche.getUserActive()) {
branche.setUserActive(newContent.isActive());
EditionChangeActivity activity = new EditionChangeActivity();
@@ -86,7 +87,6 @@
branche.setNoeudAmont(noeudAmont);
branche.setNoeudAval(noeudAval);
-
if (requireDcsp(newType)) {
DonCalcSansPrt dcsp = EMHHelper.selectFirstInstanceOf(branche.getInfosEMH(), DonCalcSansPrt.class);
applyModification(newContent.getDcsp(), dcsp);
@@ -113,7 +113,8 @@
}
}
- private CatEMHBranche changeType(CrueConfigMetier ccm, final EMHSousModele sousModele, CatEMHBranche initBranche, BrancheEditionContent newContent, EnumBrancheType newType) {
+ private CatEMHBranche changeType(CrueConfigMetier ccm, final EMHSousModele sousModele, CatEMHBranche initBranche, BrancheEditionContent newContent,
+ EnumBrancheType newType) {
//on enleve les relations
List<RelationEMHSectionDansBranche> currentSections = initBranche.getListeSectionsSortedXP(ccm);
for (RelationEMHSectionDansBranche relationEMHSectionDansBranche : currentSections) {
@@ -159,7 +160,8 @@
//les sections...
CatEMHSection amont = currentSections.get(0).getEmh();
CatEMHSection aval = currentSections.get(currentSections.size() - 1).getEmh();
- Collection<EnumSectionType> authorizedType = ValidationContentSectionDansBrancheExecutor.createSectionInterneTypeDansBrancheContents().get(newType);
+ Collection<EnumSectionType> authorizedType = ValidationContentSectionDansBrancheExecutor.createSectionInterneTypeDansBrancheContents().
+ get(newType);
EditionCreateEMH creator = new EditionCreateEMH(defaultValues);
if (!authorizedType.contains(amont.getSectionType())) {
if (authorizedType.contains(EnumSectionType.EMHSectionSansGeometrie)) {
@@ -231,11 +233,12 @@
}
}
- private CtuluLog prevalidate(BrancheEditionContent newContent, CatEMHBranche branche, CatEMHNoeud noeudAmont, CatEMHNoeud noeudAval, CrueConfigMetier ccm) {
+ private CtuluLog prevalidate(BrancheEditionContent newContent, CatEMHBranche branche, CatEMHNoeud noeudAmont, CatEMHNoeud noeudAval,
+ CrueConfigMetier ccm, boolean renameSections) {
CtuluLog log = new CtuluLog(BusinessMessages.RESOURCE_BUNDLE);
EditionRename rename = new EditionRename();
if (!newContent.getNom().equals(branche.getNom())) {
- String nameValid = rename.isNameValid(branche, newContent.getNom());
+ String nameValid = rename.isNameValid(branche, newContent.getNom(), renameSections);
if (nameValid != null) {
log.addSevereError(nameValid);
}
@@ -278,11 +281,11 @@
}
int idx = 0;
for (RelationEMHSectionDansBrancheSaintVenant relationEMHSectionDansBrancheSaintVenant : saintVenantCoeff) {
- ValidationHelper.validateObject(BusinessMessages.getString("ChangeEMHBrancheSaintVenant.ValidationRelation", Integer.toString(++idx)), log, relationEMHSectionDansBrancheSaintVenant, ccm);
+ ValidationHelper.validateObject(BusinessMessages.getString("ChangeEMHBrancheSaintVenant.ValidationRelation", Integer.toString(++idx)), log,
+ relationEMHSectionDansBrancheSaintVenant, ccm);
}
}
-
return log;
}
Modified: trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionRename.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionRename.java 2014-02-03 13:33:27 UTC (rev 8596)
+++ trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/edition/EditionRename.java 2014-02-03 14:34:34 UTC (rev 8597)
@@ -5,7 +5,9 @@
import java.util.ArrayList;
import java.util.Collection;
+import java.util.HashMap;
import java.util.List;
+import java.util.Map;
import java.util.Set;
import org.apache.commons.lang.StringUtils;
import org.fudaa.dodico.crue.common.BusinessMessages;
@@ -33,8 +35,37 @@
}
emh.setNom(newName);
propagateName(emh);
+ return null;
+ }
-
+ public String rename(CatEMHBranche emh, String newName, boolean renameSection) {
+ //si section renommée, on vérifie d'abord qu'on peut le faire:
+ Map<EMH, String> map = new HashMap<EMH, String>();
+ if (renameSection) {
+ String oldSectionPrefix = CruePrefix.changePrefix(emh.getNom(), EnumCatEMH.SECTION);
+ String newSectionPref = CruePrefix.changePrefix(newName, EnumCatEMH.SECTION);
+ final List<RelationEMHSectionDansBranche> sections = emh.getSections();
+ for (RelationEMHSectionDansBranche relationEMHSectionDansBranche : sections) {
+ final CatEMHSection section = relationEMHSectionDansBranche.getEmh();
+ if (section.getNom().startsWith(oldSectionPrefix)) {
+ String newSectionName = newSectionPref + section.getNom().substring(oldSectionPrefix.length());
+ String newSectioNameValid = isNameValid(section, newSectionName);
+ if (newSectioNameValid != null) {
+ return newSectioNameValid;
+ }
+ map.put(section, newSectionName);
+ }
+ }
+ }
+ String error = rename(emh, newName);
+ if (error != null) {
+ return error;
+ }
+ if (renameSection) {
+ for (Map.Entry<EMH, String> entry : map.entrySet()) {
+ rename(entry.getKey(), entry.getValue());
+ }
+ }
return null;
}
@@ -52,15 +83,38 @@
batiCasier.setNom(CruePrefix.changePrefix(newCasierName, CruePrefix.P_CASIER, CruePrefix.P_BATI_CASIER));
}
}
-
-
/**
*
* @param emh
* @param newName
+ * @param renameSection true si les sections doivent être renommées.
* @return une chaine non vide si erreur
*/
+ public String isNameValid(CatEMHBranche emh, String newName, boolean renameSection) {
+ final String nameValid = isNameValid(emh, newName);
+ if (nameValid != null) {
+ return nameValid;
+ }
+ if (renameSection) {
+ String oldSectionPrefix = CruePrefix.changePrefix(emh.getNom(), EnumCatEMH.SECTION);
+ String newSectionPref = CruePrefix.changePrefix(newName, EnumCatEMH.SECTION);
+ final List<RelationEMHSectionDansBranche> sections = emh.getSections();
+ for (RelationEMHSectionDansBranche relationEMHSectionDansBranche : sections) {
+ final CatEMHSection section = relationEMHSectionDansBranche.getEmh();
+ if (section.getNom().startsWith(oldSectionPrefix)) {
+ String newSectionName = newSectionPref + section.getNom().substring(oldSectionPrefix.length());
+ String newSectioNameValid = isNameValid(section, newSectionName);
+ if (newSectioNameValid != null) {
+ return newSectioNameValid;
+ }
+ }
+ }
+ }
+ return null;
+
+ }
+
public String isNameValid(EMH emh, String newName) {
String nameValidei18nMessage = ValidationPatternHelper.isNameValidei18nMessage(newName, emh.getCatType());
if (nameValidei18nMessage != null) {
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/emh/ModellingEMHBrancheTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/emh/ModellingEMHBrancheTopComponent.java 2014-02-03 13:33:27 UTC (rev 8596)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/emh/ModellingEMHBrancheTopComponent.java 2014-02-03 14:34:34 UTC (rev 8597)
@@ -20,6 +20,7 @@
import org.fudaa.dodico.crue.metier.emh.CatEMHNoeud;
import org.fudaa.dodico.crue.metier.emh.EnumBrancheType;
import org.fudaa.dodico.crue.validation.util.DelegateValidatorBranche;
+import org.fudaa.fudaa.crue.common.helper.DialogHelper;
import org.fudaa.fudaa.crue.common.helper.ObjetNommeCellRenderer;
import org.fudaa.fudaa.crue.common.helper.ToStringInternationalizableCellRenderer;
import org.fudaa.fudaa.crue.common.log.LogsDisplayer;
@@ -212,7 +213,16 @@
EditionChangeBranche edition = new EditionChangeBranche(modellingConfigService.getDefaultValues());
currentCenter.second.fillWithData(modifications);
final CatEMHBranche emh = getEMH();
- CtuluLog log = edition.changeBranche(emh, modifications, getCcm());
+ boolean renameSection = false;
+ if (!modifications.getNom().equals(emh.getNom())) {
+ String optionRename = NbBundle.getMessage(ModellingEMHBrancheTopComponent.class, "BrancheChangeName.RenameSection");
+ String optionNot = NbBundle.getMessage(ModellingEMHBrancheTopComponent.class, "BrancheChangeName.NotRenameSection");
+ String dialogContent = org.openide.util.NbBundle.getMessage(ModellingEMHBrancheTopComponent.class, "BrancheChangeName.Content");
+ renameSection = optionRename.equals(DialogHelper.showQuestion(
+ getDisplayName(), dialogContent, new String[]{optionRename, optionNot}));
+ }
+
+ CtuluLog log = edition.changeBranche(emh, modifications, getCcm(), renameSection);
if (!log.containsErrorOrSevereError()) {
modellingScenarioModificationService.setScenarioModified(new ScenarioModificationEvent(EnumModification.EMH));
setModified(false);
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/emh/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/emh/Bundle.properties 2014-02-03 13:33:27 UTC (rev 8596)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/emh/Bundle.properties 2014-02-03 14:34:34 UTC (rev 8597)
@@ -51,3 +51,6 @@
Reference.Name=R\u00e9f\u00e9rence
Dz.Name=Dz
changeSection.ProfilSectionWillBeLost=Le ProfilSection associ\u00e9 \u00e0 cette section sera perdu. Voulez-vous continuer ?
+BrancheChangeName.RenameSection=Renommer les sections
+BrancheChangeName.NotRenameSection=Ne pas renommer
+BrancheChangeName.Content=<html><body>Le nom de la branche est modifi\u00e9e. Voulez-vous: <ul><li>Renommer les sections nomm\u00e9es pr\u00e9c\u00e9demment selon le nom de la branche</li><li>Ne renommer aucune section de la branche</li></ul></body></html>
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java 2014-02-03 13:33:27 UTC (rev 8596)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java 2014-02-03 14:34:34 UTC (rev 8597)
@@ -134,6 +134,9 @@
@Override
public boolean addGeometry(GrPolyligne _p, CtuluCommandContainer _cmd, CtuluUI _ui, ZEditionAttributesDataI _d) {
+ if (_p.nombre() == 0) {
+ return false;
+ }
PlanimetryControllerHelper helper = super.getLayerController().getHelper();
if (!helper.canEMHBeAddedAndDisplayError()) {
return false;
@@ -142,6 +145,7 @@
if (brancheType == null) {
return false;
}
+
GISPolyligne polyligne = _p.toGIS();
double length = polyligne.getLength();
CrueConfigMetier crueConfigMetier = helper.getController().getCrueConfigMetier();
@@ -180,9 +184,8 @@
updateNoeudAvalPosition(nodeController, noeudAvalIdx, polyligne);
}
-
-
- CatEMHBranche createBranche = new EditionCreateEMH(getLayerController().getDefaultValues()).createBranche(helper.getDefaultSousModele(), brancheType, noeudAmont,
+ CatEMHBranche createBranche = new EditionCreateEMH(getLayerController().getDefaultValues()).createBranche(helper.getDefaultSousModele(),
+ brancheType, noeudAmont,
noeudAval, crueConfigMetier, polyligne.getLength());
if (createBranche != null) {
StringBuilder info = new StringBuilder();
@@ -206,7 +209,8 @@
}
Object[] data = helper.getPlanimetryGisModelContainer().buildEdgeData(createBranche);
getGeometries().addGeometry(polyligne, data, null);
- DialogHelper.showNotifyOperationTermine(NbBundle.getMessage(PlanimetryBrancheModel.class, "Info.CreatedBranche", createBranche.getNom()), info.toString());
+ DialogHelper.showNotifyOperationTermine(NbBundle.getMessage(PlanimetryBrancheModel.class, "Info.CreatedBranche", createBranche.getNom()), info.
+ toString());
}
return true;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-03 22:09:39
|
Revision: 8600
http://sourceforge.net/p/fudaa/svn/8600
Author: deniger
Date: 2014-02-03 22:09:30 +0000 (Mon, 03 Feb 2014)
Log Message:
-----------
CRUE-610
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/UserPreferencesSaver.java
trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java
trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/action/ModellingShowViewListAction.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/actions/ReportShowViewListAction.java
Modified: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/UserPreferencesSaver.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/UserPreferencesSaver.java 2014-02-03 22:07:59 UTC (rev 8599)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/UserPreferencesSaver.java 2014-02-03 22:09:30 UTC (rev 8600)
@@ -179,7 +179,7 @@
return GraphicsEnvironment.getLocalGraphicsEnvironment().getDefaultScreenDevice();
}
- private static void ensureComponentWillBeVisible(final Component window, final Point initLocation) {
+ public static void ensureComponentWillBeVisible(final Component window, final Point initLocation) {
final Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
ensureComponentWillBeVisible(window, initLocation, screenSize);
Copied: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/action/ModellingShowViewListAction.java (from rev 8404, trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/action/ModellingHelpAction.java)
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/action/ModellingShowViewListAction.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/action/ModellingShowViewListAction.java 2014-02-03 22:09:30 UTC (rev 8600)
@@ -0,0 +1,56 @@
+package org.fudaa.fudaa.crue.modelling.action;
+
+import java.awt.MouseInfo;
+import java.awt.Point;
+import java.awt.event.ActionEvent;
+import java.util.Collection;
+import javax.swing.AbstractAction;
+import javax.swing.Action;
+import javax.swing.JPopupMenu;
+import javax.swing.JSeparator;
+import javax.swing.SwingUtilities;
+import org.fudaa.fudaa.crue.common.PerspectiveEnum;
+import org.fudaa.fudaa.crue.common.UserPreferencesSaver;
+import org.fudaa.fudaa.crue.common.action.AbstractPerspectiveAwareAction;
+import static org.fudaa.fudaa.crue.modelling.perspective.ActiveModelisation.ACTIONS_MODELLING_VIEWS;
+import org.openide.awt.*;
+import org.openide.util.Lookup;
+import org.openide.util.NbBundle;
+import org.openide.util.lookup.Lookups;
+import org.openide.windows.WindowManager;
+
+@ActionID(category = "View",
+ id = "org.fudaa.fudaa.crue.modelling.ModellingShowViewListAction")
+//iconBase ne semble pas fonctionner !
+@ActionRegistration(displayName = "#CTL_ModellingShowViewListAction")
+@ActionReference(path = "Shortcuts", name = "A-V")
+public final class ModellingShowViewListAction extends AbstractPerspectiveAwareAction {
+
+ public ModellingShowViewListAction() {
+ super(PerspectiveEnum.MODELLING, false);
+ putValue(Action.NAME, NbBundle.getMessage(ModellingShowViewListAction.class, "CTL_ModellingShowViewListAction"));
+ }
+
+ @Override
+ public void actionPerformed(ActionEvent e) {
+ JPopupMenu menu = new JPopupMenu();
+ Collection all = Lookups.forPath(ACTIONS_MODELLING_VIEWS).lookupAll(Object.class);
+ for (Object object : all) {
+ if (object instanceof AbstractAction) {
+ menu.add((AbstractAction) object);
+ } else if (object instanceof JSeparator) {
+ menu.addSeparator();
+ }
+ }
+ final Point location = MouseInfo.getPointerInfo().getLocation();
+ UserPreferencesSaver.ensureComponentWillBeVisible(menu, location);
+ SwingUtilities.convertPointFromScreen(location, WindowManager.getDefault().getMainWindow());
+ menu.show(WindowManager.getDefault().getMainWindow(), location.x, location.y);
+ }
+
+ @Override
+ public Action createContextAwareInstance(Lookup lkp) {
+ return new ModellingShowViewListAction();
+ }
+
+}
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties 2014-02-03 22:07:59 UTC (rev 8599)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties 2014-02-03 22:09:30 UTC (rev 8600)
@@ -10,6 +10,7 @@
CTL_ModellingLaunchRunQuickAction=Lancer un run rapide
CTL_ModellingLaunchRunOptionsAction=Lancer un run avec options...
CTL_ModellingHelpAction=Aide sur la perspective Mod\u00e9lisation
+CTL_ModellingShowViewListAction=Liste des vues perspective Mod\u00e9lisation
ModellingConvertCrue10.Action=Convertir en sc\u00e9nario Crue10
ModellingConvertCrue9.Action=Convertir en sc\u00e9nario Crue9
ExportFileChooser.ApproveText=Exporter
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java 2014-02-03 22:07:59 UTC (rev 8599)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java 2014-02-03 22:09:30 UTC (rev 8600)
@@ -92,7 +92,7 @@
return action;
}
- public void installSelectionShortcuts() {
+ public final void installSelectionShortcuts() {
Action selectAll = createAction("TOUTSELECTIONNER", KeyStroke.getKeyStroke(KeyEvent.VK_A, InputEvent.CTRL_MASK));
Action invAction = createAction("INVERSESELECTION", KeyStroke.getKeyStroke(KeyEvent.VK_I, InputEvent.CTRL_MASK));
Action clearAction = createAction("CLEARSELECTION", KeyStroke.getKeyStroke(KeyEvent.VK_A, InputEvent.CTRL_MASK | InputEvent.SHIFT_MASK));
@@ -140,11 +140,15 @@
SceneSelectPreviousAction sceneSelectPreviousAction = new SceneSelectPreviousAction(gisEditor_.getSceneEditor());
SceneSelectNextAction sceneSelectNextAction = new SceneSelectNextAction(gisEditor_.getSceneEditor());
CalqueSelectNormalSelectionAction normalSelection = new CalqueSelectNormalSelectionAction(gisEditor_.getSupport());
- EbliLib.updateMapKeyStroke(this, new Action[]{sceneSelectPreviousAction, sceneSelectNextAction, normalSelection});
+ final KeyStroke keyStroke = KeyStroke.getKeyStroke(KeyEvent.VK_S, InputEvent.ALT_MASK);
+ getScene().getAtomicSelectionAction().setKey(keyStroke);
+ EbliLib.updateMapKeyStroke(this, new Action[]{sceneSelectPreviousAction, sceneSelectNextAction, normalSelection, getScene().
+ getAtomicSelectionAction()});
installSelectionShortcuts();
selectNext = (JMenuItem) sceneSelectNextAction.buildMenuItem(EbliComponentFactory.INSTANCE);
selectPrevious = (JMenuItem) sceneSelectPreviousAction.buildMenuItem(EbliComponentFactory.INSTANCE);
FSigEditor.activeDeferredModificationAsDefault();
+ getScene().setUseSelectedLayerFirstForSelection(false);
}
public PlanimetryVisuPanelConfigurer getConfigurer() {
@@ -172,10 +176,10 @@
findSelectedLayer();
}
- @Override
- public void setEnabled(boolean _newValue) {
- }
- };
+ @Override
+ public void setEnabled(boolean _newValue) {
+ }
+ };
return res;
}
@@ -214,6 +218,7 @@
}
action.updateStateBeforeShow();
if (itemAtomicActivation == null) {
+ getScene().getAtomicSelectionAction().setKey(KeyStroke.getKeyStroke("Alt s"));
getScene().getAtomicSelectionAction().updateStateBeforeShow();
itemAtomicActivation = (JMenuItem) getScene().getAtomicSelectionAction().buildMenuItem(EbliComponentFactory.INSTANCE);
}
@@ -263,8 +268,6 @@
selection.add(selectPrevious);
selection.add(selectNext);
-
-
selection.addSeparator();
if (!EbliActionMap.getInstance().isEmpty()) {
addSelectionAction(selection, true);
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java 2014-02-03 22:07:59 UTC (rev 8599)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java 2014-02-03 22:09:30 UTC (rev 8600)
@@ -26,6 +26,7 @@
public PlanimetryLigneBriseeLayer(PlanimetryLigneBriseeLayerModel _modele, FSigEditor _editor) {
super(_modele, _editor);
+ setSelectClosedLineInterior(true);
}
@Override
Copied: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/actions/ReportShowViewListAction.java (from rev 8404, trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/actions/ReportCloseAction.java)
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/actions/ReportShowViewListAction.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/actions/ReportShowViewListAction.java 2014-02-03 22:09:30 UTC (rev 8600)
@@ -0,0 +1,54 @@
+package org.fudaa.fudaa.crue.report.actions;
+
+import java.awt.MouseInfo;
+import java.awt.Point;
+import java.awt.event.ActionEvent;
+import java.util.Collection;
+import javax.swing.AbstractAction;
+import javax.swing.Action;
+import javax.swing.JPopupMenu;
+import javax.swing.JSeparator;
+import javax.swing.SwingUtilities;
+import org.fudaa.fudaa.crue.common.PerspectiveEnum;
+import org.fudaa.fudaa.crue.common.UserPreferencesSaver;
+import org.fudaa.fudaa.crue.common.action.AbstractPerspectiveAwareAction;
+import static org.fudaa.fudaa.crue.report.perspective.ActiveReport.ACTIONS_REPORT_VIEWS;
+import org.openide.awt.ActionID;
+import org.openide.awt.ActionRegistration;
+import org.openide.util.Lookup;
+import org.openide.util.NbBundle;
+import org.openide.util.lookup.Lookups;
+import org.openide.windows.WindowManager;
+
+@ActionID(category = "View",
+ id = "org.fudaa.fudaa.crue.report.actions.ReportShowViewListAction")
+@ActionRegistration(displayName = "#CTL_ReportShowViewListAction")
+public final class ReportShowViewListAction extends AbstractPerspectiveAwareAction {
+
+ public ReportShowViewListAction() {
+ super(PerspectiveEnum.POST, false);
+ putValue(Action.NAME, NbBundle.getMessage(ReportShowViewListAction.class, "CTL_ReportShowViewListAction"));
+ }
+
+ @Override
+ public Action createContextAwareInstance(Lookup actionContext) {
+ return new ReportShowViewListAction();
+ }
+
+ @Override
+ public void actionPerformed(ActionEvent e) {
+ JPopupMenu menu = new JPopupMenu();
+ Collection all = Lookups.forPath(ACTIONS_REPORT_VIEWS).lookupAll(Object.class);
+ for (Object object : all) {
+ if (object instanceof AbstractAction) {
+ menu.add((AbstractAction) object);
+ } else if (object instanceof JSeparator) {
+ menu.addSeparator();
+ }
+ }
+ final Point location = MouseInfo.getPointerInfo().getLocation();
+ UserPreferencesSaver.ensureComponentWillBeVisible(menu, location);
+ SwingUtilities.convertPointFromScreen(location, WindowManager.getDefault().getMainWindow());
+ menu.show(WindowManager.getDefault().getMainWindow(), location.x, location.y);
+ }
+}
Modified: trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties 2014-02-03 22:07:59 UTC (rev 8599)
+++ trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties 2014-02-03 22:09:30 UTC (rev 8600)
@@ -1,4 +1,5 @@
CTL_ReportCloseAction=Fermer
+CTL_ReportShowViewListAction=Liste des vues perspective Rapports
CTL_ReportSaveAction=Sauvegarder
CTL_ReportReloadAction=Recharger
ReportSetAsAlternatifNodeAction.DisplayName=Utiliser comme run alternatif
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-07 08:04:29
|
Revision: 8602
http://sourceforge.net/p/fudaa/svn/8602
Author: deniger
Date: 2014-02-07 08:04:26 +0000 (Fri, 07 Feb 2014)
Log Message:
-----------
java 7 utilis?\195?\169 partout
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-compare/pom.xml
trunk/soft/fudaa-crue/crue-config/pom.xml
trunk/soft/fudaa-crue/crue-core/pom.xml
trunk/soft/fudaa-crue/crue-emh/pom.xml
trunk/soft/fudaa-crue/crue-io/pom.xml
trunk/soft/fudaa-crue/crue-otfa/pom.xml
trunk/soft/fudaa-crue/crue-project/pom.xml
trunk/soft/fudaa-crue/crue-sysdoc/pom.xml
trunk/soft/fudaa-crue/crue-test/pom.xml
trunk/soft/fudaa-crue/crue-validation/pom.xml
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/view/DefaultNodePasteType.java
trunk/soft/fudaa-crue/ui-emh/pom.xml
trunk/soft/fudaa-crue/ui-loader/pom.xml
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/AbstractModellingListEditionTopComponent.java
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ListBrancheContentNode.java
trunk/soft/fudaa-crue/ui-wrapper/pom.xml
Modified: trunk/soft/fudaa-crue/crue-compare/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-compare/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-compare/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -25,16 +25,9 @@
</execution>
</executions>
</plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/crue-config/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-config/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-config/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -27,14 +27,6 @@
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/crue-core/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-core/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-core/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -62,16 +62,9 @@
</execution>
</executions>
</plugin>
+
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/crue-emh/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-emh/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-emh/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -27,14 +27,6 @@
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/crue-io/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-io/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-io/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -23,14 +23,6 @@
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/crue-otfa/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-otfa/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -27,14 +27,6 @@
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/crue-project/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-project/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-project/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -27,14 +27,6 @@
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/crue-sysdoc/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-sysdoc/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-sysdoc/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -12,14 +12,6 @@
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>methods</parallel>
Modified: trunk/soft/fudaa-crue/crue-test/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-test/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-test/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -29,14 +29,6 @@
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>methods</parallel>
Modified: trunk/soft/fudaa-crue/crue-validation/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-validation/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/crue-validation/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -27,14 +27,6 @@
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<parallel>classes</parallel>
Modified: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/view/DefaultNodePasteType.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/view/DefaultNodePasteType.java 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/view/DefaultNodePasteType.java 2014-02-07 08:04:26 UTC (rev 8602)
@@ -4,8 +4,10 @@
import java.io.IOException;
import java.util.ArrayList;
import java.util.Arrays;
+import java.util.Iterator;
import java.util.List;
import org.apache.commons.collections.CollectionUtils;
+import org.fudaa.ctulu.CtuluLibArray;
import org.openide.nodes.Node;
import org.openide.util.datatransfer.PasteType;
@@ -15,7 +17,7 @@
*/
public class DefaultNodePasteType extends PasteType {
- final Node dragged;
+ final Node[] dragged;
final Node target;
public static final String PROP_USE_INDEX_AS_DISPLAY_NAME = "useIndexAsDisplayName";
@@ -32,6 +34,11 @@
}
public DefaultNodePasteType(Node dragged, Node target) {
+ this.dragged = new Node[]{dragged};
+ this.target = target;
+ }
+
+ public DefaultNodePasteType(Node[] dragged, Node target) {
this.dragged = dragged;
this.target = target;
}
@@ -66,7 +73,6 @@
node.setDisplayName(Integer.toString(++ordre));
}
-
}
public static void nodeToStart(final List<Node> toStart, boolean useIndexAsDisplayName) {
@@ -88,21 +94,33 @@
}
}
- protected static void nodeDragged(final Node dragged, final Node target) {
- if (dragged == null || target == null) {
+ protected static void nodeDragged(final Node[] dragged, final Node target) {
+ if (dragged == null || target == null || dragged.length == 0) {
return;
}
- boolean useIndexAsDisplayName = isIndexUsedAsDisplayName(dragged);
- Node parentNode = dragged.getParentNode();
+ boolean useIndexAsDisplayName = isIndexUsedAsDisplayName(target);
+ Node parentNode = target.getParentNode();
List<Node> children = new ArrayList(Arrays.asList(parentNode.getChildren().getNodes()));
+ for (Iterator<Node> it = children.iterator(); it.hasNext();) {
+ Node node = it.next();
+ if (node.getParentNode() != parentNode) {
+ it.remove();
+ }
+ }
parentNode.getChildren().remove(children.toArray(new Node[children.size()]));
int targetIdx = children.indexOf(target);
- children.remove(dragged);
- if (targetIdx >= children.size()) {
- children.add(dragged);
- } else {
- children.add(targetIdx, dragged);
+ if (targetIdx < children.indexOf(dragged[0])) {
+ CtuluLibArray.invert(dragged, 0);
}
+ for (Node node : dragged) {
+ children.remove(node);
+ if (targetIdx >= children.size()) {
+ children.add(node);
+ } else {
+ children.add(targetIdx, node);
+ }
+ }
+
parentNode.getChildren().add(children.toArray(new Node[children.size()]));
if (useIndexAsDisplayName) {
updateIndexedDisplayName(parentNode);
Modified: trunk/soft/fudaa-crue/ui-emh/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-emh/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/ui-emh/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -140,17 +140,7 @@
</plugin>
<plugin>
- <!-- NetBeans 6.9+ requires JDK 6 -->
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- <configuration>
- <source>1.6</source>
- <target>1.6</target>
- </configuration>
- </plugin>
-
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<!-- to have the jar plugin pickup the nbm generated manifest -->
Modified: trunk/soft/fudaa-crue/ui-loader/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-loader/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/ui-loader/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -93,11 +93,6 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- </plugin>
-
- <plugin>
- <groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<useDefaultManifestFile>true</useDefaultManifestFile>
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/AbstractModellingListEditionTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/AbstractModellingListEditionTopComponent.java 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/AbstractModellingListEditionTopComponent.java 2014-02-07 08:04:26 UTC (rev 8602)
@@ -1,8 +1,12 @@
package org.fudaa.fudaa.crue.modelling.list;
+import java.awt.Rectangle;
import java.awt.event.MouseAdapter;
import java.awt.event.MouseEvent;
+import java.awt.event.MouseMotionAdapter;
+import java.awt.event.MouseMotionListener;
import java.util.List;
+import javax.swing.JComponent;
import org.apache.commons.lang.ArrayUtils;
import org.fudaa.dodico.crue.metier.emh.EMH;
import org.fudaa.dodico.crue.metier.emh.EMHScenario;
@@ -28,6 +32,7 @@
protected void createComponent(String firstColumnName) {
super.createComponent(firstColumnName);
outlineView.setDefaultActionAllowed(true);
+ outlineView.getOutline().setAutoscrolls(true);
outlineView.setNodePopupFactory(new ListNodePopupFactory(this));
outlineView.getOutline().addMouseListener(new MouseAdapter() {
@Override
@@ -43,7 +48,19 @@
}
}
});
+// outlineView.scrollRectToVisible(null);
+ MouseMotionListener doScrollRectToVisible = new MouseMotionAdapter() {
+ public void mouseDragged(MouseEvent e) {
+ System.err.println("e " + e.getY() + " " + outlineView.getOutline().getAutoscrolls());
+ Rectangle r = new Rectangle(0, e.getY(), 10, 10);
+// outlineView.scrollRectToVisible(r);
+// ((JComponent) e.getSource()).scrollRectToVisible(r);
+ outlineView.getOutline().scrollRectToVisible(r);
+ }
+ };
+ outlineView.getOutline().addMouseMotionListener(doScrollRectToVisible);
+
}
/**
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ListBrancheContentNode.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ListBrancheContentNode.java 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ListBrancheContentNode.java 2014-02-07 08:04:26 UTC (rev 8602)
@@ -62,7 +62,7 @@
@Override
public PasteType getDropType(Transferable t, int action, int index) {
if (isEditMode()) {
- final Node dragged = NodeTransfer.node(t, NodeTransfer.DND_COPY_OR_MOVE);
+ final Node[] dragged = NodeTransfer.nodes(t, NodeTransfer.DND_COPY_OR_MOVE);
return new DefaultNodePasteType(dragged, this);
}
return null;
@@ -105,7 +105,6 @@
active.setDisplayName(AbstractListContentNode.getActiveDisplay());
set.put(active);
-
CrueConfigMetier propDefinition = modellingScenarioService.getSelectedProjet().getPropDefinition();
NumberFormat formatter = propDefinition.getFormatter(CrueConfigMetierConstants.PROP_XP, DecimalFormatEpsilonEnum.COMPARISON);
String longeurFormatted = null;
Modified: trunk/soft/fudaa-crue/ui-wrapper/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-wrapper/pom.xml 2014-02-05 08:08:45 UTC (rev 8601)
+++ trunk/soft/fudaa-crue/ui-wrapper/pom.xml 2014-02-07 08:04:26 UTC (rev 8602)
@@ -95,11 +95,6 @@
</configuration>
</plugin>
- <plugin>
- <!-- NetBeans 6.9+ requires JDK 6 -->
- <groupId>org.apache.maven.plugins</groupId>
- <artifactId>maven-compiler-plugin</artifactId>
- </plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-11 15:49:33
|
Revision: 8610
http://sourceforge.net/p/fudaa/svn/8610
Author: deniger
Date: 2014-02-11 15:49:31 +0000 (Tue, 11 Feb 2014)
Log Message:
-----------
edition axe avec 2-click
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-application/pom.xml
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryControllerBuilder.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/listener/SectionTraceSelectionSynchronizer.java
Modified: trunk/soft/fudaa-crue/ui-application/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-application/pom.xml 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-application/pom.xml 2014-02-11 15:49:31 UTC (rev 8610)
@@ -103,7 +103,7 @@
<artifactId>nbm-maven-plugin</artifactId>
<extensions>true</extensions>
<configuration>
- <finalName>Fudaa-Crue-${version}</finalName>
+ <finalName>Fudaa-Crue-${project.version}</finalName>
<etcConfFile>src/main/resources/etc/fudaacrue.conf</etcConfFile>
</configuration>
</plugin>
@@ -120,7 +120,7 @@
<groupId>org.codehaus.mojo</groupId>
<artifactId>nbm-maven-plugin</artifactId>
<configuration>
- <finalName>Dev-Fudaa-Crue-${version}</finalName>
+ <finalName>Dev-Fudaa-Crue-${project.version}</finalName>
<etcConfFile>src/main/resources/etc/fudaacrueDev.conf</etcConfFile>
</configuration>
</plugin>
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -149,6 +149,7 @@
selectPrevious = (JMenuItem) sceneSelectPreviousAction.buildMenuItem(EbliComponentFactory.INSTANCE);
FSigEditor.activeDeferredModificationAsDefault();
getScene().setUseSelectedLayerFirstForSelection(false);
+ setAddNbSelectionInInfo(true);
}
public PlanimetryVisuPanelConfigurer getConfigurer() {
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryControllerBuilder.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryControllerBuilder.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryControllerBuilder.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -7,6 +7,7 @@
import org.fudaa.fudaa.crue.planimetry.layer.PlanimetryCLimMLayer;
import org.fudaa.fudaa.crue.planimetry.layer.PlanimetrySectionLayer;
import org.fudaa.fudaa.crue.planimetry.layer.PlanimetryTraceLayer;
+import org.fudaa.fudaa.crue.planimetry.listener.SectionTraceSelectionSynchronizer;
/**
*
@@ -47,6 +48,7 @@
groupHydraulic.enPremier(nodeController.getLayer());
groupHydraulic.enPremier(sectionController.getLayer());
groupHydraulic.enPremier(condLimiteController.getLayer());
+ new SectionTraceSelectionSynchronizer(res.getScene(), traceController.getLayer(), sectionController.getLayer()).install();
}
}
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -107,6 +107,9 @@
@Override
protected boolean isPainted(int idx, GrMorphisme _versEcran) {
+ if (isSelected(idx)) {
+ return true;
+ }
boolean res = super.isPainted(idx, _versEcran);
if (!res) {
return false;
@@ -165,7 +168,8 @@
TraceIcon icon = super.layerConfiguration.getMiddleIcon(branche, modeleDonnees(), segment);
icon.paintIconCentre(_g, pt.x_, pt.y_);
if (layerConfiguration.getLabelConfiguration().isDisplayLabels()) {
- labelPainter.paintLabels(_g, pt, layerConfiguration.getDisplayName(branche, modeleDonnees(), isSelected(i)), layerConfiguration.getLabelConfiguration(), alpha_);
+ labelPainter.paintLabels(_g, pt, layerConfiguration.getDisplayName(branche, modeleDonnees(), isSelected(i)), layerConfiguration.
+ getLabelConfiguration(), alpha_);
}
}
}
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -116,6 +116,9 @@
* @return true si l'emh active/inactive peut être dessinée
*/
protected boolean isActivityPainted(int idx) {
+ if (isSelected(idx)) {
+ return true;
+ }
CatEMHCasier casier = getCasierController().getEMHFromPositionInModel(idx);
PlanimetryControllerHelper helper = getCasierController().getHelper();
if (!helper.isVisible(casier)) {
@@ -228,7 +231,6 @@
getLabelConfiguration(), alpha_);
}
-
}
}
}
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryLigneBriseeLayer.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -4,7 +4,10 @@
import org.fudaa.ctulu.CtuluCommandContainer;
import org.fudaa.ctulu.CtuluListSelection;
import org.fudaa.ctulu.CtuluUI;
+import org.fudaa.ebli.calque.ZSceneSelection;
import org.fudaa.ebli.calque.dessin.DeForme;
+import org.fudaa.ebli.commun.EbliListeSelectionMulti;
+import org.fudaa.ebli.commun.EbliSelectionState;
import org.fudaa.ebli.geometrie.GrBoite;
import org.fudaa.ebli.geometrie.GrMorphisme;
import org.fudaa.ebli.geometrie.GrPoint;
@@ -87,6 +90,7 @@
if (seg.distanceXY(_ptReel) < distanceReel) {
GrPoint ptOnSeg = seg.pointPlusProcheXY(_ptReel);
modeleDonnees().addPoint(i, j - 1, ptOnSeg.x_, ptOnSeg.y_, null, _cmd);
+ atomAdded(i, j - 1);
return true;
}
}
@@ -95,7 +99,9 @@
modele_.point(seg.o_, i, modele_.getNbPointForGeometry(i) - 1);
if (seg.distanceXY(_ptReel) < distanceReel) {
GrPoint ptOnSeg = seg.pointPlusProcheXY(_ptReel);
- modeleDonnees().addPoint(i, modele_.getNbPointForGeometry(i) - 1, ptOnSeg.x_, ptOnSeg.y_, null, _cmd);
+ final int idxAdded = modele_.getNbPointForGeometry(i) - 1;
+ modeleDonnees().addPoint(i, idxAdded, ptOnSeg.x_, ptOnSeg.y_, null, _cmd);
+ atomAdded(i, idxAdded);
return true;
}
}
@@ -104,6 +110,18 @@
}
@Override
+ protected void atomAdded(int geomIdx, int idxOneLine) {
+ FSigEditor editor = (FSigEditor) getEditor();
+ editor.getSceneEditor().getScene().setSelectionMode(SelectionMode.ATOMIC);
+ editor.getSceneEditor().getScene().clearSelection();
+ ZSceneSelection select = new ZSceneSelection(editor.getSceneEditor().getScene());
+ EbliListeSelectionMulti multi = new EbliListeSelectionMulti(1);
+ multi.add(geomIdx, idxOneLine + 1);
+ select.addLayerListSelectionMulti(this, multi);
+ editor.getSceneEditor().getScene().changeSelection(select, EbliSelectionState.ACTION_REPLACE);
+ }
+
+ @Override
protected void initTrace(TraceIconModel _icon, int _idxPoly) {
if (!isSelected(_idxPoly) && getSelectionMode() != SelectionMode.ATOMIC) {
_icon.setType(TraceIcon.RIEN);
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -25,46 +25,46 @@
*/
public class PlanimetryNodeLayer extends PlanimetryPointLayer<NodeConfiguration>
implements LayerWithCascadeDeleteAction, PlanimetryLayerWithEMHContrat, CalqueWithDynamicActions {
-
+
public PlanimetryNodeLayer(PlanimetryNodeLayerModel _modele, FSigEditor _editor) {
super(_modele, _editor);
}
-
+
LayerNodeController getNoeudController() {
return (LayerNodeController) (((PlanimetryPointLayerModel) modeleDonnees()).getLayerController());
}
-
+
@Override
public PlanimetryNodeLayerModel modeleDonnees() {
return (PlanimetryNodeLayerModel) super.modeleDonnees();
}
-
+
@Override
public EbliFindActionInterface getFinder() {
return new PlanimetryFindEMHLayerAction(this);
}
-
+
@Override
public String editSelected() {
getActions()[0].actionPerformed(null);
return null;
}
-
+
@Override
public LayerControllerEMH getLayerControllerEMH() {
return (LayerControllerEMH) getLayerController();
}
-
+
@Override
public boolean isMovable() {
return false;
}
-
+
@Override
public boolean isTitleModifiable() {
return false;
}
-
+
@Override
public void fillPopup(BuPopupMenu popup) {
if (isEditable() && isOnlyOneObjectSelected()) {
@@ -74,13 +74,13 @@
dclmController.fillPopupMenu(emh, popup);
}
}
-
+
@Override
public GrBoite getDomaine() {
GrBoite boite = super.getDomaine();
return boite;
}
-
+
@Override
public void removeCascadeSelectedObjects() {
if (!isSelectionEmpty()) {
@@ -90,9 +90,12 @@
}
}
}
-
+
@Override
protected boolean isPainted(int idx) {
+ if (getLayerSelection().isSelected(idx)) {
+ return true;
+ }
CatEMHNoeud noeud = getNoeudController().getEMHFromPositionInModel(idx);
PlanimetryControllerHelper helper = getNoeudController().getHelper();
if (!helper.isVisible(noeud)) {
@@ -104,13 +107,13 @@
}
return res;
}
-
+
@Override
public boolean canAddForme(int _typeForme) {
return isEditable() && _typeForme == DeForme.POINT;
}
LabelPainter painter = new LabelPainter();
-
+
@Override
protected void paintLabels(final Graphics2D g2d, int idx, GrPoint pEcran) {
LabelConfiguration labelConfiguration = layerConfiguration.getLabelConfiguration();
@@ -118,7 +121,8 @@
return;
}
CatEMHNoeud noeud = getNoeudController().getNoeud(idx);
- String nom = layerConfiguration.getDisplayedLabel(noeud, (PlanimetryNodeLayerModel) modeleDonnees(), selection_ != null && selection_.isSelected(idx));
+ String nom = layerConfiguration.getDisplayedLabel(noeud, (PlanimetryNodeLayerModel) modeleDonnees(), selection_ != null && selection_.isSelected(
+ idx));
painter.paintLabels(g2d, pEcran, nom, labelConfiguration, alpha_);
}
}
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -26,7 +26,8 @@
*
* @author deniger ( genesis)
*/
-public class PlanimetrySectionLayer extends PlanimetryPointLayer<SectionConfiguration> implements LayerWithCascadeDeleteAction, PlanimetryLayerWithEMHContrat {
+public class PlanimetrySectionLayer extends PlanimetryPointLayer<SectionConfiguration> implements LayerWithCascadeDeleteAction,
+ PlanimetryLayerWithEMHContrat {
public PlanimetrySectionLayer(PlanimetrySectionLayerModel _modele, FSigEditor _editor) {
super(_modele, _editor);
@@ -94,6 +95,9 @@
@Override
protected boolean isPainted(int idx) {
+ if (getLayerSelection().isSelected(idx)) {
+ return true;
+ }
boolean res = super.isPainted(idx);
CatEMHSection section = getController().getEMHFromPositionInModel(idx);
PlanimetryControllerHelper helper = getLayerController().getHelper();
@@ -123,7 +127,8 @@
continue;
}
RelationEMHSectionDansBranche sectionDansBranche = getController().getRelationEMHSectionDansBranche(i);
- final String nom = getLayerConfiguration().getDisplayName(sectionDansBranche.getEmh(), modeleDonnees(), selection_ != null && selection_.isSelected(i));
+ final String nom = getLayerConfiguration().getDisplayName(sectionDansBranche.getEmh(), modeleDonnees(), selection_ != null && selection_.
+ isSelected(i));
if (!uidDone.contains(sectionDansBranche.getEmh().getUiId())) {
modele_.point(pt, i, true);
if (!_clipReel.contientXY(pt)) {
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java 2014-02-11 15:48:26 UTC (rev 8609)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -83,6 +83,9 @@
@Override
protected boolean isPainted(int idx, GrMorphisme _versEcran) {
boolean res = super.isPainted(idx, _versEcran);
+ if (isSelected(idx)) {
+ return true;
+ }
if (!res) {
return false;
}
Added: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/listener/SectionTraceSelectionSynchronizer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/listener/SectionTraceSelectionSynchronizer.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/listener/SectionTraceSelectionSynchronizer.java 2014-02-11 15:49:31 UTC (rev 8610)
@@ -0,0 +1,66 @@
+/*
+ GPL 2
+ */
+package org.fudaa.fudaa.crue.planimetry.listener;
+
+import java.util.HashSet;
+import java.util.Set;
+import org.fudaa.ctulu.CtuluListSelection;
+import org.fudaa.ebli.calque.ZScene;
+import org.fudaa.ebli.calque.ZSelectionEvent;
+import org.fudaa.ebli.calque.ZSelectionListener;
+import org.fudaa.ebli.commun.EbliSelectionState;
+import org.fudaa.fudaa.crue.planimetry.layer.PlanimetryLayerWithEMHContrat;
+import org.fudaa.fudaa.crue.planimetry.layer.PlanimetrySectionLayer;
+import org.fudaa.fudaa.crue.planimetry.layer.PlanimetryTraceLayer;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class SectionTraceSelectionSynchronizer implements ZSelectionListener {
+
+ private final PlanimetryTraceLayer trace;
+ private final PlanimetrySectionLayer section;
+ private final ZScene scene;
+ private boolean updating;
+
+ public SectionTraceSelectionSynchronizer(ZScene scene, PlanimetryTraceLayer trace, PlanimetrySectionLayer section) {
+ this.trace = trace;
+ this.section = section;
+ this.scene = scene;
+ }
+
+ public void install() {
+ trace.addSelectionListener(this);
+ section.addSelectionListener(this);
+ }
+
+ @Override
+ public void selectionChanged(ZSelectionEvent _evt) {
+ if (updating) {
+ return;
+ }
+ updating = true;
+ PlanimetryLayerWithEMHContrat source = (PlanimetryLayerWithEMHContrat) _evt.getSource();
+ Set<Long> uidSelected = new HashSet<>();
+ if (source == section) {
+ section.getLayerController().getSelectedEMHs(uidSelected);
+ } else {
+ trace.getLayerController().getSelectedEMHs(uidSelected);
+ }
+ if (scene.isRestrictedToCalqueActif()) {
+ scene.setCalqueActif(trace);
+ trace.getLayerController().setSelectedEMHUids(uidSelected);
+ } else {
+ if (source == section) {
+ trace.getLayerController().setSelectedEMHUids(uidSelected);
+ } else {
+ section.getLayerController().setSelectedEMHUids(uidSelected);
+ }
+ }
+ scene.fireSelectionEvent();
+ updating = false;
+ }
+
+}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-14 08:34:11
|
Revision: 8618
http://sourceforge.net/p/fudaa/svn/8618
Author: deniger
Date: 2014-02-14 08:34:06 +0000 (Fri, 14 Feb 2014)
Log Message:
-----------
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerBrancheController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerCasierController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerNodeController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerSectionController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerTraceController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportLayersTreeComponent.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerBrancheController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerBrancheController.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerBrancheController.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -190,9 +190,6 @@
}
public boolean setSelectedEMHs(List<EMH> selectedEMH) {
- if (!layer.isVisible()) {
- return false;
- }
List<EMH> selectEMHS = EMHHelper.selectEMHS(selectedEMH, EnumCatEMH.BRANCHE);
TIntArrayList positions = new TIntArrayList();
for (EMH emh : selectEMHS) {
@@ -206,9 +203,6 @@
}
public boolean setSelectedEMHUids(Collection<Long> selectedUid) {
- if (!layer.isVisible()) {
- return false;
- }
TIntArrayList positions = new TIntArrayList();
for (Long uid : selectedUid) {
int nodePosition = getBranchePosition(uid);
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerCasierController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerCasierController.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerCasierController.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -127,9 +127,6 @@
}
public boolean setSelectedEMHs(List<EMH> selectedEMH) {
- if (!layer.isVisible()) {
- return false;
- }
List<EMH> selectEMHS = EMHHelper.selectEMHS(selectedEMH, EnumCatEMH.CASIER);
TIntArrayList positions = new TIntArrayList();
for (EMH emh : selectEMHS) {
@@ -143,9 +140,6 @@
}
public boolean setSelectedEMHUids(Collection<Long> selectedUids) {
- if (!layer.isVisible()) {
- return false;
- }
TIntArrayList positions = new TIntArrayList();
for (Long uid : selectedUids) {
int nodePosition = getCasierPosition(uid);
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerNodeController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerNodeController.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerNodeController.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -151,9 +151,6 @@
}
public boolean setSelectedEMHs(List<EMH> selectedEMH) {
- if (!layer.isVisible()) {
- return false;
- }
List<EMH> selectEMHS = EMHHelper.selectEMHS(selectedEMH, EnumCatEMH.NOEUD);
TIntArrayList positions = new TIntArrayList();
for (EMH emh : selectEMHS) {
@@ -167,9 +164,6 @@
}
public boolean setSelectedEMHUids(Collection<Long> selectedEMHUids) {
- if (!layer.isVisible()) {
- return false;
- }
TIntArrayList positions = new TIntArrayList();
for (Long uid : selectedEMHUids) {
int nodePosition = getNodePosition(uid);
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerSectionController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerSectionController.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerSectionController.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -101,9 +101,6 @@
}
public boolean setSelectedEMHs(List<EMH> selectedEMH) {
- if (!layer.isVisible()) {
- return false;
- }
List<EMH> selectEMHS = EMHHelper.selectEMHS(selectedEMH, EnumCatEMH.SECTION);
TIntArrayList positions = new TIntArrayList();
if (!selectEMHS.isEmpty()) {
@@ -126,9 +123,6 @@
}
public boolean setSelectedEMHUids(Collection<Long> uids) {
- if (!layer.isVisible()) {
- return false;
- }
TIntArrayList positions = new TIntArrayList();
if (!uids.isEmpty()) {
GISZoneCollectionPoint gisCollection = getGISCollection();
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerTraceController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerTraceController.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/LayerTraceController.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -105,9 +105,6 @@
}
public boolean setSelectedEMHs(List<EMH> selectedEMH) {
- if (!layer.isVisible()) {
- return false;
- }
List<EMH> selectEMHS = EMHHelper.selectEMHS(selectedEMH, EnumCatEMH.SECTION);
TIntArrayList positions = new TIntArrayList();
if (!selectEMHS.isEmpty()) {
@@ -130,9 +127,6 @@
}
public boolean setSelectedEMHUids(Collection<Long> uids) {
- if (!layer.isVisible()) {
- return false;
- }
TIntArrayList positions = new TIntArrayList();
if (!uids.isEmpty()) {
GISZoneCollectionLigneBrisee gisCollection = getGISCollection();
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -48,16 +48,27 @@
@Override
public void setView(final ZEbliCalquesPanel view) {
super.setView(view);
- view.getVueCalque().removeKeyListener(cqCatchI_);
- removeCalqueInteraction(cqCatchI_);
+// view.getVueCalque().removeKeyListener(cqCatchI_);
+// removeCalqueInteraction(cqCatchI_);
+ cqCatchI_.setGele(true);
view.getVueCalque().addKeyListener(new KeyAdapter() {
@Override
public void keyPressed(KeyEvent e) {
super.keyPressed(e);
if (e.getKeyCode() == KeyEvent.VK_ESCAPE) {
getCqSelectionI().setGele(false);
+ } else if (e.getKeyCode() == KeyEvent.VK_A) {
+ cqCatchI_.setGele(false);
}
}
+
+ @Override
+ public void keyReleased(KeyEvent e) {
+ if (e.getKeyCode() == KeyEvent.VK_A) {
+ cqCatchI_.setGele(true);
+ }
+ }
+
});
new PlanimetryAccrocheController((PlanimetryVisuPanel) view).install();
SelectionMoveInteraction selection = (SelectionMoveInteraction) getCalqueInteraction("cqSELECTION");
@@ -85,7 +96,6 @@
}
DeleteEMHCascadeAction deleteCascadeAction;
-
public DeleteEMHCascadeAction getDeleteCascade() {
if (deleteCascadeAction == null) {
deleteCascadeAction = new DeleteEMHCascadeAction(getVisuPanel().getEditor());
@@ -149,11 +159,11 @@
EbliActionPaletteAbstract ebliActionPaletteAbstract = new EbliActionPaletteAbstract(EbliLib.getS("Légende"),
EbliResource.EBLI.getToolIcon("legend"),
"EDIT_LEGEND", true) {
- @Override
- public JComponent buildContentPane() {
- return new BCalqueLegendeCustomizer(getView().getCqLegend());
- }
- };
+ @Override
+ public JComponent buildContentPane() {
+ return new BCalqueLegendeCustomizer(getView().getCqLegend());
+ }
+ };
ebliActionPaletteAbstract.setParent(pn_);
l.add(ebliActionPaletteAbstract);
standardActionGroup_ = new EbliActionInterface[l.size()];
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheLayer.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -105,11 +105,40 @@
return layerConfiguration.getFlecheSize();
}
+ private boolean userVisible = true;
+
@Override
+ public boolean isUserVisible() {
+ return userVisible;
+ }
+
+ @Override
+ public void setUserVisible(boolean userVisible) {
+ if (this.userVisible != userVisible) {
+ super.setUserVisible(userVisible);
+ this.userVisible = userVisible;
+ clearCacheAndRepaint();
+ }
+ }
+
+ @Override
+ public boolean isVisible() {
+ return !isSelectionEmpty() || isUserVisible();
+ }
+
+ @Override
+ protected boolean clearSelectionIfLayerNonVisible() {
+ return false;
+ }
+
+ @Override
protected boolean isPainted(int idx, GrMorphisme _versEcran) {
if (isSelected(idx)) {
return true;
}
+ if (!isUserVisible()) {
+ return false;
+ }
boolean res = super.isPainted(idx, _versEcran);
if (!res) {
return false;
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCasierLayer.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -119,6 +119,9 @@
if (isSelected(idx)) {
return true;
}
+ if (!isUserVisible()) {
+ return false;
+ }
CatEMHCasier casier = getCasierController().getEMHFromPositionInModel(idx);
PlanimetryControllerHelper helper = getCasierController().getHelper();
if (!helper.isVisible(casier)) {
@@ -130,7 +133,28 @@
return true;
}
+ private boolean userVisible = true;
+
@Override
+ public boolean isUserVisible() {
+ return userVisible;
+ }
+
+ @Override
+ public void setUserVisible(boolean userVisible) {
+ if (this.userVisible != userVisible) {
+ super.setUserVisible(userVisible);
+ this.userVisible = userVisible;
+ clearCacheAndRepaint();
+ }
+ }
+
+ @Override
+ public boolean isVisible() {
+ return !isSelectionEmpty() || isUserVisible();
+ }
+
+ @Override
protected boolean isPainted(int idx, GrMorphisme _versEcran) {
return isActivityPainted(idx) && isPaintedAsPolyligne(idx, _versEcran);
}
@@ -168,6 +192,11 @@
LabelPainter labelPainter = new LabelPainter();
@Override
+ protected boolean clearSelectionIfLayerNonVisible() {
+ return false;
+ }
+
+ @Override
protected Color getSurfaceSpecColor(int i, Color initColor) {
CatEMHCasier casier = getCasierController().getCasier(i);
Color res = layerConfiguration.getFond(casier, modeleDonnees());
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryNodeLayer.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -2,9 +2,11 @@
import com.memoire.bu.BuPopupMenu;
import java.awt.Graphics2D;
+import org.fudaa.ctulu.CtuluListSelection;
import org.fudaa.dodico.crue.metier.emh.CatEMHNoeud;
import org.fudaa.dodico.crue.metier.emh.EMH;
import org.fudaa.ebli.calque.dessin.DeForme;
+import org.fudaa.ebli.controle.BSelecteurCheckBox;
import org.fudaa.ebli.find.EbliFindActionInterface;
import org.fudaa.ebli.geometrie.GrBoite;
import org.fudaa.ebli.geometrie.GrPoint;
@@ -56,6 +58,32 @@
}
@Override
+ protected boolean clearSelectionIfLayerNonVisible() {
+ return false;
+ }
+
+ private boolean userVisible = true;
+
+ @Override
+ public boolean isUserVisible() {
+ return userVisible;
+ }
+
+ @Override
+ public void setUserVisible(boolean userVisible) {
+ if (this.userVisible != userVisible) {
+ super.setUserVisible(userVisible);
+ this.userVisible = userVisible;
+ clearCacheAndRepaint();
+ }
+ }
+
+ @Override
+ public boolean isVisible() {
+ return !isSelectionEmpty() || isUserVisible();
+ }
+
+ @Override
public boolean isMovable() {
return false;
}
@@ -96,6 +124,9 @@
if (getLayerSelection().isSelected(idx)) {
return true;
}
+ if (!isUserVisible()) {
+ return false;
+ }
CatEMHNoeud noeud = getNoeudController().getEMHFromPositionInModel(idx);
PlanimetryControllerHelper helper = getNoeudController().getHelper();
if (!helper.isVisible(noeud)) {
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetrySectionLayer.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -94,10 +94,18 @@
}
@Override
+ protected boolean clearSelectionIfLayerNonVisible() {
+ return false;
+ }
+
+ @Override
protected boolean isPainted(int idx) {
if (getLayerSelection().isSelected(idx)) {
return true;
}
+ if (!isUserVisible()) {
+ return false;
+ }
boolean res = super.isPainted(idx);
CatEMHSection section = getController().getEMHFromPositionInModel(idx);
PlanimetryControllerHelper helper = getLayerController().getHelper();
@@ -110,7 +118,28 @@
return res;
}
+ private boolean userVisible = true;
+
@Override
+ public boolean isUserVisible() {
+ return userVisible;
+ }
+
+ @Override
+ public void setUserVisible(boolean userVisible) {
+ if (this.userVisible != userVisible) {
+ super.setUserVisible(userVisible);
+ this.userVisible = userVisible;
+ clearCacheAndRepaint();
+ }
+ }
+
+ @Override
+ public boolean isVisible() {
+ return !isSelectionEmpty() || isUserVisible();
+ }
+
+ @Override
public void paintDonnees(Graphics2D _g, GrMorphisme _versEcran, GrMorphisme _versReel, GrBoite _clipReel) {
if (!isVisible()) {
return;
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -10,6 +10,7 @@
import javax.swing.SwingConstants;
import org.apache.commons.collections.CollectionUtils;
import org.apache.commons.lang.StringUtils;
+import org.fudaa.ctulu.CtuluListSelection;
import org.fudaa.ctulu.gis.GISPolyligne;
import org.fudaa.ctulu.gis.GisAbscCurviligneToCoordinate;
import org.fudaa.dodico.crue.config.comparator.XtComparator;
@@ -20,6 +21,8 @@
import org.fudaa.dodico.crue.metier.emh.LitNumerote;
import org.fudaa.dodico.crue.metier.emh.PtProfil;
import org.fudaa.dodico.crue.metier.helper.EMHHelper;
+import org.fudaa.ebli.commun.EbliListeSelectionMultiInterface;
+import org.fudaa.ebli.controle.BSelecteurCheckBox;
import org.fudaa.ebli.find.EbliFindActionInterface;
import org.fudaa.ebli.geometrie.GrBoite;
import org.fudaa.ebli.geometrie.GrMorphisme;
@@ -38,7 +41,8 @@
*
* @author deniger ( genesis)
*/
-public class PlanimetryTraceLayer extends PlanimetryLigneBriseeLayer<TraceConfiguration> implements LayerWithCascadeDeleteAction, PlanimetryLayerWithEMHContrat {
+public class PlanimetryTraceLayer extends PlanimetryLigneBriseeLayer<TraceConfiguration> implements LayerWithCascadeDeleteAction,
+ PlanimetryLayerWithEMHContrat {
public PlanimetryTraceLayer(PlanimetryTraceLayerModel _modele, FSigEditor _editor) {
super(_modele, _editor);
@@ -60,6 +64,32 @@
}
@Override
+ protected boolean clearSelectionIfLayerNonVisible() {
+ return false;
+ }
+
+ private boolean userVisible = true;
+
+ @Override
+ public boolean isUserVisible() {
+ return userVisible;
+ }
+
+ @Override
+ public void setUserVisible(boolean userVisible) {
+ if (this.userVisible != userVisible) {
+ super.setUserVisible(userVisible);
+ this.userVisible = userVisible;
+ clearCacheAndRepaint();
+ }
+ }
+
+ @Override
+ public boolean isVisible() {
+ return !isSelectionEmpty() || isUserVisible();
+ }
+
+ @Override
public String editSelected() {
getActions()[0].actionPerformed(null);
return null;
@@ -82,10 +112,13 @@
@Override
protected boolean isPainted(int idx, GrMorphisme _versEcran) {
- boolean res = super.isPainted(idx, _versEcran);
if (isSelected(idx)) {
return true;
}
+ if (!isUserVisible()) {
+ return false;
+ }
+ boolean res = super.isPainted(idx, _versEcran);
if (!res) {
return false;
}
@@ -155,7 +188,6 @@
double xmax = LayerTraceGisBuilder.findXmaxLit(profilSection.getLitNumerote(), false);
double length = xmax - xmin;
-
super.layerConfiguration.initTraceIconLimiteLitOrEtiquette(iconEtiquette.getModel(), i);
//les limites de lits
TreeSet<Double> done = new TreeSet<Double>(xtComparator);
@@ -271,7 +303,8 @@
}
if (_clipReel.contientXY(pt)) {
pt.autoApplique(_versEcran);
- labelPainter.paintLabels(_g, pt, layerConfiguration.getDisplayName(profilSection, modeleDonnees(), isSelected(i)), layerConfiguration.getSectionLabelConfiguration(), alpha_);
+ labelPainter.paintLabels(_g, pt, layerConfiguration.getDisplayName(profilSection, modeleDonnees(), isSelected(i)), layerConfiguration.
+ getSectionLabelConfiguration(), alpha_);
}
}
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportLayersTreeComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportLayersTreeComponent.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportLayersTreeComponent.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -118,7 +118,7 @@
this.revalidate();
List<BCalque> mainLayers = panel.getPlanimetryController().getMainLayers();
for (BCalque bCalque : mainLayers) {
- bCalque.addPropertyChangeListener(BSelecteurCheckBox.PROP_VISIBLE, this);
+ bCalque.addPropertyChangeListener(BSelecteurCheckBox.PROP_USER_VISIBLE, this);
}
panel.getPlanimetryController().getGroupExternController().addObserver(this);
@@ -149,7 +149,7 @@
if (panel != null) {
List<BCalque> mainLayers = panel.getPlanimetryController().getMainLayers();
for (BCalque bCalque : mainLayers) {
- bCalque.removePropertyChangeListener(BSelecteurCheckBox.PROP_VISIBLE, this);
+ bCalque.removePropertyChangeListener(BSelecteurCheckBox.PROP_USER_VISIBLE, this);
}
panel.getPlanimetryController().getGroupExternController().deleteObserver(this);
}
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java 2014-02-14 08:28:37 UTC (rev 8617)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java 2014-02-14 08:34:06 UTC (rev 8618)
@@ -283,7 +283,7 @@
panel = reportVisuService.getPlanimetryVisuPanel();
List<BCalque> mainLayers = panel.getPlanimetryController().getMainLayers();
for (BCalque bCalque : mainLayers) {
- bCalque.addPropertyChangeListener(BSelecteurCheckBox.PROP_VISIBLE, this);
+ bCalque.addPropertyChangeListener(BSelecteurCheckBox.PROP_USER_VISIBLE, this);
}
initConfiguration = panel.getPlanimetryController().getVisuConfiguration().deepClone();
restoreDefaultConfigurationData();
@@ -424,7 +424,7 @@
panel.getScene().removeSelectionListener(selectionListener);
List<BCalque> mainLayers = panel.getPlanimetryController().getMainLayers();
for (BCalque bCalque : mainLayers) {
- bCalque.removePropertyChangeListener(BSelecteurCheckBox.PROP_VISIBLE, this);
+ bCalque.removePropertyChangeListener(BSelecteurCheckBox.PROP_USER_VISIBLE, this);
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-14 21:12:46
|
Revision: 8623
http://sourceforge.net/p/fudaa/svn/8623
Author: deniger
Date: 2014-02-14 21:12:43 +0000 (Fri, 14 Feb 2014)
Log Message:
-----------
CRUE-618
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueConverterCommonParameter.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueDaoStructureOptions.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneItem.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
trunk/soft/fudaa-crue/crue-otfa/src/test/java/org/fudaa/dodico/crue/io/otfa/TestCrueOTFA.java
trunk/soft/fudaa-crue/crue-otfa/src/test/resources/otfa/campagne.otfa.xml
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java
Modified: trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
===================================================================
--- trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-02-14 21:12:43 UTC (rev 8623)
@@ -558,6 +558,7 @@
otfa.validator.referenceScenarioNoSet=le sc\u00e9nario de r\u00e9f\u00e9rence n'est pas renseign\u00e9
otfa.validator.referenceCoeurNoSet=Le coeur de r\u00e9f\u00e9rence n'est pas renseign\u00e9
otfa.validator.cibleCoeurNoSet=Le coeur cible n'est pas renseign\u00e9
+otfa.validator.cibleCoeurEmptyButNotScenarioEtude=Si Le coeur cible est vide toute la demi-ligne cible doit \u00eatre vide
otfa.validator.cibleConversionMisconfigured=La cible est mal d\u00e9finie. Pour repr\u00e9senter une conversion, l'\u00e9tude et le sc\u00e9nario doivent \u00eatre tous les 2 vides.
otfa.deleteRunBefore.logs=Effacement des runs avant
otfa.deleteRunAfter.logs=Effacement des runs apr\u00e8s
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueConverterCommonParameter.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueConverterCommonParameter.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueConverterCommonParameter.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -63,6 +63,11 @@
OtfaCampagneLine metier = new OtfaCampagneLine();
metier.setCommentaire(dao.Commentaire);
metier.setIndice(dao.Numero);
+ if (dao.LancerComparaison != null) {
+ metier.setLancerComparaison(Boolean.valueOf(dao.LancerComparaison));
+ } else {
+ metier.setLancerComparaison(true);
+ }
metier.setReference(CrueConverterCommonParameter.convertRunParametersDaoToMetier(dao.Reference));
metier.setCible(CrueConverterCommonParameter.convertRunParametersDaoToMetier(dao.Cible));
return metier;
@@ -72,6 +77,7 @@
CrueDaoStructureOptions.LigneCampagne dao = new CrueDaoStructureOptions.LigneCampagne();
dao.Commentaire = metier.getCommentaire();
dao.Numero = metier.getIndice();
+ dao.LancerComparaison = Boolean.valueOf(metier.isLancerComparaison());
dao.Reference = CrueConverterCommonParameter.convertRunParametersMetierToDao(metier.getReference());
dao.Cible = CrueConverterCommonParameter.convertRunParametersMetierToDao(metier.getCible());
return dao;
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueDaoStructureOptions.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueDaoStructureOptions.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/io/common/CrueDaoStructureOptions.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -32,6 +32,7 @@
public int Numero;
public String Commentaire;
+ public Boolean LancerComparaison;
public RunParameters Reference;
public RunParameters Cible;
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneItem.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneItem.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneItem.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -30,6 +30,10 @@
}
}
+ public boolean isEmpty() {
+ return StringUtils.isBlank(coeurName) && StringUtils.isBlank(scenarioNom) && StringUtils.isBlank(etuFile);
+ }
+
/**
*
* @return true si la version utilisee est Crue9.
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -6,7 +6,7 @@
/**
* Correspond a une ligne d'une campagne.
- *
+ *
* @author deniger
*/
public class OtfaCampagneLine {
@@ -14,6 +14,8 @@
private OtfaCampagneItem reference;
private OtfaCampagneItem cible;
private String commentaire;
+ private boolean lancerComparaison = true;
+
/**
* correspond à l'indice de la ligne dans la liste de {@link OtfaCampagne}
*/
@@ -22,6 +24,14 @@
public OtfaCampagneLine() {
}
+ public boolean isLancerComparaison() {
+ return lancerComparaison;
+ }
+
+ public void setLancerComparaison(boolean lancerComparaison) {
+ this.lancerComparaison = lancerComparaison;
+ }
+
public OtfaCampagneLine(OtfaCampagneLine toCopy) {
if (toCopy != null) {
if (toCopy.reference != null) {
@@ -30,8 +40,8 @@
if (toCopy.cible != null) {
cible = new OtfaCampagneItem(toCopy.cible);
}
- this.commentaire=toCopy.commentaire;
- this.indice=toCopy.indice;
+ this.commentaire = toCopy.commentaire;
+ this.indice = toCopy.indice;
}
}
@@ -51,7 +61,8 @@
/**
* TODO a verifer:
- * @return
+ *
+ * @return
*/
public boolean isCibleAConversion() {
return (StringUtils.isBlank(cible.getScenarioNom()) && StringUtils.isBlank(cible.getEtuPath()));
@@ -132,6 +143,9 @@
result = prime * result + ((commentaire == null) ? 0 : commentaire.hashCode());
result = prime * result + indice;
result = prime * result + ((reference == null) ? 0 : reference.hashCode());
+ if (lancerComparaison) {
+ result++;
+ }
return result;
}
@@ -167,6 +181,9 @@
if (indice != other.indice) {
return false;
}
+ if (lancerComparaison != other.lancerComparaison) {
+ return false;
+ }
if (reference == null) {
if (other.reference != null) {
return false;
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -110,14 +110,18 @@
}
boolean cibleEtuEmpty = StringUtils.isEmpty(line.getCible().getEtuPath());
boolean cibleScenarioEmpty = StringUtils.isEmpty(line.getCible().getScenarioNom());
- if ((cibleEtuEmpty && !cibleScenarioEmpty) || (!cibleEtuEmpty && cibleScenarioEmpty)) {
- log.addSevereError("otfa.validator.cibleConversionMisconfigured");
+ final boolean coeurEmpty = StringUtils.isEmpty(line.getCible().getCoeurName());
+ if (line.isLancerComparaison() || !coeurEmpty) {
+ if ((cibleEtuEmpty && !cibleScenarioEmpty) || (!cibleEtuEmpty && cibleScenarioEmpty)) {
+ log.addSevereError("otfa.validator.cibleConversionMisconfigured");
+ }
}
-
-
- if (StringUtils.isEmpty(line.getCible().getCoeurName())) {
+ if (line.isLancerComparaison() && coeurEmpty) {
log.addSevereError("otfa.validator.cibleCoeurNoSet");
}
+ if (!line.isLancerComparaison() && coeurEmpty && (!cibleEtuEmpty || !cibleScenarioEmpty)) {
+ log.addSevereError("otfa.validator.cibleCoeurEmptyButNotScenarioEtude");
+ }
}
}
@@ -165,7 +169,6 @@
}
}
-
}
}
@@ -197,7 +200,6 @@
}
}
-
}
}
@@ -220,7 +222,7 @@
}
private void validateXsdCompatible(OtfaCampagne campagne, OtfaCampagneItem item, Map<File, String> xsdVersionByEtuFile,
- CtuluLog log, boolean isRef) {
+ CtuluLog log, boolean isRef) {
if (item.isCrue9()) {
return;
}
@@ -241,7 +243,7 @@
} else if (!StringUtils.equals(xsdVersion, findVersion.getVersion())) {
log.addSevereError(isRef ? "otfa.validator.referenceXsdNotCompatible" : "otfa.validator.cibleXsdNotCompatible",
- xsdVersion, findVersion.getVersion());
+ xsdVersion, findVersion.getVersion());
}
}
@@ -266,7 +268,7 @@
final Map<String, CrueVersionType> scenarios = scenariosByEtudes.get(reference.getEtuPath());
if (scenarios != null) {
scenarios.put(line.getFinalCible().getScenarioNom(),
- line.getCible().isCrue9() ? CrueVersionType.CRUE9 : CrueVersionType.CRUE10);
+ line.getCible().isCrue9() ? CrueVersionType.CRUE9 : CrueVersionType.CRUE10);
}
} else {
this.validScenarioExist(campagne, cible, scenariosByEtudes, log);
@@ -276,7 +278,7 @@
}
private void validScenarioExist(OtfaCampagne campagne, OtfaCampagneItem item,
- final Map<String, Map<String, CrueVersionType>> scenariosByEtudes, CtuluLog log) {
+ final Map<String, Map<String, CrueVersionType>> scenariosByEtudes, CtuluLog log) {
File etuFile = item.getEtuFile(campagne.getOtfaDir());
//validation effectuée auparavant:
if (etuFile == null || !etuFile.exists()) {
@@ -314,15 +316,14 @@
//erreur relevée par ailleurs: il faut eviter les remontées multiples
if (versionItem.equals(CrueVersionType.CRUE10) && !coeurExist(item.getCoeurName())) {
Logger.getLogger(OtfaContentValidator.class.getName()).log(Level.INFO,
- "pas d'erreur le scenario {0} car deja remonté dans un test precedent",
- scenarioVersion);
+ "pas d'erreur le scenario {0} car deja remonté dans un test precedent",
+ scenarioVersion);
} else {
log.addSevereError("otfa.validator.crueVersionNonCompatible", name, scenarioVersion.getDisplayName(),
- versionItem.getDisplayName());
+ versionItem.getDisplayName());
}
}
-
}
}
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -57,7 +57,7 @@
*
*/
public class OtfaExecutor {
-
+
private final CoeurManager coeurManager;
private final ConnexionInformation user;
private final CalculCrueRunnerManager calculRunner;
@@ -75,7 +75,7 @@
this.calculRunner = calculRunner;
this.lineSaver = lineSaver;
}
-
+
public RTFAResultLines launch(OtfaCampagne in, ProgressionInterface progress) {
RTFAResultLines result = null;
OutOfMemoryError oomError = null;
@@ -87,7 +87,7 @@
lineSaver.start(false);
}
result = lineSaver.getLines();
-
+
result.getHeader().setCommentaire(in.getCommentaire());
result.getHeader().setDate(new LocalDateTime());
updater.majProgessionStateOnly(BusinessMessages.getString("otfa.avancement.validation"));
@@ -98,20 +98,20 @@
if (preloadSelector != null && preloadSelector.containsSomething()) {
campagneLogs.addGroup(preloadSelector);
}
-
+
if (campagneLogs.containsFatalError()) {
return result;
}
if (stoppedAskedByUser()) {
return result;
}
-
+
List<OtfaCampagneLine> lines = in.getLines();
final int size = lines.size();
updater.setValue(size, size);
updater.majProgessionStateOnly(BusinessMessages.getString("otfa.avancement.lock"));
for (OtfaCampagneLine line : lines) {
-
+
allEtu.add(line.getReference().getEtuFile(in.getOtfaDir()));
if (!line.isCibleAConversion()) {
allEtu.add(line.getFinalCible().getEtuFile(in.getOtfaDir()));
@@ -157,7 +157,7 @@
}
return result;
}
-
+
private void processAllLines(OtfaCampagne in, CtuluLogGroup campagneLogs, ProgressionUpdater updater) {
if (in.getReferenceOptions().isEffacerRunAvant() || in.getCibleOptions().isEffacerRunAvant()) {
CtuluLogGroup logsBefore = campagneLogs.createGroup("otfa.deleteRunBefore.logs");
@@ -179,13 +179,13 @@
deleteRuns(in, in.getReferenceOptions().isEffacerRunApres(), in.getCibleOptions().isEffacerRunApres(), logsAfter);
}
}
-
+
private OtfaCampagneLineResult launch(OtfaCampagne campagne, OtfaCampagneLine line) {
final OtfaCampagneLineResult result = new OtfaCampagneLineResult();
final CtuluLogGroup logs = new CtuluLogGroup(BusinessMessages.RESOURCE_BUNDLE);
logs.setDescription("otfa.launchLine");
logs.setDescriptionArgs(Integer.toString(line.getIndice()));
-
+
result.setInitialLine(line);
result.setLogs(logs);
@@ -202,21 +202,22 @@
if (stoppedAskedByUser()) {
return result;
}
-
- final CoeurConfigContrat coeurForItem = getCoeurForItem(campagne, line.getReference());
+ if (line.isLancerComparaison()) {
+ final CoeurConfigContrat coeurForItem = getCoeurForItem(campagne, line.getReference());
- //la config est celle de la référence.
- CrueConfigMetier config = coeurForItem.getCrueConfigMetier();
- final EMHScenario refScenario = referenceResult == null ? null : referenceResult.getResult();
- final EMHScenario cibleScenario = cibleResult == null ? null : cibleResult.getResult();
-
- if ((refScenario != null) && (cibleScenario != null)) {
- result.setComparisonResult(executor.compare(config, refScenario, cibleScenario, getSelectorType(line)));
+ //la config est celle de la référence.
+ CrueConfigMetier config = coeurForItem.getCrueConfigMetier();
+ final EMHScenario refScenario = referenceResult == null ? null : referenceResult.getResult();
+ final EMHScenario cibleScenario = cibleResult == null ? null : cibleResult.getResult();
+
+ if ((refScenario != null) && (cibleScenario != null)) {
+ result.setComparisonResult(executor.compare(config, refScenario, cibleScenario, getSelectorType(line)));
+ }
}
-
+
return result;
}
-
+
protected ComparaisonSelectorEnum getSelectorType(OtfaCampagneLine line) {
if (line.getReference().isCrue9() && line.getFinalCible().isCrue9()) {
return ComparaisonSelectorEnum.C9_C9;
@@ -226,7 +227,7 @@
}
return ComparaisonSelectorEnum.C9_C10;
}
-
+
public CoeurConfigContrat getCoeurForItem(OtfaCampagne campagne, OtfaCampagneItem item) {
File etuFile = item.getEtuFile(campagne.getOtfaDir());
final CoeurConfigContrat coeur;
@@ -240,11 +241,11 @@
}
CalculCrueContrat currentRunner;
boolean batch;
-
+
public boolean isBatch() {
return batch;
}
-
+
public void setBatch(boolean batch) {
this.batch = batch;
}
@@ -258,6 +259,9 @@
*/
private CrueOperationResult<EMHScenario> launchItem(OtfaCampagne campagne, OtfaCampagneItem item, OtfaCampagneItem ref) {
final CtuluLogGroup logs = new CtuluLogGroup(BusinessMessages.RESOURCE_BUNDLE);
+ if (item.isEmpty()) {
+ return new CrueOperationResult<>(null, logs.createCleanGroup());
+ }
// Chargement du projet.
final File etuFile = item.getEtuFile(campagne.getOtfaDir());
@@ -273,10 +277,10 @@
if (projetResult.getResult() == null || stoppedAskedByUser()) {
return new CrueOperationResult<EMHScenario>(null, logs.createCleanGroup());
}
-
+
EMHProjet projet = projetResult.getResult();
EMHProjetController controller = new EMHProjetController(projet, user);
-
+
ManagerEMHScenario managerScenario = projet.getScenario(item.getScenarioNom());
// Conversion
if (ref != null) {
@@ -286,12 +290,12 @@
final CrueOperationResult<EMHScenarioContainer> conversionResult = controller.convertScenario(ref.getScenarioNom(), infos,
ref.getEtuFile(
campagne.getOtfaDir()));
-
+
logs.addGroup(conversionResult.getLogs().createCleanGroup());
EMHProjetController.writeProjet(etuFile, projet, logs, user);
projetResult = this.loadProjet(etuFile, getCoeurForItem(campagne, item));
final CtuluLogGroup cleanLogGroup = projetResult.getLogs().createCleanGroup();
-
+
logs.addGroup(cleanLogGroup);
if (projetResult.getResult() == null || cleanLogGroup.containsFatalError()) {
return new CrueOperationResult<EMHScenario>(null, (CtuluLog) null);
@@ -305,7 +309,7 @@
logs.createNewLog("otfa.scenarioNotFound").addError("otfa.scenarionNotFound.detail", item.getScenarioNom());
return new CrueOperationResult<EMHScenario>(null, logs.createCleanGroup());
}
-
+
if (item.isLaunchCompute()) {
// Création du run et sauvegarde dans l'étude
//pour créer le runs on utilise des options sans run afin de forcer le lancement complet des calculs.
@@ -331,7 +335,7 @@
}
}
ScenarioLoader loader = new ScenarioLoader(managerScenario, projet, projet.getCoeurConfig());
-
+
ScenarioLoaderOperation load = loader.load(managerScenario.getRunCourant());//on charge le run courant:
logs.addGroup(load.getLogs().createCleanGroup());
@@ -361,14 +365,14 @@
}
}
}
-
+
return new CrueOperationResult<EMHScenario>(emhScenario, logs.createCleanGroup());
}
-
+
private CrueOperationResult<EMHProjet> loadProjet(File etuFile, CoeurConfigContrat version) {
return EMHProjetController.readProjet(etuFile, version);
}
-
+
public void deleteRuns(OtfaCampagne in, boolean reference, boolean cible, CtuluLogGroup logs) {
//rien a faire:
if (!reference && !cible) {
@@ -390,7 +394,7 @@
}
}
}
-
+
private void deleteRuns(File referenceFile, String scenarioNom, OtfaCampagne campagne,
OtfaCampagneItem item, CtuluLogGroup logs) {
CrueOperationResult<EMHProjet> projetResult = this.loadProjet(referenceFile, getCoeurForItem(campagne, item));
@@ -425,9 +429,9 @@
}
controller.saveProjet(referenceFile, logs);
}
-
+
}
-
+
}
private volatile boolean stoppedByUser;
@@ -440,7 +444,7 @@
currentRunner.stop();
}
}
-
+
private boolean stoppedAskedByUser() {
return Thread.currentThread().isInterrupted() || stoppedByUser;
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/test/java/org/fudaa/dodico/crue/io/otfa/TestCrueOTFA.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/test/java/org/fudaa/dodico/crue/io/otfa/TestCrueOTFA.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/test/java/org/fudaa/dodico/crue/io/otfa/TestCrueOTFA.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -112,7 +112,7 @@
line.setIndice(1);
line.setCommentaire("Commentaire de la LigneCampagne ");
-
+ line.setLancerComparaison(true);
OtfaCampagneItem item = new OtfaCampagneItem();
// /v10.1 est un path absolu:
item.setEtuPath("/v10.1/Etu3-0");
@@ -139,7 +139,7 @@
line.setIndice(2);
line.setCommentaire("Commentaire de la LigneCampagne ");
-
+ line.setLancerComparaison(false);
OtfaCampagneItem item = new OtfaCampagneItem();
item.setEtuPath("/v10.1/Etu3-0");
Modified: trunk/soft/fudaa-crue/crue-otfa/src/test/resources/otfa/campagne.otfa.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/test/resources/otfa/campagne.otfa.xml 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-otfa/src/test/resources/otfa/campagne.otfa.xml 2014-02-14 21:12:43 UTC (rev 8623)
@@ -40,6 +40,7 @@
</LigneCampagne>
<LigneCampagne Numero="2">
<Commentaire>Commentaire de la LigneCampagne </Commentaire>
+ <LancerComparaison>False</LancerComparaison>
<Reference>
<Etude>/v10.1/Etu3-0</Etude>
<Scenario>Sc_M3-0_c9c10</Scenario>
Modified: trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java 2014-02-14 21:05:26 UTC (rev 8622)
+++ trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/integration/TestIntegrationEtu41.java 2014-02-14 21:12:43 UTC (rev 8623)
@@ -45,7 +45,7 @@
@Test
public void testSc_M41_c9c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M4-1_c9", "Sc_M4-1_c9c9", "M4-1_c9c9", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_M4-1_c9c9", new ErrorBilanTester(0, 0, 6, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-1_c9c9", new ErrorBilanTester(0, 0, 5, 2));
}
@Test
@@ -58,13 +58,13 @@
public void testSc_M41_c10c9() {
IntegrationHelper.exportToCrue9(getEtuFile().getParentFile(), projet, "Sc_M4-1_c10", "Sc_M4-1_c10c9", "M4-1_c10c9",
Arrays.asList("COM5", "COM1", "COM3", "PNUM1", "OPTR1"));
- IntegrationHelper.testScenario(projet, "Sc_M4-1_c10c9", new ErrorBilanTester(0, 0, 6, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-1_c10c9", new ErrorBilanTester(0, 0, 5, 2));
}
@Test
public void testSc_M41_c10c10() {
IntegrationHelper.exportToCrue10(getEtuFile().getParentFile(), projet, "Sc_M4-1_c10", "Sc_M4-1_c10c10", "M4-1_c10c10", true, 0);
- IntegrationHelper.testScenario(projet, "Sc_M4-1_c10c10", new ErrorBilanTester(0, 0, 5, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-1_c10c10", new ErrorBilanTester(0, 0, 4, 2));
}
@Test
@@ -73,17 +73,17 @@
"COM5", "OCAL4",
"OPTI6", "OPTG4",
"OPTR1"));// différences
- IntegrationHelper.testScenario(projet, "Sc_M4-1_c9c10", new ErrorBilanTester(0, 0, 5, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-1_c9c10", new ErrorBilanTester(0, 0, 4, 2));
}
@Test
public void testSc_M41_c9() {
- IntegrationHelper.testScenario(projet, "Sc_M4-1_c9", new ErrorBilanTester(0, 0, 6, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-1_c9", new ErrorBilanTester(0, 0, 5, 2));
}
@Test
public void testSc_M41_c10() {
- IntegrationHelper.testScenario(projet, "Sc_M4-1_c10", new ErrorBilanTester(0, 0, 5, 2));
+ IntegrationHelper.testScenario(projet, "Sc_M4-1_c10", new ErrorBilanTester(0, 0, 4, 2));
}
private File getEtuFile() {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-14 21:35:42
|
Revision: 8625
http://sourceforge.net/p/fudaa/svn/8625
Author: deniger
Date: 2014-02-14 21:35:39 +0000 (Fri, 14 Feb 2014)
Log Message:
-----------
CRUE-618
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidatorAndLoaderResultatCrue9Test.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/OtfaCampagneTopComponent.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/CoeurProperty.java
trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties
trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/node/Bundle.properties
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryAccrocheController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCLimMLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilProcessor.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/resources/org/fudaa/fudaa/crue/planimetry/Bundle.properties
trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/SigHelperForTest.java
trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilTest.java
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-planimetry/src/test/resources/ggcrue/EMG_Profil_point_canal_de_fuite.dbf
trunk/soft/fudaa-crue/ui-planimetry/src/test/resources/ggcrue/EMG_Profil_point_canal_de_fuite.shp
Modified: trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidatorAndLoaderResultatCrue9Test.java
===================================================================
--- trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidatorAndLoaderResultatCrue9Test.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidatorAndLoaderResultatCrue9Test.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -40,24 +40,10 @@
data.setSto(readBinaire(this, Crue9FileFormatFactory.getSTOFileFormat(), FilesForTest.STO_ETU30_M30, data).getMetier());
ValidatorAndLoaderResultatCrue9.validFcbProfils(read.getMetier(), data, log);
AbstractIOBinaryTestCase.testAnalyser(log);
- assertTrue(getResultatPosition(data, "ST_B5_AMONT") > 0);
- assertTrue(getResultatPosition(data, "ST_B5_AVAL") > 0);
- assertTrue(getResultatPosition(data, "ST_B8_AMONT") > 0);
- assertTrue(getResultatPosition(data, "ST_B8_AVAL") > 0);
- // tests des sections sans géometrie qui peuvent causer problèmes:
-// FCBSequentialReader.EnteteContainer<FCBValueObject.EnteteBranche, FCBValueObject.ResBranche> containerBranches = infos.getContainerBranches();
-// for (int i = 0; i < containerBranches.getNbData(); i++) {
-// String name = containerBranches.getDataName(i);
-// assertFalse(StringUtils.isBlank(name));
-// }
-// FCBSequentialReader.EnteteContainer<FCBValueObject.EnteteCasier, FCBValueObject.ResCasier> containerNoeud = infos.getContainerCasiers();
-// for (int i = 0; i < containerNoeud.getNbData(); i++) {
-// String name = containerNoeud.getDataName(i);
-// assertFalse(StringUtils.isBlank(name));
-// }
-// int nbPdt = read.getMetier().getPdt().getNbResultats();
-// assertEquals(25, nbPdt);
-
+ assertTrue(getResultatPosition(data, "ST_B5_AM") > 0);
+ assertTrue(getResultatPosition(data, "ST_B5_AV") > 0);
+ assertTrue(getResultatPosition(data, "ST_B8_AM") > 0);
+ assertTrue(getResultatPosition(data, "ST_B8_AV") > 0);
}
private int getResultatPosition(CrueData data, final String id) {
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/OtfaCampagneTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/OtfaCampagneTopComponent.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/OtfaCampagneTopComponent.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -88,6 +88,7 @@
associateLookup(ExplorerUtils.createLookup(mgr, getActionMap()));
this.outlineView.addPropertyColumn("commentaire", NbBundle.getMessage(OtfaCampagneTopComponent.class, "comment"));
+ this.outlineView.addPropertyColumn("lancerComparaison", NbBundle.getMessage(OtfaCampagneTopComponent.class, "lancerComparaison"));
this.outlineView.addPropertyColumn("referenceEtuFile", NbBundle.getMessage(OtfaCampagneTopComponent.class, "refEtuFile"));
this.outlineView.addPropertyColumn("referenceScenarioNom", NbBundle.getMessage(OtfaCampagneTopComponent.class, "refScenario"));
this.outlineView.addPropertyColumn("referenceLaunchCompute", NbBundle.getMessage(OtfaCampagneTopComponent.class,
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -153,6 +153,7 @@
try {
Property indice = new PropertySupportReflection(this, line, int.class, "getIndice", null);
Property commentaire = new PropertySupportReflection(this, line, String.class, "getCommentaire", "setCommentaire");
+ Property lancerComparaison = new PropertySupportReflection(this, line, boolean.class, "isLancerComparaison", "setLancerComparaison");
final String logDisplayName = NbBundle.getMessage(OtfaCampagneLineNode.class, "logsName");
final String logDescription = NbBundle.getMessage(OtfaCampagneLineNode.class, "logsDescription");
OtfaRtfaLineProperty logs = new OtfaRtfaLineProperty(data, "logs", logDisplayName, logDescription);
@@ -168,6 +169,10 @@
commentaire.setDisplayName(NbBundle.getMessage(OtfaCampagneLineNode.class, "commentName"));
commentaire.setShortDescription(NbBundle.getMessage(OtfaCampagneLineNode.class, "commentDescription"));
+ lancerComparaison.setName("lancerComparaison");
+ lancerComparaison.setDisplayName(NbBundle.getMessage(OtfaCampagneLineNode.class, "lancerComparaisonName"));
+ lancerComparaison.setShortDescription(NbBundle.getMessage(OtfaCampagneLineNode.class, "lancerComparaisonDescription"));
+
logs.setPropertyEditorClass(LogsPropertyEditor.class);
comparaisons.setPropertyEditorClass(ComparaisonsPropertyEditor.class);
if (!data.hasDifferences()) {
@@ -178,6 +183,7 @@
}
set.put(indice);
+ set.put(lancerComparaison);
set.put(commentaire);
set.put(logs);
set.put(comparaisons);
@@ -234,7 +240,7 @@
configureFileEditor(etude);
PropertySupportReflection scenario = new ScenarioProperty(this, otfaCampagne, line.getReference(), "getScenarioNom", "setScenarioNom");
- CoeurProperty coeur = new CoeurProperty(this, line.getReference(), String.class, "getCoeurName", "setCoeurName");
+ CoeurProperty coeur = new CoeurProperty(this, line.getReference(), String.class, "getCoeurName", "setCoeurName", false);
Property lancerCalcul = new PropertySupportReflection(this, line.getReference(), boolean.class, "isLaunchCompute", "setLaunchCompute");
etude.setName(REFERENCE_ETU_FILE_PROPERTY);
@@ -287,8 +293,9 @@
};
etude.setCanWrite(true);
configureFileEditor(etude);
- Property scenario = new ScenarioProperty(this, otfaService.getCurrentOTFA().getOtfaCampagne(), line.getCible(), "getScenarioNom", "setScenarioNom");
- Reflection coeur = new CoeurProperty(this, line.getCible(), String.class, "getCoeurName", "setCoeurName");
+ Property scenario = new ScenarioProperty(this, otfaService.getCurrentOTFA().getOtfaCampagne(), line.getCible(), "getScenarioNom",
+ "setScenarioNom");
+ Reflection coeur = new CoeurProperty(this, line.getCible(), String.class, "getCoeurName", "setCoeurName", true);
Property lancerCalcul = new PropertySupportReflection(this, line.getCible(), boolean.class, "isLaunchCompute", "setLaunchCompute");
etude.setName(CIBLE_ETU_FILE_PROPERPTY);
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/CoeurProperty.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/CoeurProperty.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/CoeurProperty.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -8,6 +8,7 @@
import java.beans.PropertyEditorSupport;
import java.util.ArrayList;
import java.util.List;
+import org.apache.commons.lang.StringUtils;
import org.fudaa.dodico.crue.projet.otfa.OtfaCampagneItem;
import org.fudaa.fudaa.crue.common.property.AbstractNodeFirable;
import org.fudaa.fudaa.crue.common.property.PropertySupportReflection;
@@ -20,8 +21,11 @@
*/
public class CoeurProperty extends PropertySupportReflection<String> {
- public CoeurProperty(AbstractNodeFirable node, Object instance, Class clazz, String getter, String setter) throws NoSuchMethodException {
+ private final boolean emptyAuthorized;
+
+ public CoeurProperty(AbstractNodeFirable node, Object instance, Class clazz, String getter, String setter, boolean emptyAuthorized) throws NoSuchMethodException {
super(node, instance, clazz, getter, setter);
+ this.emptyAuthorized = emptyAuthorized;
}
@Override
@@ -51,6 +55,9 @@
public String[] getTags() {
if (coeurs == null) {
List<String> all = new ArrayList<String>();
+ if (emptyAuthorized) {
+ all.add(StringUtils.EMPTY);
+ }
all.add(OtfaCampagneItem.CRUE9);
all.addAll(service.getCoeursNames());
coeurs = (String[]) all.toArray(new String[all.size()]);
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties 2014-02-14 21:35:39 UTC (rev 8625)
@@ -38,6 +38,7 @@
OtfaCampagneTopComponent.ciblesDeleteRunsBeforeCheckBox.text=Effacer les runs avant
OtfaCampagneTopComponent.openOtfaButton.text=OpenOtfa
comment=Commentaire
+lancerComparaison=Comparaison
refEtuFile=Fichier Etu de la r\u00e9f\u00e9rence
refScenario=Sc\u00e9nario de la r\u00e9f\u00e9rence
refLaunchCompute=Lancement des runs de la r\u00e9f\u00e9rence
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/node/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/node/Bundle.properties 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/node/Bundle.properties 2014-02-14 21:35:39 UTC (rev 8625)
@@ -3,6 +3,8 @@
indiceDescription=D\u00e9fini l'indice de la ligne.
commentName=Commentaire
commentDescription=D\u00e9fini le commentaire de la ligne.
+lancerComparaisonName=Lancer la comparaison
+lancerComparaisonDescription=Lancer la comparaison ou non
indicateurName=Indicateur
indicateurDescription=D\u00e9fini l'\u00e9tat des comparaisons de la ligne.
logsName=Logs
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/PlanimetryVisuPanel.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -14,6 +14,7 @@
import java.util.Collections;
import java.util.HashSet;
import java.util.List;
+import java.util.MissingResourceException;
import java.util.Observable;
import java.util.Observer;
import java.util.Set;
@@ -27,12 +28,15 @@
import javax.swing.border.Border;
import org.fudaa.ctulu.CtuluLib;
import org.fudaa.ctulu.CtuluUI;
+import org.fudaa.ctulu.gis.GISPolyligne;
+import org.fudaa.dodico.crue.metier.emh.CatEMHBranche;
import org.fudaa.dodico.crue.metier.emh.EMH;
import org.fudaa.dodico.crue.metier.emh.IdRegistry;
import org.fudaa.ebli.calque.BArbreCalqueModel;
import org.fudaa.ebli.calque.BCalque;
import org.fudaa.ebli.calque.BGroupeCalque;
import org.fudaa.ebli.calque.ZCalqueAffichageDonneesInterface;
+import org.fudaa.ebli.calque.ZCatchEvent;
import org.fudaa.ebli.calque.ZSelectionEvent;
import org.fudaa.ebli.calque.ZSelectionListener;
import org.fudaa.ebli.calque.action.AddVertexAction;
@@ -48,10 +52,12 @@
import org.fudaa.ebli.find.EbliFindDialog;
import org.fudaa.ebli.find.EbliFindableItem;
import org.fudaa.ebli.geometrie.GrBoite;
+import org.fudaa.ebli.ressource.EbliResource;
import org.fudaa.fudaa.crue.planimetry.action.AddBrancheAction;
import org.fudaa.fudaa.crue.planimetry.action.AddCasierAction;
import org.fudaa.fudaa.crue.planimetry.action.AddNoeudAction;
import org.fudaa.fudaa.crue.planimetry.action.EditZonePanel;
+import org.fudaa.fudaa.crue.planimetry.controller.LayerBrancheController;
import org.fudaa.fudaa.crue.planimetry.controller.PlanimetryController;
import org.fudaa.fudaa.crue.planimetry.controller.PlanimetryVisuPanelController;
import org.fudaa.fudaa.crue.planimetry.layer.CalqueWithDynamicActions;
@@ -157,6 +163,54 @@
}
@Override
+ public void setAccrocheText(ZCatchEvent _evt) {
+ final ZCalqueAffichageDonneesInterface layer = _evt.selection.getScene().getLayerForId(_evt.idxGeom);
+ int idx = _evt.selection.getScene().sceneId2LayerId(_evt.idxGeom);
+ int vertex = _evt.idxVertex;
+ final PlanimetryController planimetryController = getPlanimetryController();
+ if (layer == planimetryController.getCqNoeud()) {
+ final EMH emh = planimetryController.getNodeController().getEMHFromLayerPosition(idx);
+ setInfoText(NbBundle.getMessage(PlanimetryVisuPanel.class, "accroche.node", emh.getNom()));
+ } else if (layer == planimetryController.getCqBranche()) {
+ setAccrocheTextBranche(planimetryController, idx, vertex);
+ } else if (layer == planimetryController.getCqCasier()) {
+ final EMH emh = planimetryController.getCasierController().getEMHFromLayerPosition(idx);
+ setInfoText(NbBundle.getMessage(PlanimetryVisuPanel.class, "accroche.casier", emh.getNom(), vertex));
+ } else if (layer == planimetryController.getCqSection()) {
+ final EMH emh = planimetryController.getSectionController().getEMHFromLayerPosition(idx);
+ setInfoText(NbBundle.getMessage(PlanimetryVisuPanel.class, "accroche.section", emh.getNom()));
+ } else {
+ super.setAccrocheText(_evt);
+ }
+ }
+
+ private void setAccrocheTextBranche(final PlanimetryController planimetryController, int idx, int vertex) throws MissingResourceException {
+ final CatEMHBranche branche = (CatEMHBranche) planimetryController.getBrancheController().getEMHFromLayerPosition(idx);
+ final GISPolyligne brancheGis = planimetryController.getBrancheController().getBrancheGis(idx);
+ if (vertex == LayerBrancheController.getAmontCoordinatePosition()) {
+ final EMH emh = branche.getNoeudAmont();
+ setInfoText(NbBundle.getMessage(PlanimetryVisuPanel.class, "accroche.node", emh.getNom()));
+ } else if (vertex == LayerBrancheController.getAvalCoordinatePosition(brancheGis.getNumPoints())) {
+ final EMH emh = branche.getNoeudAval();
+ setInfoText(NbBundle.getMessage(PlanimetryVisuPanel.class, "accroche.node", emh.getNom()));
+ } else {
+ setInfoText(NbBundle.getMessage(PlanimetryVisuPanel.class, "accroche.branche", branche.getNom(), vertex + 1));
+ }
+ }
+
+ public void setAccrocheText(String[] vars) {
+ String text
+ = EbliResource.EBLI.getString(
+ "Accroche : Calque={0} Geom={1} Sommet={2}", vars);
+ setInfoText(text);
+ }
+
+ @Override
+ public void unsetAcrrocheText() {
+ super.unsetAcrrocheText();
+ }
+
+ @Override
protected ZEditorDefault createGisEditor() {
return new PlanimetryGisEditor(this);
}
@@ -178,7 +232,7 @@
}
@Override
- public void setEnabled(boolean _newValue) {
+ public void setEnabled(boolean _newValue) {
}
};
return res;
@@ -393,15 +447,20 @@
TitledSeparator titleSeparator = new TitledSeparator(org.openide.util.NbBundle.getMessage(PlanimetryVisuPanel.class, "Toolbar.Separator"));
final Border emptyBorder = BorderFactory.createEmptyBorder(5, 1, 1, 1);
+
titleSeparator.setBorder(emptyBorder);
+
gisEditionPalette.add(titleSeparator);
gisEditionPalette.add(add(addNoeud.buildToolButton(EbliComponentFactory.INSTANCE)));
gisEditionPalette.add(add(addBranche.buildToolButton(EbliComponentFactory.INSTANCE)));
gisEditionPalette.add(add(addCasier.buildToolButton(EbliComponentFactory.INSTANCE)));
titleSeparator = new TitledSeparator(org.openide.util.NbBundle.getMessage(PlanimetryVisuPanel.class, "Project.Separator"));
+
titleSeparator.setBorder(emptyBorder);
+
gisEditionPalette.add(titleSeparator);
+
gisEditionPalette.add(add(getPlanimetryController().getProjectEMHOnSIGAction().buildToolButton(EbliComponentFactory.INSTANCE)));
gisEditionPalette.add(add(getPlanimetryController().getTraceProfilAttachedToBrancheAction().buildToolButton(EbliComponentFactory.INSTANCE)));
}
@@ -435,6 +494,7 @@
}
}
return emhs;
+
}
private class ObserverCalque implements Observer {
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryAccrocheController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryAccrocheController.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryAccrocheController.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -46,8 +46,10 @@
final CtuluListSelection selection = layer.selection(pt, ZCalqueSelectionInteractionAbstract.DEFAULT_TOLERANCE_PIXEL);
Cursor newCursor = null;
if (selection == null || selection.isEmpty()) {
- newCursor = view.getController().getDefautCursor();
- view.unsetInfoText();
+ if (!view.getController().getCqCatchI().isSomethingCatched()) {
+ newCursor = view.getController().getDefautCursor();
+ view.unsetInfoText();
+ }
PlanimetryCLimMLayer climM = view.getPlanimetryController().getcondLimiteController().getLayer();
final CtuluListSelection selectionClimM = climM.selection(pt, ZCalqueSelectionInteractionAbstract.DEFAULT_TOLERANCE_PIXEL);
if (selectionClimM != null && !selectionClimM.isEmpty()) {
@@ -63,7 +65,7 @@
}
view.setInfoText(StringUtils.join(emhs, "; "));
}
- if (!newCursor.equals(view.getVueCalque().getCursor())) {
+ if (newCursor != null && !newCursor.equals(view.getVueCalque().getCursor())) {
view.getVueCalque().setCursor(newCursor);
}
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/controller/PlanimetryVisuPanelController.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -2,6 +2,7 @@
import java.awt.event.KeyAdapter;
import java.awt.event.KeyEvent;
+import java.beans.PropertyChangeListener;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Collection;
@@ -46,11 +47,23 @@
}
@Override
+ public void setCalqueInteractionActif(BCalqueInteraction _b) {
+ super.setCalqueInteractionActif(_b);
+ getView().getVueCalque().requestFocus();
+ }
+
+
+ @Override
public void setView(final ZEbliCalquesPanel view) {
super.setView(view);
-// view.getVueCalque().removeKeyListener(cqCatchI_);
-// removeCalqueInteraction(cqCatchI_);
+ view.getVueCalque().removeKeyListener(cqCatchI_);
cqCatchI_.setGele(true);
+ final PropertyChangeListener[] propertyChangeListeners = cqCatchI_.getPropertyChangeListeners("gele");
+ if (propertyChangeListeners != null) {
+ for (PropertyChangeListener propertyChangeListener : propertyChangeListeners) {
+ cqCatchI_.removePropertyChangeListener("gele", propertyChangeListener);
+ }
+ }
view.getVueCalque().addKeyListener(new KeyAdapter() {
@Override
public void keyPressed(KeyEvent e) {
@@ -68,7 +81,6 @@
cqCatchI_.setGele(true);
}
}
-
});
new PlanimetryAccrocheController((PlanimetryVisuPanel) view).install();
SelectionMoveInteraction selection = (SelectionMoveInteraction) getCalqueInteraction("cqSELECTION");
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCLimMLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCLimMLayer.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryCLimMLayer.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -50,6 +50,11 @@
}
@Override
+ public boolean canBeUsedForAccroche() {
+ return false;
+ }
+
+ @Override
public CtuluListSelection selection(GrPoint _pt, int _tolerance) {
if (modele == null || !isVisible()) {
return null;
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryTraceLayer.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -111,6 +111,11 @@
LabelPainter labelPainter = new LabelPainter();
@Override
+ public boolean canBeUsedForAccroche() {
+ return false;
+ }
+
+ @Override
protected boolean isPainted(int idx, GrMorphisme _versEcran) {
if (isSelected(idx)) {
return true;
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilProcessor.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilProcessor.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilProcessor.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -44,6 +44,7 @@
GISAttributeModel model = entry.getValue();
if (model == null) {
log.addSevereError(NbBundle.getMessage(GGPointToTraceProfilProcessor.class, "traceProfil.AttributNotFound", key));
+ return;
} else if (model.getSize() != nbPoint) {
log.addSevereError(NbBundle.getMessage(GGPointToTraceProfilProcessor.class, "traceProfil.AttributeSizeNotCorrect", key, Integer.toString(
model.getSize()), Integer.toString(nbPoint)));
@@ -64,7 +65,7 @@
if (model.getObjectValueAt(i) == null) {
log.
addSevereError(NbBundle.getMessage(GGPointToTraceProfilProcessor.class, "traceProfil.AttributeWithEmptyValue", key, Integer.
- toString(i)));
+ toString(i)));
}
}
}
@@ -144,7 +145,6 @@
}
res.setResultat(zone);
-
return res;
}
}
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/resources/org/fudaa/fudaa/crue/planimetry/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/resources/org/fudaa/fudaa/crue/planimetry/Bundle.properties 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/resources/org/fudaa/fudaa/crue/planimetry/Bundle.properties 2014-02-14 21:35:39 UTC (rev 8625)
@@ -18,3 +18,8 @@
DeleteEMH.Name=Supprimer uniquement la s\u00e9lection
Cancel.Name=Annuler
Project.Separator=<->
+accroche.node=Accroche: Noeud {0}
+accroche.branche=Accroche: Branche {0}, sommet {1}
+accroche.casier=Accroche: Casier {0}, sommet {1}
+accroche.section=Accroche: Section {0}
+
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/SigHelperForTest.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/SigHelperForTest.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/SigHelperForTest.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -33,7 +33,7 @@
analyse);
assertTrue(analyse.isEmpty());
GISZoneCollectionPoint buildPoints = SigLoaderHelper.buildPoints(result.createData());
- assertEquals(16581, buildPoints.getNbGeometries());
+ assertEquals(2433, buildPoints.getNbGeometries());
GGPointToTraceProfilProcessor toTrace = new GGPointToTraceProfilProcessor(buildPoints, TestCoeurConfig.INSTANCE.getCrueConfigMetier());
CtuluLogResult<GISZoneCollectionLigneBrisee> toProfil = toTrace.toProfil();
return toProfil;
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilTest.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilTest.java 2014-02-14 21:16:50 UTC (rev 8624)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/test/java/org/fudaa/fudaa/crue/planimetry/sig/traceprofil/GGPointToTraceProfilTest.java 2014-02-14 21:35:39 UTC (rev 8625)
@@ -32,10 +32,10 @@
@BeforeClass
public static void extractFile() throws IOException {
targetDir = CtuluLibFile.createTempDir();
- shapeFile = new File(targetDir, "EMG_Profil_point.shp");
- File dbfFile = new File(targetDir, "EMG_Profil_point.dbf");
- CtuluLibFile.getFileFromJar("/ggcrue/EMG_Profil_point.shp", shapeFile);
- CtuluLibFile.getFileFromJar("/ggcrue/EMG_Profil_point.dbf", dbfFile);
+ shapeFile = new File(targetDir, "EMG_Profil_point_canal_de_fuite.shp");
+ File dbfFile = new File(targetDir, "EMG_Profil_point_canal_de_fuite.dbf");
+ CtuluLibFile.getFileFromJar("/ggcrue/EMG_Profil_point_canal_de_fuite.shp", shapeFile);
+ CtuluLibFile.getFileFromJar("/ggcrue/EMG_Profil_point_canal_de_fuite.dbf", dbfFile);
}
@AfterClass
@@ -57,7 +57,7 @@
assertTrue("contient des doublons donc warning", toProfil.getLog().containsWarnings());//a cous
assertFalse(toProfil.getLog().containsErrorOrSevereError());
assertNotNull(toProfil.getResultat());
- final int nbProfil = 96;
+ final int nbProfil = 16;
assertEquals(nbProfil, toProfil.getResultat().getNbGeometries());
GISAttributeModel modelNom = toProfil.getResultat().getModel(nomIdx);
assertEquals(GGTraceProfilSectionAttributesController.NOM, modelNom.getAttribute());
@@ -67,8 +67,8 @@
objectValues[i] = (String) initValues[i];
}
Arrays.sort(objectValues);
- assertEquals("100.000", objectValues[0]);
- assertEquals("99.800", objectValues[nbProfil - 1]);
+ assertEquals("PCF1", objectValues[0]);
+ assertEquals("PCF5", objectValues[nbProfil - 1]);
GISAttributeModel modelXt = toProfil.getResultat().getModel(xtIdx);
GISAttributeModel modelZ = toProfil.getResultat().getModel(zIdx);
@@ -78,68 +78,68 @@
//c'est trié dans l'ordre
String nom1 = (String) modelNom.getObjectValueAt(0);
- assertEquals("98.500", nom1);
+ assertEquals("PCF1", nom1);
Double xt = getValueAt(modelXt, 0, 0);
- assertEquals(-29.84, xt, 1e-3);
+ assertEquals(-12.02, xt, 1e-3);
//on teste la première frontière:
int firstLimMinIdx = 7;
xt = getValueAt(modelXt, 0, firstLimMinIdx);
- String limLit = getValueAt(modelLimLit, 0, firstLimMinIdx);
- String limGeom = getValueAt(modelLimGeo, 0, firstLimMinIdx);
- String label = getValueAt(modelLabel, 0, firstLimMinIdx);
- assertEquals(1.08, xt, 1e-3);
- assertEquals(LimLitHelper.MAJD_MIN, limLit);
- assertEquals("", limGeom);
- assertEquals(LimLitHelper.MAJD_MIN, label);
-
- int thalwegIdx = 12;
- xt = ge...
[truncated message content] |
|
From: <de...@us...> - 2014-02-25 21:16:56
|
Revision: 8629
http://sourceforge.net/p/fudaa/svn/8629
Author: deniger
Date: 2014-02-25 21:16:52 +0000 (Tue, 25 Feb 2014)
Log Message:
-----------
backup de la base
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/FileEditor.java
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/StringCustomEditor.java
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java 2014-02-25 21:16:02 UTC (rev 8628)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java 2014-02-25 21:16:52 UTC (rev 8629)
@@ -37,7 +37,7 @@
Toolbar state = getStateToolbar(toolbars);
if (state != null) {
state.setOpaque(false);
- state.setBorder(BorderFactory.createCompoundBorder(state.getBorder(), BorderFactory.createEmptyBorder(5, 5, 0, 0)));
+ state.setBorder(BorderFactory.createCompoundBorder(state.getBorder(), BorderFactory.createEmptyBorder(1, 1, 0, 0)));
}
Toolbar perspective = getPerspectiveToolbar(toolbars);
if (perspective != null) {
Added: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/FileEditor.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/FileEditor.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/FileEditor.java 2014-02-25 21:16:52 UTC (rev 8629)
@@ -0,0 +1,541 @@
+/*
+ Copier depuis le source Netbeans
+ */
+package org.fudaa.fudaa.crue.common.editor;
+
+import java.awt.event.ActionEvent;
+import java.awt.event.KeyEvent;
+import java.awt.Component;
+import java.awt.Container;
+import java.awt.Dialog;
+import java.awt.KeyboardFocusManager;
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+import java.beans.PropertyEditorSupport;
+import java.io.File;
+import java.io.FilenameFilter;
+import java.util.logging.Level;
+import java.util.logging.Logger;
+import javax.swing.AbstractAction;
+import javax.swing.AbstractButton;
+import javax.swing.Action;
+import javax.swing.JComboBox;
+import javax.swing.JComponent;
+import javax.swing.JFileChooser;
+import javax.swing.JScrollBar;
+import javax.swing.KeyStroke;
+import org.openide.nodes.Node;
+import org.openide.explorer.propertysheet.ExPropertyEditor;
+import org.openide.explorer.propertysheet.PropertyEnv;
+import org.openide.util.HelpCtx;
+import org.openide.util.NbBundle;
+
+/**
+ * https://fudaa-project.atlassian.net/browse/CRUE-633 TODO a enlever des que l'on pourra passer à une version de Netbeans >7.4
+ *
+ * La version 7.4 corrige le probleme mais apporte des régressions sur la persistances des informations sur les OutlineView. <br>
+ *
+ * PropertyEditor for * <code>java.io.File</code>.
+ *
+ * @author Jaroslav Tulach, David Strupl, Peter Zavadsky, Jesse Glick
+ */
+public class FileEditor extends PropertyEditorSupport implements ExPropertyEditor, PropertyChangeListener {
+
+ /**
+ * Name of the property obtained from the feature descriptor.
+ */
+ static final String PROPERTY_SHOW_DIRECTORIES = "directories"; //NOI18N
+
+ /**
+ * Name of the property obtained from the feature descriptor.
+ */
+ static final String PROPERTY_SHOW_FILES = "files"; //NOI18N
+
+ /**
+ * Name of the property obtained from the feature descriptor.
+ */
+ static final String PROPERTY_FILTER = "filter"; //NOI18N
+
+ /**
+ * Name of the property obtained from the feature descriptor.
+ */
+ static final String PROPERTY_CURRENT_DIR = "currentDir"; //NOI18N
+
+ /**
+ * Name of the property obtained from the feature descriptor.
+ */
+ static final String PROPERTY_BASE_DIR = "baseDir"; // NOI18N
+
+ /**
+ * Name of the property obtained from the feature descriptor.
+ */
+ static final String PROPERTY_FILE_HIDING = "file_hiding"; // NOI18N
+
+ /**
+ * Openning mode.
+ */
+ private int mode = JFileChooser.FILES_AND_DIRECTORIES;
+
+ /**
+ * Flag indicating whether to choose directories. Default value is <code>true</code>.
+ */
+ private boolean directories = true;
+ /**
+ * Flag indicating whether to choose files. Default value is <code>true</code>.
+ */
+ private boolean files = true;
+ /**
+ * Flag indicating whether to hide files marked as hidden. Default value is <code>false</code>.
+ */
+ private boolean fileHiding = false;
+ /**
+ * Filter for files to show.
+ */
+ private javax.swing.filechooser.FileFilter fileFilter;
+ /**
+ * Current firectory.
+ */
+ private File currentDirectory;
+ /**
+ * Base directory to which to show relative path, if is set.
+ */
+ private File baseDirectory;
+
+ /**
+ * Caches last used directory.
+ */
+ static File lastCurrentDir;
+
+ private PropertyEnv env;
+
+ /**
+ * Cached chooser. If you don't cache it, MountIterator in core flickers and behaves weirdly, because apparently PropertyPanel will call
+ * getCustomEditor repeatedly and refresh the display each time. XXX MountIterator is dead so is this still necessary? -jglick
+ */
+ private JFileChooser chooser;
+
+ /**
+ * whether the value can be edited -- default to true
+ */
+ private boolean editable = true;
+
+ /**
+ * This method is called by the IDE to pass the environment to the property editor.
+ *
+ * @param env Environment passed by the ide.
+ */
+ public void attachEnv(PropertyEnv env) {
+ this.env = env;
+
+ // clearing to defaults
+ directories = true;
+ files = true;
+ fileFilter = null;
+ fileHiding = false;
+
+ Object dirs = env.getFeatureDescriptor().getValue(PROPERTY_SHOW_DIRECTORIES);
+ if (dirs instanceof Boolean) {
+ directories = ((Boolean) dirs).booleanValue();
+ } // XXX else if != null, warn
+ Object fil = env.getFeatureDescriptor().getValue(PROPERTY_SHOW_FILES);
+ if (fil instanceof Boolean) {
+ files = ((Boolean) fil).booleanValue();
+ } // XXX else if != null, warn
+ Object filter = env.getFeatureDescriptor().getValue(PROPERTY_FILTER);
+ if (filter instanceof FilenameFilter) {
+ fileFilter = new DelegatingFilenameFilter((FilenameFilter) filter);
+ } else if (filter instanceof javax.swing.filechooser.FileFilter) {
+ fileFilter = (javax.swing.filechooser.FileFilter) filter;
+ } else if (filter instanceof java.io.FileFilter) {
+ fileFilter = new DelegatingFileFilter((java.io.FileFilter) filter);
+ } // XXX else if != null, warn
+
+ Object curDir = env.getFeatureDescriptor().getValue(PROPERTY_CURRENT_DIR);
+ if (curDir instanceof File) {
+ currentDirectory = (File) curDir;
+ if (!currentDirectory.isDirectory()) {
+ Logger.getAnonymousLogger().warning("java.io.File will not accept currentDir=" + currentDirectory); // NOI18N
+ currentDirectory = null;
+ }
+ } // XXX else if != null, warn
+
+ Object baseDir = env.getFeatureDescriptor().getValue(PROPERTY_BASE_DIR);
+ if (baseDir instanceof File) {
+ baseDirectory = (File) baseDir;
+ // As baseDir accept only directories in their absolute form.
+ if (!baseDirectory.isDirectory() || !baseDirectory.isAbsolute()) {
+ Logger.getAnonymousLogger().warning("java.io.File will not accept baseDir=" + baseDirectory); // NOI18N
+ baseDirectory = null;
+ }
+ } // XXX else if != null, warn
+ if (files) {
+ mode = directories ? JFileChooser.FILES_AND_DIRECTORIES
+ : JFileChooser.FILES_ONLY;
+ } else {
+ mode = directories ? JFileChooser.DIRECTORIES_ONLY
+ : JFileChooser.FILES_AND_DIRECTORIES; // both false, what now? XXX warn
+ }
+
+ Object fileHide = env.getFeatureDescriptor().getValue(PROPERTY_FILE_HIDING);
+ if (fileHide instanceof Boolean) {
+ fileHiding = ((Boolean) fileHide).booleanValue();
+ }
+
+ if (env.getFeatureDescriptor() instanceof Node.Property) {
+ Node.Property prop = (Node.Property) env.getFeatureDescriptor();
+ editable = prop.canWrite();
+ }
+ }
+
+ /**
+ * Returns human readable form of the edited value.
+ *
+ * @return string reprezentation
+ */
+ public String getAsText() {
+ File file = (File) getValue();
+ if (file == null) {
+ return ""; // NOI18N
+ }
+ String path = file.getPath();
+ // Dot is more friendly to people though Java itself would prefer blank:
+ if ("".equals(path)) {
+ path = "."; // NOI18N
+ }
+ return path;
+ }
+
+ /**
+ * Parses the given string and should create a new instance of the edited object.
+ *
+ * @param str string reprezentation of the file (used as a parameter for File).
+ * @throws IllegalArgumentException If the given string cannot be parsed
+ */
+ public void setAsText(String str) throws IllegalArgumentException {
+ if (str == null) {
+ throw new IllegalArgumentException("null"); // NOI18N
+ }
+ if ("".equals(str)) { // NOI18N
+ setValue(null);
+ return;
+ }
+ // See getAsText.
+ if (".".equals(str)) {
+ str = ""; // NOI18N
+ }
+ setValue(new File(str));
+ }
+
+ /**
+ * Custon editor.
+ *
+ * @return Returns custom editor component.
+ */
+ public Component getCustomEditor() {
+ if (!editable) {
+ String info = "";
+ Object curVal = getValue();
+ if (curVal instanceof java.io.File) {
+ info = ((java.io.File) curVal).getAbsolutePath();
+ }
+ return new StringCustomEditor(info, false, true, null, this, env);
+ }
+ if (chooser == null) {
+ chooser = createHackedFileChooser();
+
+ File originalFile = (File) getValue();
+ if (originalFile != null && !originalFile.isAbsolute() && baseDirectory != null) {
+ originalFile = new File(baseDirectory, originalFile.getPath());
+ }
+ if (currentDirectory != null) {
+ chooser.setCurrentDirectory(currentDirectory);
+ } else if (originalFile != null && originalFile.getParentFile() != null) {
+ chooser.setCurrentDirectory(originalFile.getParentFile());
+ chooser.setSelectedFile(originalFile);
+ } else if (lastCurrentDir != null) {
+ chooser.setCurrentDirectory(lastCurrentDir);
+ }
+ chooser.setFileSelectionMode(mode);
+ if (fileFilter != null) {
+ chooser.setFileFilter(fileFilter);
+ }
+ switch (mode) {
+ case JFileChooser.FILES_AND_DIRECTORIES:
+ chooser.setDialogTitle(getString("CTL_DialogTitleFilesAndDirs"));
+ break;
+ case JFileChooser.FILES_ONLY:
+ chooser.setDialogTitle(getString("CTL_DialogTitleFiles"));
+ break;
+ case JFileChooser.DIRECTORIES_ONLY:
+ chooser.setDialogTitle(getString("CTL_DialogTitleDirs"));
+ break;
+ }
+ chooser.setFileHidingEnabled(fileHiding);
+
+ chooser.setControlButtonsAreShown(false);
+
+ chooser.addPropertyChangeListener(
+ JFileChooser.SELECTED_FILE_CHANGED_PROPERTY,
+ this
+ );
+
+ HelpCtx.setHelpIDString(chooser, getHelpCtx().getHelpID());
+ }
+
+ return chooser;
+ }
+
+ /**
+ * Implements PropertyEditor method.
+ *
+ * @return Returns true.
+ */
+ public boolean supportsCustomEditor() {
+ return true;
+ }
+
+ /**
+ * Should create a string insertable to the newly generated source code.
+ *
+ * @return initialization string
+ */
+ public String getJavaInitializationString() {
+ File value = (File) getValue();
+ if (value == null) {
+ return "null"; // NOI18N
+ } else {
+ // [PENDING] not a full escape of filenames, but enough to at least
+ // handle normal Windows backslashes
+ if (baseDirectory != null && !value.isAbsolute()) {
+ return "new java.io.File(" // NOI18N
+ + stringify(baseDirectory.getPath())
+ + ", " // NOI18N
+ + stringify(value.getPath())
+ + ")"; // NOI18N
+ } else {
+ return "new java.io.File(" // NOI18N
+ + stringify(value.getAbsolutePath())
+ + ")"; // NOI18N
+ }
+ }
+ }
+
+ static String stringify(String in) {
+ StringBuilder buf = new StringBuilder(in.length() * 2 + 2);
+ buf.append('"'); // NOI18N
+ for (int i = 0; i < in.length(); i++) {
+ char c = in.charAt(i);
+ if (c == '\\' || c == '"') { // NOI18N
+ buf.append('\\'); // NOI18N
+ }
+ buf.append(c);
+ }
+ buf.append('"'); // NOI18N
+ return buf.toString();
+ }
+
+ /**
+ * Gets help context.
+ */
+ private HelpCtx getHelpCtx() {
+ return new HelpCtx(FileEditor.class);
+ }
+
+ /**
+ * Gets localized string. Helper method.
+ */
+ private static String getString(String key) {
+ return NbBundle.getBundle(FileEditor.class).getString(key);
+ }
+
+ /**
+ * Gets relative path of file to specified directory only for case the file is in directory tree.
+ *
+ * @param baseDir base directory
+ * @param file file which relative path to <code>baseDir</code> is needed
+ * @return relative path or <code>null</code> can't be resolved or if the <code>file</code> is not under <code>baseDir</code> tree
+ */
+ static String getChildRelativePath(File baseDir, File file) {
+ // Handle hypothetical weird situations where file is in baseDir
+ // but the prefixes do not match. E.g.:
+ // file=\foo\bar.txt (assumed to be on C:) baseDir=c:\foo
+ if (file.equals(baseDir)) {
+ // The empty pathname, not ".", is correct here I think...
+ // Try making new File(new File("/tmp", x)) for x in {".", ""}
+ return ""; // NOI18N
+ }
+ StringBuilder buf = new StringBuilder(file.getPath().length());
+ buf.append(file.getName());
+ for (File parent = file.getParentFile(); parent != null; parent = parent.getParentFile()) {
+ if (parent.equals(baseDir)) {
+ return buf.toString();
+ }
+ buf.insert(0, File.separatorChar);
+ buf.insert(0, parent.getName());
+ }
+ return null;
+ }
+
+ /**
+ * Property change listaner attached to the JFileChooser chooser.
+ */
+ public void propertyChange(PropertyChangeEvent e) {
+ JFileChooser chooser = (JFileChooser) e.getSource();
+ File f = chooser.getSelectedFile();
+ if (f == null) {
+ return;
+ }
+ if (!files && f.isFile()) {
+ return;
+ }
+ if (!directories && f.isDirectory()) {
+ return;
+ }
+
+ if (baseDirectory != null) {
+ String rel = getChildRelativePath(baseDirectory, f);
+ if (rel != null) {
+ f = new File(rel);
+ }
+ }
+
+ // use to be setValue(f) - the next line is
+ // workaround for JDK bug 4533419
+ // it should be returned back to setValue(f) after the
+ // mentioned bug is fixed in JDK.
+ setValue(new File(f.getPath()));
+
+ lastCurrentDir = chooser.getCurrentDirectory();
+ }
+
+ // XXX #18270. Enter doesn't work when expecting folder change,
+ // Accessibility problem. We hack default behaviour here.
+ /**
+ * Creates hacked fileChooser, responding on Enter the way it performs folder change.
+ */
+ public static JFileChooser createHackedFileChooser() {
+ JFileChooser chooser = new JFileChooser();
+ hackFileChooser(chooser);
+ return chooser;
+ }
+
+ /**
+ * Hacks fileChooser, responding on Enter the way it performs folder change.
+ */
+ public static void hackFileChooser(final JFileChooser chooser) {
+ chooser.getAccessibleContext().setAccessibleDescription(getString("ACSD_FileEditor"));
+
+ //issue 31605 - make escape work properly
+ //Get the existing action key on ESCAPE
+ // XXX is this hack still necessary?
+ final Object key = chooser.getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT).get(
+ KeyStroke.getKeyStroke(KeyEvent.VK_ESCAPE, 0));
+
+ Action close = new AbstractAction() {
+ public void actionPerformed(ActionEvent ae) {
+ Component comp = KeyboardFocusManager.getCurrentKeyboardFocusManager().getFocusOwner();
+ if (key != null) {
+ //if there was an action, do it first
+ Action a = chooser.getActionMap().get(key);
+ if (a != null) {
+ a.actionPerformed(ae);
+ }
+ }
+ if (comp.getParent() == null) {
+ //then we were editing a file name, and the editor
+ //was removed - we don't want to close the dialog
+ return;
+ }
+
+ Container c = chooser.getTopLevelAncestor();
+ //The action *may* have already hidden the panel (works
+ //intermittently)
+ if (c instanceof Dialog) {
+ if (((Dialog) c).isVisible()) {
+ ((Dialog) c).setVisible(false);
+ ((Dialog) c).dispose();
+ }
+ }
+ }
+ };
+ chooser.getInputMap(JComponent.WHEN_ANCESTOR_OF_FOCUSED_COMPONENT).put(
+ KeyStroke.getKeyStroke(KeyEvent.VK_ESCAPE, 0), "close");
+ chooser.getActionMap().put("close", close);
+ }
+
+ private static class ButtonHider implements PropertyChangeListener {
+
+ public void propertyChange(PropertyChangeEvent pce) {
+ if (JFileChooser.CONTROL_BUTTONS_ARE_SHOWN_CHANGED_PROPERTY.equals(pce.getPropertyName())) {
+ JFileChooser jfc = (JFileChooser) pce.getSource();
+ try {
+ hideShowButtons(jfc, Boolean.TRUE.equals(pce.getNewValue()));
+ } catch (Exception e) {
+ Logger.getLogger(FileEditor.class.getName()).log(Level.WARNING, null, e);
+ }
+ }
+ }
+
+ private void hideShowButtons(Container cont, boolean val) {
+ if (cont instanceof JComboBox || cont instanceof JScrollBar) {
+ return;
+ }
+ Component[] c = cont.getComponents();
+ for (int i = 0; i < c.length; i++) {
+ if (c[i] instanceof Container) {
+ hideShowButtons((Container) c[i], val);
+ }
+ if (c[i] instanceof AbstractButton) {
+ c[i].setVisible(val);
+ }
+ }
+ }
+ }
+
+ /**
+ * Wraps java.io.FileFilter to javax.swing.filechooser.FileFilter.
+ */
+ static class DelegatingFileFilter extends javax.swing.filechooser.FileFilter {
+
+ private java.io.FileFilter filter;
+
+ public DelegatingFileFilter(java.io.FileFilter f) {
+ this.filter = f;
+ }
+
+ public boolean accept(File f) {
+ return filter.accept(f);
+ }
+
+ public String getDescription() {
+ // [PENDING] what should we return?
+ return null;
+ }
+
+ } // End of class DelegatingFileFilter.
+
+ /**
+ * Wraps FilenameFilter to javax.swing.filechooser.FileFilter.
+ */
+ static class DelegatingFilenameFilter extends javax.swing.filechooser.FileFilter {
+
+ private FilenameFilter filter;
+
+ public DelegatingFilenameFilter(FilenameFilter f) {
+ this.filter = f;
+ }
+
+ /**
+ * Calls the filenameFilter's accept method with arguments created from the original object f.
+ */
+ public boolean accept(File f) {
+ return filter.accept(f.getParentFile(), f.getName());
+ }
+
+ public String getDescription() {
+ // [PENDING] what should we return?
+ return null;
+ }
+ } // End of class DelegatingFilenameFilter.
+
+}
Added: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/StringCustomEditor.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/StringCustomEditor.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/editor/StringCustomEditor.java 2014-02-25 21:16:52 UTC (rev 8629)
@@ -0,0 +1,194 @@
+/*
+Copier depuis le source Netbeans
+ */
+
+package org.fudaa.fudaa.crue.common.editor;
+
+import java.beans.PropertyChangeEvent;
+import java.beans.PropertyChangeListener;
+import java.beans.PropertyEditor;
+import org.openide.explorer.propertysheet.PropertyEnv;
+import org.openide.util.NbBundle;
+import javax.swing.*;
+import javax.swing.border.*;
+import javax.swing.text.JTextComponent;
+import java.awt.BorderLayout;
+
+/**
+ * A custom editor for Strings.
+ *
+* @author Ian Formanek
+ * @version 1.00, Sep 21, 1998
+ */
+public class StringCustomEditor extends javax.swing.JPanel implements PropertyChangeListener {
+
+ static final long serialVersionUID = 7348579663907322425L;
+
+ boolean oneline = false;
+ String instructions = null;
+
+ private PropertyEnv env;
+
+ private PropertyEditor editor;
+
+ //enh 29294, provide one line editor on request
+ /**
+ * Create a StringCustomEditor.
+ *
+ * @param value the initial value for the string
+ * @param editable whether to show the editor in read only or read-write mode
+ * @param oneline whether the text component should be a single-line or multi-line component
+ * @param instructions any instructions that should be displayed
+ */
+ StringCustomEditor(String value, boolean editable, boolean oneline, String instructions, PropertyEditor editor, PropertyEnv env) {
+ this.oneline = oneline;
+ this.instructions = instructions;
+ this.env = env;
+ this.editor = editor;
+
+ this.env.setState(PropertyEnv.STATE_NEEDS_VALIDATION);
+ this.env.addPropertyChangeListener(this);
+
+ init(value, editable);
+ }
+
+ /**
+ * Initializes the Form
+ *
+ * @deprecated Nothing should be using this constructor
+ */
+ public StringCustomEditor(String s, boolean editable) {
+ init(s, editable);
+ }
+
+ private void init(String s, boolean editable) {
+ setLayout(new java.awt.BorderLayout());
+ if (oneline) {
+ textArea = new javax.swing.JTextField();
+ add(textArea, BorderLayout.CENTER);
+ } else {
+ textAreaScroll = new javax.swing.JScrollPane();
+ textArea = new javax.swing.JTextArea();
+ textAreaScroll.setViewportView(textArea);
+ add(textAreaScroll, BorderLayout.CENTER);
+ }
+ //original constructor code
+ textArea.setEditable(editable);
+
+ int from = 0;
+ int to = 0;
+ int ctn = 1;
+ while ((to = s.indexOf("\n", from)) > 0) {
+ ctn++;
+ from = to + 1;
+ }
+
+ textArea.setText(s);
+ if (textArea instanceof JTextArea && s.length() < 1E4) {
+ ((JTextArea) textArea).setWrapStyleWord(true);
+ ((JTextArea) textArea).setLineWrap(true);
+ setPreferredSize(new java.awt.Dimension(500, 300));
+ } else {
+ textArea.setMinimumSize(new java.awt.Dimension(100, 20));
+ if (textArea instanceof JTextArea) {
+ //Some gargantuan string value - do something that will
+ //show it. Line wrap is off, otherwise it will spend
+ //minutes trying to calculate preferred size, etc.
+ setPreferredSize(new java.awt.Dimension(500, 300));
+ }
+ }
+
+ if (!editable) {
+ // hack to fix #9219
+ //TODO Fix this to use UIManager values, this is silly
+ JTextField hack = new JTextField();
+ hack.setEditable(false);
+ textArea.setBackground(hack.getBackground());
+ textArea.setForeground(hack.getForeground());
+ }
+
+ setBorder(BorderFactory.createEmptyBorder(12, 12, 0, 11));
+
+ textArea.getAccessibleContext().setAccessibleName(NbBundle.getBundle(StringCustomEditor.class).getString("ACS_TextArea")); //NOI18N
+ if (instructions == null) {
+ textArea.getAccessibleContext().setAccessibleDescription(NbBundle.getBundle(StringCustomEditor.class).getString("ACSD_TextArea")); //NOI18N
+ } else {
+ textArea.getAccessibleContext().setAccessibleDescription(instructions);
+ }
+ getAccessibleContext().setAccessibleDescription(NbBundle.getBundle(StringCustomEditor.class).getString("ACSD_CustomStringEditor")); //NOI18N
+ //Layout is not quite smart enough about text field along with variable
+ //size text area
+ int prefHeight;
+
+ //IZ 44152, Debugger can produce 512K+ length strings, avoid excessive
+ //iterations (which textArea.getPreferredSize() will definitely do)
+ if (s.length() < 1024) {
+ prefHeight = textArea.getPreferredSize().height + 8;
+ } else {
+ prefHeight = ctn * 8;
+ }
+
+ if (instructions != null) {
+ final JTextArea jta = new JTextArea(instructions);
+ jta.setEditable(false);
+ java.awt.Color c = UIManager.getColor("control"); //NOI18N
+ if (c != null) {
+ jta.setBackground(c);
+ } else {
+ jta.setBackground(getBackground());
+ }
+ jta.setLineWrap(true);
+ jta.setWrapStyleWord(true);
+ jta.setFont(getFont());
+ add(jta, BorderLayout.NORTH, 0);
+ jta.getAccessibleContext().setAccessibleName(
+ NbBundle.getMessage(StringCustomEditor.class,
+ "ACS_Instructions")); //NOI18N
+ jta.getAccessibleContext().setAccessibleDescription(
+ NbBundle.getMessage(StringCustomEditor.class,
+ "ACSD_Instructions")); //NOI18N
+ prefHeight += jta.getPreferredSize().height;
+ //jlf guidelines - auto select text when clicked
+ jta.addFocusListener(new java.awt.event.FocusListener() {
+ public void focusGained(java.awt.event.FocusEvent e) {
+ jta.setSelectionStart(0);
+ jta.setSelectionEnd(jta.getText().length());
+ }
+
+ public void focusLost(java.awt.event.FocusEvent e) {
+ jta.setSelectionStart(0);
+ jta.setSelectionEnd(0);
+ }
+ });
+ }
+ if (textArea instanceof JTextField) {
+ setPreferredSize(new java.awt.Dimension(300,
+ prefHeight));
+ }
+ }
+
+ public void addNotify() {
+ super.addNotify();
+ //force focus to the editable area
+ if (isEnabled() && isFocusable()) {
+ textArea.requestFocus();
+ }
+ }
+
+ /**
+ * @return Returns the property value that is result of the CustomPropertyEditor.
+ * @exception InvalidStateException when the custom property editor does not represent valid property value (and thus it should not be set)
+ */
+ private Object getPropertyValue() throws IllegalStateException {
+ return textArea.getText();
+ }
+
+ public void propertyChange(PropertyChangeEvent evt) {
+ if (PropertyEnv.PROP_STATE.equals(evt.getPropertyName()) && evt.getNewValue() == PropertyEnv.STATE_VALID) {
+ editor.setValue(getPropertyValue());
+ }
+ }
+
+ private javax.swing.JScrollPane textAreaScroll;
+ private JTextComponent textArea;
+}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-02-28 11:13:30
|
Revision: 8642
http://sourceforge.net/p/fudaa/svn/8642
Author: deniger
Date: 2014-02-28 11:13:25 +0000 (Fri, 28 Feb 2014)
Log Message:
-----------
Modification de ?\194?\171 Build/Compile/Java Platform
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-io/nb-configuration.xml
trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml
trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml
trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml
trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml
trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml
trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml
trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml
trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml
trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml
trunk/soft/fudaa-crue/ui-post/nb-configuration.xml
trunk/soft/fudaa-crue/ui-report/nb-configuration.xml
trunk/soft/fudaa-crue/ui-study/nb-configuration.xml
trunk/soft/fudaa-crue/ui-sysdoc/nb-configuration.xml
trunk/soft/fudaa-crue/ui-wrapper/nb-configuration.xml
Modified: trunk/soft/fudaa-crue/crue-io/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-io/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/crue-io/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,22 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<config-data xmlns="http://www.netbeans.org/ns/maven-config-data/1">
<configurations/>
</config-data>
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
<netbeans.compile.on.save>test</netbeans.compile.on.save>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,19 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
<netbeans.compile.on.save>none</netbeans.compile.on.save>
- <netbeans.hint.jdkPlatform>JDK_1.7_051</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-post/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-post/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-post/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-report/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-report/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-report/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,19 +1,19 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
<netbeans.compile.on.save>test</netbeans.compile.on.save>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-study/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-study/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-study/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
@@ -1,18 +1,18 @@
<?xml version="1.0" encoding="UTF-8"?>
<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
+ <!--
+This file contains additional configuration written by modules in the NetBeans IDE.
+The configuration is intended to be shared among all the users of project and
+therefore it is assumed to be part of version control checkout.
+Without this configuration present, some functionality in the IDE may be limited or fail altogether.
-->
<properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
-->
- <netbeans.hint.jdkPlatform>JDK_1.6</netbeans.hint.jdkPlatform>
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
</properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/ui-sysdoc/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-sysdoc/nb-configuration.xml 2014-02-28 10:46:31 UTC (rev 8641)
+++ trunk/soft/fudaa-crue/ui-sysdoc/nb-confi...
[truncated message content] |
|
From: <de...@us...> - 2014-02-28 11:18:57
|
Revision: 8643
http://sourceforge.net/p/fudaa/svn/8643
Author: deniger
Date: 2014-02-28 11:18:52 +0000 (Fri, 28 Feb 2014)
Log Message:
-----------
Modification de ?\194?\171 Build/Compile/Java Platform
Removed Paths:
-------------
trunk/soft/fudaa-crue/crue-io/nb-configuration.xml
trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml
trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml
trunk/soft/fudaa-crue/ui-common/nb-configuration.xml
trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml
trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml
trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml
trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml
trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml
trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml
trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml
trunk/soft/fudaa-crue/ui-post/nb-configuration.xml
trunk/soft/fudaa-crue/ui-study/nb-configuration.xml
trunk/soft/fudaa-crue/ui-sysdoc/nb-configuration.xml
trunk/soft/fudaa-crue/ui-wrapper/nb-configuration.xml
Deleted: trunk/soft/fudaa-crue/crue-io/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-io/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/crue-io/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,22 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <config-data xmlns="http://www.netbeans.org/ns/maven-config-data/1">
- <configurations/>
- </config-data>
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- <netbeans.compile.on.save>test</netbeans.compile.on.save>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-branding/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-commandline/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-common/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-common/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-common/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.compile.on.save>none</netbeans.compile.on.save>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-comparison/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-emh/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-loader/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-loi/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-modelling/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,19 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.compile.on.save>none</netbeans.compile.on.save>
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-otfa/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-planimetry/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-post/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-post/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-post/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-study/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-study/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-study/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-sysdoc/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-sysdoc/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-sysdoc/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
Deleted: trunk/soft/fudaa-crue/ui-wrapper/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-wrapper/nb-configuration.xml 2014-02-28 11:13:25 UTC (rev 8642)
+++ trunk/soft/fudaa-crue/ui-wrapper/nb-configuration.xml 2014-02-28 11:18:52 UTC (rev 8643)
@@ -1,18 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<project-shared-configuration>
- <!--
-This file contains additional configuration written by modules in the NetBeans IDE.
-The configuration is intended to be shared among all the users of project and
-therefore it is assumed to be part of version control checkout.
-Without this configuration present, some functionality in the IDE may be limited or fail altogether.
--->
- <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
- <!--
-Properties that influence various parts of the IDE, especially code formatting and the like.
-You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
-That way multiple projects can share the same settings (useful for formatting rules for example).
-Any value defined here will override the pom.xml file value but is only applicable to the current project.
--->
- <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
- </properties>
-</project-shared-configuration>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-03-04 11:11:48
|
Revision: 8647
http://sourceforge.net/p/fudaa/svn/8647
Author: deniger
Date: 2014-03-04 11:11:45 +0000 (Tue, 04 Mar 2014)
Log Message:
-----------
CRUE-543: deboguage
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-application/src/main/resources/etc/fudaacrueDev.conf
trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/CheckThreadViolationRepaintManager.java
Modified: trunk/soft/fudaa-crue/ui-application/src/main/resources/etc/fudaacrueDev.conf
===================================================================
--- trunk/soft/fudaa-crue/ui-application/src/main/resources/etc/fudaacrueDev.conf 2014-03-04 09:33:20 UTC (rev 8646)
+++ trunk/soft/fudaa-crue/ui-application/src/main/resources/etc/fudaacrueDev.conf 2014-03-04 11:11:45 UTC (rev 8647)
@@ -3,7 +3,7 @@
# options used by the launcher by default, can be overridden by explicit
# command line switches
-default_options="-J-Ddev.etcDir="C:\data\Fudaa-Crue\etc" -J-Xmx512m --branding fudaacrue -J-Dsydoc-admin=true"
+default_options="-J-Ddev.etcDir="C:\data\Fudaa-Crue\etc" -J-Xmx512m --branding fudaacrue -J-Dsydoc-admin=true -J-Ddebug-swing=true"
# for development purposes you may wish to append: -J-Dnetbeans.logger.console=true -J-ea
# default location of JDK/JRE, can be overridden by using --jdkhome <dir> switch
Added: trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/CheckThreadViolationRepaintManager.java
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/CheckThreadViolationRepaintManager.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/CheckThreadViolationRepaintManager.java 2014-03-04 11:11:45 UTC (rev 8647)
@@ -0,0 +1,155 @@
+/*
+ GPL 2
+ */
+
+package org.fudaa.fudaa.crue.branding;
+
+import java.lang.ref.WeakReference;
+import javax.swing.JButton;
+import javax.swing.JComponent;
+import javax.swing.JEditorPane;
+import javax.swing.JFrame;
+import javax.swing.RepaintManager;
+import javax.swing.SwingUtilities;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class CheckThreadViolationRepaintManager extends RepaintManager {
+
+ // it is recommended to pass the complete check
+ private boolean completeCheck = true;
+ private WeakReference<JComponent> lastComponent;
+
+ public CheckThreadViolationRepaintManager(boolean completeCheck) {
+ this.completeCheck = completeCheck;
+ }
+
+ public CheckThreadViolationRepaintManager() {
+ this(true);
+ }
+
+ public boolean isCompleteCheck() {
+ return completeCheck;
+ }
+
+ public void setCompleteCheck(boolean completeCheck) {
+ this.completeCheck = completeCheck;
+ }
+
+ public synchronized void addInvalidComponent(JComponent component) {
+ checkThreadViolations(component);
+ super.addInvalidComponent(component);
+ }
+
+ public void addDirtyRegion(JComponent component, int x, int y, int w, int h) {
+ checkThreadViolations(component);
+ super.addDirtyRegion(component, x, y, w, h);
+ }
+
+ private void checkThreadViolations(JComponent c) {
+ if (!SwingUtilities.isEventDispatchThread() && (completeCheck || c.isShowing())) {
+ boolean repaint = false;
+ boolean fromSwing = false;
+ boolean imageUpdate = false;
+ StackTraceElement[] stackTrace = Thread.currentThread().getStackTrace();
+ for (StackTraceElement st : stackTrace) {
+ if (repaint && st.getClassName().startsWith("javax.swing.")
+ && // for details see
+ // https://swinghelper.dev.java.net/issues/show_bug.cgi?id=1
+ !st.getClassName().startsWith("javax.swing.SwingWorker")) {
+ fromSwing = true;
+ }
+ if (repaint && "imageUpdate".equals(st.getMethodName())) {
+ imageUpdate = true;
+ }
+ if ("repaint".equals(st.getMethodName())) {
+ repaint = true;
+ fromSwing = false;
+ }
+ }
+ if (imageUpdate) {
+ //assuming it is java.awt.image.ImageObserver.imageUpdate(...)
+ //image was asynchronously updated, that's ok
+ return;
+ }
+ if (repaint && !fromSwing) {
+ //no problems here, since repaint() is thread safe
+ return;
+ }
+ //ignore the last processed component
+ if (lastComponent != null && c == lastComponent.get()) {
+ return;
+ }
+ lastComponent = new WeakReference<JComponent>(c);
+ violationFound(c, stackTrace);
+ }
+ }
+
+ protected void violationFound(JComponent c, StackTraceElement[] stackTrace) {
+ System.out.println();
+ System.out.println("EDT violation detected");
+ System.out.println(c);
+ for (StackTraceElement st : stackTrace) {
+ System.out.println("\tat " + st);
+ }
+ }
+
+ public static void main(String[] args) throws Exception {
+ //set CheckThreadViolationRepaintManager
+ RepaintManager.setCurrentManager(new CheckThreadViolationRepaintManager());
+ //Valid code
+ SwingUtilities.invokeAndWait(new Runnable() {
+ public void run() {
+ test();
+ }
+ });
+ System.out.println("Valid code passed...");
+ repaintTest();
+ System.out.println("Repaint test - correct code");
+ //Invalide code (stack trace expected)
+ test();
+ }
+
+ static void test() {
+ JFrame frame = new JFrame("Am I on EDT?");
+ frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ frame.add(new JButton("JButton"));
+ frame.pack();
+ frame.setVisible(true);
+ frame.dispose();
+ }
+
+ //this test must pass
+ static void imageUpdateTest() {
+ JFrame frame = new JFrame();
+ frame.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
+ JEditorPane editor = new JEditorPane();
+ frame.setContentPane(editor);
+ editor.setContentType("text/html");
+ //it works with no valid image as well
+ editor.setText("<html><img src=\"file:\\lala.png\"></html>");
+ frame.setSize(300, 200);
+ frame.setVisible(true);
+ }
+
+ private static JButton test;
+
+ static void repaintTest() {
+ try {
+ SwingUtilities.invokeAndWait(new Runnable() {
+ public void run() {
+ test = new JButton();
+ test.setSize(100, 100);
+ }
+ });
+ } catch (Exception e) {
+ e.printStackTrace();
+ }
+ // repaint(Rectangle) should be ok
+ test.repaint(test.getBounds());
+ test.repaint(0, 0, 100, 100);
+ test.repaint();
+ }
+}
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java 2014-03-04 09:33:20 UTC (rev 8646)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/java/org/fudaa/fudaa/crue/branding/InitGeneralUIInstaller.java 2014-03-04 11:11:45 UTC (rev 8647)
@@ -7,6 +7,7 @@
import javax.swing.BorderFactory;
import javax.swing.JFrame;
import javax.swing.JPanel;
+import javax.swing.RepaintManager;
import javax.swing.border.Border;
import org.openide.awt.Toolbar;
import org.openide.awt.ToolbarPool;
@@ -62,6 +63,9 @@
perspective.add(buttons, BorderLayout.SOUTH);
perspective.setBorder(BorderFactory.createEmptyBorder(0, 5, 0, 5));
}
+ if ("true".equals(System.getProperty("debug-swing"))) {
+ RepaintManager.setCurrentManager(new CheckThreadViolationRepaintManager());
+ }
}
public static Toolbar getPerspectiveToolbar(Toolbar[] in) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-03-04 23:30:40
|
Revision: 8652
http://sourceforge.net/p/fudaa/svn/8652
Author: deniger
Date: 2014-03-04 23:30:37 +0000 (Tue, 04 Mar 2014)
Log Message:
-----------
CRUE-617
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-project/pom.xml
Added Paths:
-----------
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/IndexSaverTest.java
trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/ReportViewLineInfoTest.java
trunk/soft/fudaa-crue/crue-project/src/test/resources/org/
trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/
trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/
trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/crue/
trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/crue/projet/
trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/crue/projet/report/
trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/crue/projet/report/index.xml
Removed Paths:
-------------
trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/ReportViewLineInfoTest.java
trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/persist/IndexSaverTest.java
Modified: trunk/soft/fudaa-crue/crue-project/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-project/pom.xml 2014-03-04 23:30:10 UTC (rev 8651)
+++ trunk/soft/fudaa-crue/crue-project/pom.xml 2014-03-04 23:30:37 UTC (rev 8652)
@@ -49,6 +49,11 @@
<scope>test</scope>
</dependency>
<dependency>
+ <groupId>org.netbeans.api</groupId>
+ <artifactId>org-netbeans-api-progress</artifactId>
+ <version>${netbeans.version}</version>
+ </dependency>
+ <dependency>
<groupId>commons-collections</groupId>
<artifactId>commons-collections</artifactId>
</dependency>
Copied: trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/IndexSaverTest.java (from rev 8645, trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/persist/IndexSaverTest.java)
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/IndexSaverTest.java (rev 0)
+++ trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/IndexSaverTest.java 2014-03-04 23:30:37 UTC (rev 8652)
@@ -0,0 +1,62 @@
+/*
+ GPL 2
+ */
+package org.fudaa.dodico.crue.projet.report;
+
+import java.io.File;
+import java.util.List;
+import org.fudaa.dodico.crue.common.transformer.DateDurationConverter;
+import org.fudaa.dodico.crue.io.AbstractIOTestCase;
+import org.fudaa.dodico.crue.common.io.CrueIOResu;
+import org.fudaa.dodico.crue.test.FileTest;
+import static org.junit.Assert.*;
+import org.junit.Test;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class IndexSaverTest extends FileTest {
+
+ private String auteurCreation = "AuteurCreation";
+ private String auteurDerniereModif = "AuteurDerniereModif";
+
+ public IndexSaverTest() {
+ }
+
+ @Test
+ public void testRead() {
+ File file = AbstractIOTestCase.getFile("/org/fudaa/dodico/crue/projet/report/index.xml");
+ assertTrue(file.exists());
+ ReportIndexReader saver = new ReportIndexReader();
+ CrueIOResu<List<ReportViewLineInfo>> read = saver.read(file);
+ List<ReportViewLineInfo> metier = read.getMetier();
+ testResult(metier,
+ DateDurationConverter.getDate("2012-10-09T12:02:23.853").toDateTime().getMillis(),
+ DateDurationConverter.getDate("2012-10-09T12:02:33.853").toDateTime().getMillis(), "fileName 1", "fileName 2");
+ file.delete();
+
+ }
+
+ private void testGeneralInfos(final ReportViewLineInfo line, final long creationDate, final long modificationDate) {
+ assertEquals(auteurCreation, line.getAuteurCreation());
+ assertEquals(auteurDerniereModif, line.getAuteurDerniereModif());
+ assertEquals(creationDate, line.getDateCreation().toDateTime().getMillis());
+ assertEquals(modificationDate, line.getDateDerniereModif().toDateTime().getMillis());
+ }
+
+ private void testResult(List<ReportViewLineInfo> metier, final long creationDate, final long modificationDate, final String fileNameOne,
+ final String fileNameTwo) {
+ assertEquals(2, metier.size());
+ ReportViewLineInfo line = metier.get(0);
+ assertEquals("Vue 1", line.getNom());
+ assertEquals(fileNameOne, line.getFilename());
+ assertEquals(fileNameOne, line.getCommentaire());
+ testGeneralInfos(line, creationDate, modificationDate);
+ line = metier.get(1);
+ assertEquals("Vue 2", line.getNom());
+ assertEquals(fileNameTwo, line.getFilename());
+ assertEquals(fileNameTwo, line.getCommentaire());
+ testGeneralInfos(line, creationDate, modificationDate);
+ }
+}
Copied: trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/ReportViewLineInfoTest.java (from rev 8645, trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/ReportViewLineInfoTest.java)
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/ReportViewLineInfoTest.java (rev 0)
+++ trunk/soft/fudaa-crue/crue-project/src/test/java/org/fudaa/dodico/crue/projet/report/ReportViewLineInfoTest.java 2014-03-04 23:30:37 UTC (rev 8652)
@@ -0,0 +1,58 @@
+/*
+ GPL 2
+ */
+package org.fudaa.dodico.crue.projet.report;
+
+import org.fudaa.dodico.crue.common.ConnexionInformationDefault;
+import org.fudaa.dodico.crue.common.ConnexionInformationFixed;
+import org.joda.time.LocalDateTime;
+import static org.junit.Assert.*;
+import org.junit.Test;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class ReportViewLineInfoTest {
+
+ public ReportViewLineInfoTest() {
+ }
+
+ @Test
+ public void testCloned() {
+ ReportViewLineInfo info = new ReportViewLineInfo();
+ info.setCommentaire("commentaire");
+ info.setDateCreation(new LocalDateTime());
+ info.setAuteurCreation("Tester");
+ ReportViewLineInfo cloned = info.clone();
+ assertEquals(info.getCommentaire(), cloned.getCommentaire());
+ assertEquals(info.getDateCreation(), cloned.getDateCreation());
+
+ ConnexionInformationFixed ci = new ConnexionInformationFixed(new ConnexionInformationDefault());
+ info.updateEdited(ci);
+ assertEquals(info.getAuteurDerniereModif(), ci.getCurrentUser());
+ assertEquals(info.getDateDerniereModif(), ci.getCurrentDate());
+ }
+
+ @Test
+ public void testCopy() {
+ ReportViewLineInfo info = new ReportViewLineInfo();
+ info.setCommentaire("commentaire");
+ info.setDateCreation(new LocalDateTime(0));
+ info.setAuteurCreation("Tester");
+ info.setAuteurDerniereModif("modifier");
+ info.setDateDerniereModif(new LocalDateTime(10));
+ info.setFilename("filename");
+
+ ConnexionInformationFixed ci = new ConnexionInformationFixed(new ConnexionInformationDefault());
+ assertNotSame(info.getAuteurCreation(), ci.getCurrentUser());
+ assertNotSame(info.getAuteurDerniereModif(), ci.getCurrentUser());
+ ReportViewLineInfo copy = info.copy(ci);
+ assertEquals(info.getCommentaire(), copy.getCommentaire());
+ assertEquals(ci.getCurrentUser(), copy.getAuteurCreation());
+ assertEquals(ci.getCurrentUser(), copy.getAuteurDerniereModif());
+ assertEquals(ci.getCurrentDate(), copy.getDateCreation());
+ assertEquals(ci.getCurrentDate(), copy.getDateDerniereModif());
+ assertNull(copy.getFilename());
+ }
+}
Added: trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/crue/projet/report/index.xml
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/crue/projet/report/index.xml (rev 0)
+++ trunk/soft/fudaa-crue/crue-project/src/test/resources/org/fudaa/dodico/crue/projet/report/index.xml 2014-03-04 23:30:37 UTC (rev 8652)
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ReportIndex xmlns="http://www.fudaa.fr/xsd/crue" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.fudaa.fr/xsd/crue http://www.fudaa.fr/xsd/crue/report-index-1.0.xsd">
+ <Commentaire></Commentaire>
+ <Type>longitudinal</Type>
+ <VueConfig>
+ <Nom>Vue 1</Nom>
+ <Commentaire>fileName 1</Commentaire>
+ <Filename>fileName 1</Filename>
+ <AuteurCreation>AuteurCreation</AuteurCreation>
+ <DateCreation>2012-10-09T12:02:23.853</DateCreation>
+ <AuteurDerniereModif>AuteurDerniereModif</AuteurDerniereModif>
+ <DateDerniereModif>2012-10-09T12:02:33.853</DateDerniereModif>
+ </VueConfig>
+ <VueConfig>
+ <Nom>Vue 2</Nom>
+ <Commentaire>fileName 2</Commentaire>
+ <Filename>fileName 2</Filename>
+ <AuteurCreation>AuteurCreation</AuteurCreation>
+ <DateCreation>2012-10-09T12:02:23.853</DateCreation>
+ <AuteurDerniereModif>AuteurDerniereModif</AuteurDerniereModif>
+ <DateDerniereModif>2012-10-09T12:02:33.853</DateDerniereModif>
+ </VueConfig>
+</ReportIndex>
\ No newline at end of file
Deleted: trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/ReportViewLineInfoTest.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/ReportViewLineInfoTest.java 2014-03-04 23:30:10 UTC (rev 8651)
+++ trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/ReportViewLineInfoTest.java 2014-03-04 23:30:37 UTC (rev 8652)
@@ -1,58 +0,0 @@
-/*
- GPL 2
- */
-package org.fudaa.fudaa.crue.report.view;
-
-import org.fudaa.dodico.crue.common.ConnexionInformationDefault;
-import org.fudaa.dodico.crue.common.ConnexionInformationFixed;
-import org.joda.time.LocalDateTime;
-import static org.junit.Assert.*;
-import org.junit.Test;
-
-/**
- *
- * @author Frederic Deniger
- */
-public class ReportViewLineInfoTest {
-
- public ReportViewLineInfoTest() {
- }
-
- @Test
- public void testCloned() {
- ReportViewLineInfo info = new ReportViewLineInfo();
- info.setCommentaire("commentaire");
- info.setDateCreation(new LocalDateTime());
- info.setAuteurCreation("Tester");
- ReportViewLineInfo cloned = info.clone();
- assertEquals(info.getCommentaire(), cloned.getCommentaire());
- assertEquals(info.getDateCreation(), cloned.getDateCreation());
-
- ConnexionInformationFixed ci = new ConnexionInformationFixed(new ConnexionInformationDefault());
- info.updateEdited(ci);
- assertEquals(info.getAuteurDerniereModif(), ci.getCurrentUser());
- assertEquals(info.getDateDerniereModif(), ci.getCurrentDate());
- }
-
- @Test
- public void testCopy() {
- ReportViewLineInfo info = new ReportViewLineInfo();
- info.setCommentaire("commentaire");
- info.setDateCreation(new LocalDateTime(0));
- info.setAuteurCreation("Tester");
- info.setAuteurDerniereModif("modifier");
- info.setDateDerniereModif(new LocalDateTime(10));
- info.setFilename("filename");
-
- ConnexionInformationFixed ci = new ConnexionInformationFixed(new ConnexionInformationDefault());
- assertNotSame(info.getAuteurCreation(), ci.getCurrentUser());
- assertNotSame(info.getAuteurDerniereModif(), ci.getCurrentUser());
- ReportViewLineInfo copy = info.copy(ci);
- assertEquals(info.getCommentaire(), copy.getCommentaire());
- assertEquals(ci.getCurrentUser(), copy.getAuteurCreation());
- assertEquals(ci.getCurrentUser(), copy.getAuteurDerniereModif());
- assertEquals(ci.getCurrentDate(), copy.getDateCreation());
- assertEquals(ci.getCurrentDate(), copy.getDateDerniereModif());
- assertNull(copy.getFilename());
- }
-}
Deleted: trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/persist/IndexSaverTest.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/persist/IndexSaverTest.java 2014-03-04 23:30:10 UTC (rev 8651)
+++ trunk/soft/fudaa-crue/ui-report/src/test/java/org/fudaa/fudaa/crue/report/view/persist/IndexSaverTest.java 2014-03-04 23:30:37 UTC (rev 8652)
@@ -1,99 +0,0 @@
-/*
- GPL 2
- */
-package org.fudaa.fudaa.crue.report.view.persist;
-
-import java.io.File;
-import java.io.IOException;
-import java.util.Arrays;
-import java.util.List;
-import org.fudaa.ctulu.CtuluLog;
-import org.fudaa.dodico.crue.common.transformer.DateDurationConverter;
-import org.fudaa.dodico.crue.io.AbstractIOTestCase;
-import org.fudaa.dodico.crue.common.io.CrueIOResu;
-import org.fudaa.fudaa.crue.report.data.ReportContentType;
-import org.fudaa.fudaa.crue.report.view.ReportViewLine;
-import org.fudaa.fudaa.crue.report.view.ReportViewLineInfo;
-import org.joda.time.LocalDateTime;
-import static org.junit.Assert.*;
-import org.junit.Test;
-
-/**
- *
- * @author Frederic Deniger
- */
-public class IndexSaverTest extends FileTest {
-
- private String auteurCreation = "AuteurCreation";
- private String auteurDerniereModif = "AuteurDerniereModif";
-
- public IndexSaverTest() {
- }
-
- @Test
- public void testRead() {
- File file = AbstractIOTestCase.getFile("/org/fudaa/fudaa/crue/report/view/persist/index.xml");
- assertTrue(file.exists());
- IndexSaver saver = new IndexSaver();
- CrueIOResu<List<ReportViewLineInfo>> read = saver.read(file);
- List<ReportViewLineInfo> metier = read.getMetier();
- testResult(metier,
- DateDurationConverter.getDate("2012-10-09T12:02:23.853").toDateTime().getMillis(),
- DateDurationConverter.getDate("2012-10-09T12:02:33.853").toDateTime().getMillis(), "fileName 1", "fileName 2");
- file.delete();
-
- }
-
- @Test
- public void testWrite() throws IOException {
- IndexSaver saver = new IndexSaver();
- File target = createTempFile("index", ".xml");
- final long creationDate = System.currentTimeMillis() - 10000;
- final long modificationDate = System.currentTimeMillis();
- final String fileNameOne = "fileName 1";
- final String fileNameTwo = "fileName 2";
- ReportViewLine lineOne = new ReportViewLine(ReportContentType.LONGITUDINAL, createInfo(creationDate, modificationDate, fileNameOne), null, null, null);
- ReportViewLine lineTwo = new ReportViewLine(ReportContentType.LONGITUDINAL, createInfo(creationDate, modificationDate, fileNameTwo), null, null, null);
- lineOne.getInfo().setNom("Vue 1");
- lineTwo.getInfo().setNom("Vue 2");
- CtuluLog save = saver.save(target, Arrays.asList(lineOne, lineTwo), "longitudinal");
-
- assertTrue(save.isEmpty());
- CrueIOResu<List<ReportViewLineInfo>> read = saver.read(target);
- assertTrue(read.getAnalyse().isEmpty());
- List<ReportViewLineInfo> metier = read.getMetier();
- testResult(metier, creationDate, modificationDate, fileNameOne, fileNameTwo);
- }
-
- private ReportViewLineInfo createInfo(final long creationDate, final long modificationDate, final String fileName) {
- ReportViewLineInfo info = new ReportViewLineInfo();
- info.setAuteurCreation(auteurCreation);
- info.setAuteurDerniereModif(auteurDerniereModif);
- info.setDateCreation(new LocalDateTime(creationDate));
- info.setDateDerniereModif(new LocalDateTime(modificationDate));
- info.setFilename(fileName);
- info.setCommentaire(fileName);
- return info;
- }
-
- private void testGeneralInfos(final ReportViewLineInfo line, final long creationDate, final long modificationDate) {
- assertEquals(auteurCreation, line.getAuteurCreation());
- assertEquals(auteurDerniereModif, line.getAuteurDerniereModif());
- assertEquals(creationDate, line.getDateCreation().toDateTime().getMillis());
- assertEquals(modificationDate, line.getDateDerniereModif().toDateTime().getMillis());
- }
-
- private void testResult(List<ReportViewLineInfo> metier, final long creationDate, final long modificationDate, final String fileNameOne, final String fileNameTwo) {
- assertEquals(2, metier.size());
- ReportViewLineInfo line = metier.get(0);
- assertEquals("Vue 1", line.getNom());
- assertEquals(fileNameOne, line.getFilename());
- assertEquals(fileNameOne, line.getCommentaire());
- testGeneralInfos(line, creationDate, modificationDate);
- line = metier.get(1);
- assertEquals("Vue 2", line.getNom());
- assertEquals(fileNameTwo, line.getFilename());
- assertEquals(fileNameTwo, line.getCommentaire());
- testGeneralInfos(line, creationDate, modificationDate);
- }
-}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-04-02 22:21:29
|
Revision: 8691
http://sourceforge.net/p/fudaa/svn/8691
Author: deniger
Date: 2014-04-02 22:21:23 +0000 (Wed, 02 Apr 2014)
Log Message:
-----------
CRUE-617
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorBuilder.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegate.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateLongitudinal.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportGlobalService.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportResultService.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/config/AbstractReportGrapheBuilder.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/multivar/ReportMultiVarGrapheBuilder.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/rptg/ReportRPTGGrapheBuilder.java
Added Paths:
-----------
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateMultiVar.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateRPTG.java
Modified: trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
===================================================================
--- trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-04-02 22:21:23 UTC (rev 8691)
@@ -1320,4 +1320,8 @@
Export.Calcul.ColumnName=Calcul
Export.Temps.ColumnName=Temps
Report.RunNonCurrentIgnored=Les donn\u00e9es des runs alternatifs ne sont pas export\u00e9s
-otfa.report.longitudinalFirstColName=Branche / Section
\ No newline at end of file
+otfa.report.longitudinalFirstColName=Branche / Section
+otfa.report.exportTo=Export rapport {0} vers {1}
+otfa.report.emhNotFound=L''EMH {0} n''a pas \u00e9t\u00e9 trouv\u00e9e
+otfa.report.emhNoRPTG=L''EMH {0} ne poss\u00e8de pas de r\u00e9sultat de pr\u00e9-traitement
+otfa.report.exportRPTG.on=Export RPTG sur EMH
\ No newline at end of file
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -372,15 +372,15 @@
if (StringUtils.isNotEmpty(item.getRapport())) {
final CtuluLogGroup reportGroup = logs.createGroup("otfa.reportCreation");
reportGroup.setDescriptionArgs(item.getRapport());
- CtuluLogGroup logReport = new CtuluLogGroup(BusinessMessages.RESOURCE_BUNDLE);
if (managerScenario.getRunCourant() == null) {
- logReport.createNewLog("otfa.report.loading").addSevereError("otfa.report.notGenerated.NoCurrentRun");
+ reportGroup.createNewLog("otfa.report.loading").addSevereError("otfa.report.notGenerated.NoCurrentRun");
} else {
OtfaReportExecutor report = new OtfaReportExecutor(projet, managerScenario, emhScenario, item, campagne);
- report.exportCSV(logReport);
+ report.exportCSV(reportGroup);
}
+
}
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -116,7 +116,7 @@
File targetFile = null;
File modeleDir = projet.getDirForRunModele(managerScenario, managerScenario.getManagerFils(defaultModele.getId()), run);
if (CtuluLibString.isEmpty(targetCsvFile)) {
- targetCsvFile = report.getType().geti18n().toLowerCase() + "_" + CtuluLibFile.getSansExtension(xml.getName()) + ".csv";
+ targetCsvFile = report.getType().name().toLowerCase() + "_" + CtuluLibFile.getSansExtension(xml.getName()) + ".csv";
targetFile = new File(modeleDir, targetCsvFile).getAbsoluteFile();
} else {
targetFile = new File(targetCsvFile);
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorBuilder.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorBuilder.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorBuilder.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -11,13 +11,13 @@
* @author Frederic Deniger
*/
public class OtfaReportExecutorBuilder {
-
+
private final OtfaReportExecutor parent;
-
+
public OtfaReportExecutorBuilder(OtfaReportExecutor parent) {
this.parent = parent;
}
-
+
protected OtfaReportExecutorDelegate createDelegate(ReportConfigContrat config, ReportViewLineInfoAndType reportInfo,
OtfaReportGlobalService reportGlobalService) {
switch (config.getType()) {
@@ -25,8 +25,12 @@
return new OtfaReportExecutorDelegateTemporal(parent, reportInfo, config, reportGlobalService);
case LONGITUDINAL:
return new OtfaReportExecutorDelegateLongitudinal(parent, reportInfo, config, reportGlobalService);
+ case MULTI_VAR:
+ return new OtfaReportExecutorDelegateMultiVar(parent, reportInfo, config, reportGlobalService);
+ case RPTG:
+ return new OtfaReportExecutorDelegateRPTG(parent, reportInfo, config, reportGlobalService);
}
return null;
}
-
+
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegate.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegate.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegate.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -91,6 +91,7 @@
}
public void exportTo(File targetFile, CtuluLog log) {
+ log.addInfo("otfa.report.exportTo", reportInfo.getInfo().getNom(), targetFile.getAbsolutePath());
CSVPrinter writer = null;
try {
writer = new CSVPrinter(new FileOutputStream(targetFile));
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateLongitudinal.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateLongitudinal.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateLongitudinal.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -63,7 +63,7 @@
@Override
protected void exportTo(CSVPrinter printer, CtuluLog log) throws IOException {
- ReportLongitudinalConfig config = (ReportLongitudinalConfig) super.config;
+ ReportLongitudinalConfig content = (ReportLongitudinalConfig) super.config;
final CrueConfigMetier ccm = reportGlobalService.getResultService().getCcm();
ReportLongitudinalLimitHelper limitHelper = new ReportLongitudinalLimitHelper(ccm);
final Map<String, String> displayNameById = limitHelper.getDisplayNameById();
@@ -71,8 +71,8 @@
StringBuilder builder = new StringBuilder();
builder.append(quote).append(BusinessMessages.getString("otfa.report.longitudinalFirstColName")).append(quote).append(super.delimiter);
builder.append(quote).append(propertyXp.getDisplayNom()).append(quote);
- final List<ResultatTimeKey> profilTimes = config.getTimes();
- final List<ReportRunVariableKey> variables = config.getProfilVariables();
+ final List<ResultatTimeKey> profilTimes = content.getTimes();
+ final List<ReportRunVariableKey> variables = content.getProfilVariables();
for (ReportRunVariableKey variable : variables) {
if (ReportVariableTypeEnum.LIMIT_PROFIL.equals(variable.getVariable().getVariableType())) {
String displayName = displayNameById.get(variable.getVariableName());
@@ -99,7 +99,7 @@
log.addWarn(BusinessMessages.getString("Report.RunNonCurrentIgnored"));
}
printer.writelnComment(builder.toString());
- final List<ReportLongitudinalBrancheConfig> branchesConfig = config.getBranchesConfig();
+ final List<ReportLongitudinalBrancheConfig> branchesConfig = content.getBranchesConfig();
ReportLongitudinalPositionBuilder positionBuilder = new ReportLongitudinalPositionBuilder(reportGlobalService.getResultService(), ccm);
final ReportRunKey runCourant = new ReportRunKey();
Set<ReportRunKey> keys = Collections.singleton(runCourant);
Copied: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateMultiVar.java (from rev 8689, trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateTemporal.java)
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateMultiVar.java (rev 0)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateMultiVar.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -0,0 +1,80 @@
+/*
+ GPL 2
+ */
+package org.fudaa.dodico.crue.projet.otfa;
+
+import com.Ostermiller.util.CSVPrinter;
+import java.io.IOException;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+import org.fudaa.ctulu.CtuluLog;
+import org.fudaa.dodico.crue.common.BusinessMessages;
+import org.fudaa.dodico.crue.metier.emh.ResultatTimeKey;
+import org.fudaa.dodico.crue.projet.report.ReportMultiVarConfig;
+import org.fudaa.dodico.crue.projet.report.ReportViewLineInfoAndType;
+import org.fudaa.dodico.crue.projet.report.data.ReportRunKey;
+import org.fudaa.dodico.crue.projet.report.data.ReportRunVariableEmhKey;
+import org.fudaa.dodico.crue.projet.report.data.ReportRunVariableHelper;
+import org.fudaa.dodico.crue.projet.report.data.ReportVariableKey;
+import org.fudaa.dodico.crue.projet.report.persist.ReportConfigContrat;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class OtfaReportExecutorDelegateMultiVar extends OtfaReportExecutorDelegate {
+
+ public OtfaReportExecutorDelegateMultiVar(OtfaReportExecutor parent, ReportViewLineInfoAndType reportInfo, ReportConfigContrat config,
+ OtfaReportGlobalService reportGlobalService) {
+ super(parent, reportInfo, config, reportGlobalService);
+ }
+
+ @Override
+ protected void exportTo(CSVPrinter printer, CtuluLog log) throws IOException {
+ ReportMultiVarConfig content = (ReportMultiVarConfig) super.config;
+ Map<String, List<ReportRunKey>> keyByVar = ReportRunVariableHelper.getByEmh(content.getReportRunEmhs());
+ List<ReportRunVariableEmhKey> keysToUse = new ArrayList<ReportRunVariableEmhKey>();
+ boolean containsNonCurrent = false;
+ ReportRunKey current = new ReportRunKey();
+ final ReportVariableKey horizontalVariableKey = super.reportGlobalService.getResultService().createVariableKey(content.getHorizontalVar());
+ for (String variableName : content.getVariables()) {
+ final ReportVariableKey verticalVariableKey = super.reportGlobalService.getResultService().createVariableKey(variableName);
+ for (String emhName : content.getEmhs()) {
+ List<ReportRunKey> keys = keyByVar.get(emhName);
+ if (containsAlternatif(keys)) {
+ containsNonCurrent = true;
+ }
+ if (containsCurrent(keys)) {
+ keysToUse.add(new ReportRunVariableEmhKey(current, horizontalVariableKey, emhName));
+ keysToUse.add(new ReportRunVariableEmhKey(current, verticalVariableKey, emhName));
+
+ }
+ }
+ }
+ if (containsNonCurrent) {
+ log.addWarn(BusinessMessages.getString("Report.RunNonCurrentIgnored"));
+ }
+ StringBuilder builder = new StringBuilder();
+ boolean addDelim = false;
+ for (ReportRunVariableEmhKey key : keysToUse) {
+ if (addDelim) {
+ builder.append(super.delimiter);
+ }
+ addDelim = true;
+ builder.append(quote).append(key.getRunVariableKey().getVariable().getVariableDisplayName()).append(" - ").append(key.getEmhName()).
+ append(quote);
+
+ }
+ printer.printlnComment(builder.toString());
+ final List<ResultatTimeKey> times = reportGlobalService.getRangeSelectedTimeKeys();
+ for (ResultatTimeKey time : times) {
+ for (ReportRunVariableEmhKey key : keysToUse) {
+ super.printVariable(printer, reportGlobalService.getResultService().getValue(time, key.getRunVariableKey(), key.getEmhName()), key.
+ getVariableName());
+ }
+ printer.println();
+ }
+ }
+
+}
Copied: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateRPTG.java (from rev 8689, trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateTemporal.java)
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateRPTG.java (rev 0)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutorDelegateRPTG.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -0,0 +1,111 @@
+/*
+ GPL 2
+ */
+package org.fudaa.dodico.crue.projet.otfa;
+
+import com.Ostermiller.util.CSVPrinter;
+import java.io.IOException;
+import java.util.List;
+import org.apache.commons.lang.StringUtils;
+import org.fudaa.ctulu.CtuluLog;
+import org.fudaa.dodico.crue.common.BusinessMessages;
+import org.fudaa.dodico.crue.config.ccm.ConfigLoi;
+import org.fudaa.dodico.crue.config.ccm.CrueConfigMetier;
+import org.fudaa.dodico.crue.metier.emh.EMH;
+import org.fudaa.dodico.crue.metier.emh.LoiFF;
+import org.fudaa.dodico.crue.metier.emh.ResPrtGeo;
+import org.fudaa.dodico.crue.metier.helper.LoiHelper;
+import org.fudaa.dodico.crue.projet.report.ReportRPTGConfig;
+import org.fudaa.dodico.crue.projet.report.ReportViewLineInfoAndType;
+import org.fudaa.dodico.crue.projet.report.persist.ReportConfigContrat;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class OtfaReportExecutorDelegateRPTG extends OtfaReportExecutorDelegate {
+
+ public static LoiFF findLoi(List<LoiFF> lois, String varX, String varY, CrueConfigMetier ccm) {
+ for (LoiFF loiFF : lois) {
+ ConfigLoi config = ccm.getConfLoi().get(loiFF.getType());
+ if (config.getVarAbscisse().getNom().equals(varX) && config.getVarOrdonnee().getNom().equals(varY)) {
+ return loiFF;
+ } else if (config.getVarAbscisse().getNom().equals(varY) && config.getVarOrdonnee().getNom().equals(varX)) {
+ return LoiHelper.switchAbscOrdonnee(loiFF);
+ }
+ }
+ return null;
+ }
+
+ public OtfaReportExecutorDelegateRPTG(OtfaReportExecutor parent, ReportViewLineInfoAndType reportInfo, ReportConfigContrat config,
+ OtfaReportGlobalService reportGlobalService) {
+ super(parent, reportInfo, config, reportGlobalService);
+ }
+
+ @Override
+ protected void exportTo(CSVPrinter printer, CtuluLog log) throws IOException {
+ ReportRPTGConfig content = (ReportRPTGConfig) super.config;
+ EMH emh = reportGlobalService.getResultService().getRunCourant().getEMH(content.getEmh());
+ if (emh == null) {
+ log.addError("otfa.report.emhNotFound", content.getEmh());
+ return;
+ }
+ ResPrtGeo rptg = emh.getRPTG();
+ if (rptg == null) {
+ log.addError("otfa.report.emhNoRPTG", content.getEmh());
+ return;
+ }
+ printer.writelnComment(BusinessMessages.getString("otfa.report.exportRPTG.on") + ": " + emh.getNom());
+ List<LoiFF> lois = rptg.getLois();
+ final String var1 = content.getVar1();
+ final String var2 = content.getVar2();
+ final String varH = content.getVarHorizontal();
+ LoiFF lois1 = null;
+ LoiFF lois2 = null;
+ if (var1 != null) {
+ lois1 = findLoi(lois, varH, var1, reportGlobalService.getResultService().getCcm());
+ }
+ if (var2 != null) {
+ lois2 = findLoi(lois, varH, var2, reportGlobalService.getResultService().getCcm());
+ }
+ int max1 = 0;
+ int max2 = 0;
+ StringBuilder builder = new StringBuilder();
+ if (lois1 != null) {
+ max1 = lois1.getNombrePoint();
+ builder.append(super.quote).append(reportGlobalService.getResultService().getVariableName(varH)).append(super.quote);
+ builder.append(super.delimiter).append(super.quote).append(reportGlobalService.getResultService().getVariableName(var1)).append(super.quote);
+ }
+ if (lois2 != null) {
+ max2 = lois2.getNombrePoint();
+ if (builder.length() > 0) {
+ builder.append(super.delimiter);
+ }
+ builder.append(super.quote).append(reportGlobalService.getResultService().getVariableName(varH)).append(super.quote);
+ builder.append(super.delimiter).append(super.quote).append(reportGlobalService.getResultService().getVariableName(var2)).append(super.quote);
+ }
+ int maxSize = Math.max(max1, max2);
+ printer.printlnComment(builder.toString());
+ for (int i = 0; i < maxSize; i++) {
+ if (lois1 != null) {
+ if (i >= max1) {
+ printer.print(StringUtils.EMPTY);
+ printer.print(StringUtils.EMPTY);
+ }
+ printVariable(printer, lois1.getAbscisse(i), varH);
+ printVariable(printer, lois1.getOrdonnee(i), var1);
+ }
+ if (lois2 != null) {
+ if (i >= max2) {
+ printer.print(StringUtils.EMPTY);
+ printer.print(StringUtils.EMPTY);
+ }
+ printVariable(printer, lois2.getAbscisse(i), varH);
+ printVariable(printer, lois2.getOrdonnee(i), var2);
+ }
+ printer.println();
+ }
+
+ }
+
+}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportGlobalService.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportGlobalService.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportGlobalService.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -9,7 +9,6 @@
import java.util.Map;
import org.fudaa.dodico.crue.metier.emh.ResultatTimeKey;
import org.fudaa.dodico.crue.projet.report.ReportGlobalServiceContrat;
-import org.fudaa.dodico.crue.projet.report.ReportResultProviderServiceContrat;
import org.fudaa.dodico.crue.projet.report.formule.function.AggregationCacheKey;
import org.netbeans.api.progress.ProgressRunnable;
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportResultService.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportResultService.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportResultService.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -136,6 +136,14 @@
return getRunCourant().getEMH(nom);
}
+ public String getVariableName(String varName) {
+ if (formuleService.isFormule(varName)) {
+ return varName;
+ }
+ ItemVariable property = getCcm().getProperty(varName);
+ return property == null ? varName : property.getDisplayNom();
+ }
+
@Override
public PropertyNature getPropertyNature(String varName) {
if (formuleService.isFormule(varName)) {
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -4,6 +4,7 @@
import java.awt.Color;
import org.fudaa.fudaa.crue.common.editor.CustomEditorAbstract;
import java.io.File;
+import java.util.Arrays;
import java.util.List;
import javax.swing.JComponent;
import javax.swing.JLabel;
@@ -60,7 +61,12 @@
ReportIndexReaderHelper helper = new ReportIndexReaderHelper(projet);
String value = (String) editor.getValue();
TreeNode selectedValue = null;
+ List<ReportContentType> toAvoid = Arrays.asList(ReportContentType.PLANIMETRY, ReportContentType.TRANSVERSAL);
for (ReportContentType reportContentType : values) {
+ //on ignore les rapports non gérés.
+ if (toAvoid.contains(reportContentType)) {
+ continue;
+ }
final CrueIOResu<List<ReportViewLineInfo>> linesIO = helper.readType(reportContentType);
if (linesIO != null && CtuluLibArray.isNotEmpty(linesIO.getMetier())) {
DefaultMutableTreeNode lineParent = new DefaultMutableTreeNode(reportContentType.getFolderName());
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/config/AbstractReportGrapheBuilder.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/config/AbstractReportGrapheBuilder.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/config/AbstractReportGrapheBuilder.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -285,10 +285,13 @@
axeVConfig.apply(axe);
}
}
- if (horizontalPersist != null) {
+ boolean performZoom = false;
+ if (horizontalPersist != null && StringUtils.equals(horizontalPersist.getTitre(), uiController.getAxeX().getTitre())) {
horizontalPersist.apply(uiController.getAxeX());
+ } else {
+ performZoom = true;
}
- if (fromTemplate || content.isNoZoomSet()) {
+ if (performZoom || fromTemplate || content.isNoZoomSet()) {
uiController.getGraphe().restore();
}
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/multivar/ReportMultiVarGrapheBuilder.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/multivar/ReportMultiVarGrapheBuilder.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/multivar/ReportMultiVarGrapheBuilder.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -40,12 +40,11 @@
* @author Frederic Deniger
*/
public class ReportMultiVarGrapheBuilder extends AbstractReportGrapheBuilder<CourbesUiController, ReportMultiVarConfig> {
-
+
public ReportMultiVarGrapheBuilder(CourbesUiController uiController, ViewCourbeManager loiLabelsManager) {
super(uiController, loiLabelsManager);
}
-
-
+
@Override
public List<EGCourbeSimple> getInternCourbes(ReportMultiVarConfig content, ProgressHandle progress) {
if (!reportService.isRunLoaded()) {
@@ -60,6 +59,10 @@
return Collections.emptyList();
}
PropertyNature propertyHorizontal = reportResultProviderService.getPropertyNature(content.getHorizontalVar());
+ //on change de variables horizontales: on oublie les pref.
+ if (propertyHorizontal != axeX.getUserObject()) {
+ content.saveAxeH(null);
+ }
axeX.setTitre(propertyHorizontal.getDisplayName());
axeX.setUniteVisible(true);
axeX.setUnite(propertyHorizontal.getUnite());
@@ -68,20 +71,12 @@
axeX.setSpecificFormat(new CtuluNumberFormatDefault(propertyHorizontal.getFormatter(DecimalFormatEpsilonEnum.PRESENTATION)));
axeX.setSpecificDetailFormat(new CtuluNumberFormatDefault(propertyHorizontal.getFormatter(DecimalFormatEpsilonEnum.COMPARISON)));
axeX.setUserObject(propertyHorizontal);
-// EGCourbe selectedComponent = uiController.getEGGrapheSimpleModel().getSelectedComponent();
-// Object selectedKey = null;
-// if (selectedComponent != null && selectedComponent.getModel() != null) {
-// selectedKey = ((CourbeModelWithKey) selectedComponent.getModel()).getKey();
-// if (ReportVerticalTimeKey.isTimeKey(selectedKey)) {
-// selectedKey = null;
-// }
-// }
Map<String, List<ReportRunKey>> keyByVar = ReportRunVariableHelper.getByEmh(content.getReportRunEmhs());
List<ResultatTimeKey> times = reportService.getRangeSelectedTimeKeys();
List<EGCourbeSimple> courbes = new ArrayList<EGCourbeSimple>();
Map<String, EGAxeVertical> saved = new HashMap<String, EGAxeVertical>();
for (String variableName : content.getVariables()) {
-
+
PropertyNature property = reportResultProviderService.getPropertyNature(variableName);
ReportVariableKey variableKey = reportResultProviderService.createVariableKey(variableName);
EGAxeVertical axeVertical = getOrCreateAxeVerticalConfigured(property, content, saved);
@@ -99,9 +94,6 @@
final EGCourbePersist persist = content.getCourbeconfigs().get(key);
applyPersistConfig(persist, courbe);
courbes.add(courbe);
-// if (selectedKey == null) {
-// selectedKey = key;
-// }
}
}
}
@@ -109,16 +101,16 @@
}
return courbes;
}
-
+
@Override
public void updateResultCurvesAfterTimeChanged(ReportMultiVarConfig content) {
}
-
+
@Override
public List<EGCourbeSimple> getInternCourbesAfterTimeChanged(ReportMultiVarConfig content, ProgressHandle progress) {
return Collections.emptyList();
}
-
+
private LoiConstanteCourbeModel createCourbeModel(ReportMultiVarConfig config, List<ResultatTimeKey> times, ReportRunVariableEmhKey key) {
ReportRunVariableKey hKey = new ReportRunVariableKey(key.getRunVariableKey().getRunKey(), reportResultProviderService.createVariableKey(
config.getHorizontalVar()));
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/rptg/ReportRPTGGrapheBuilder.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/rptg/ReportRPTGGrapheBuilder.java 2014-04-02 19:38:44 UTC (rev 8690)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/rptg/ReportRPTGGrapheBuilder.java 2014-04-02 22:21:23 UTC (rev 8691)
@@ -18,6 +18,7 @@
import org.fudaa.dodico.crue.metier.emh.LoiFF;
import org.fudaa.dodico.crue.metier.emh.ResPrtGeo;
import org.fudaa.dodico.crue.metier.helper.LoiHelper;
+import org.fudaa.dodico.crue.projet.otfa.OtfaReportExecutorDelegateRPTG;
import org.fudaa.ebli.courbe.EGAxeVertical;
import org.fudaa.ebli.courbe.EGCourbePersist;
import org.fudaa.ebli.courbe.EGCourbeSimple;
@@ -92,19 +93,6 @@
return courbe;
}
- private LoiFF findLoi(List<LoiFF> lois, String varX, String varY, CrueConfigMetier ccm) {
- for (LoiFF loiFF : lois) {
- ConfigLoi config = ccm.getConfLoi().get(loiFF.getType());
- if (config.getVarAbscisse().getNom().equals(varX) && config.getVarOrdonnee().getNom().equals(varY)) {
- return loiFF;
- } else if (config.getVarAbscisse().getNom().equals(varY) && config.getVarOrdonnee().getNom().equals(varX)) {
- return LoiHelper.switchAbscOrdonnee(loiFF);
- }
- }
- return null;
-
- }
-
@Override
public List<EGCourbeSimple> getInternCourbes(ReportRPTGConfig content, ProgressHandle progress) {
final String varHorizontal = content.getVarHorizontal();
@@ -147,7 +135,7 @@
protected EGCourbeSimple createCourbe(List<LoiFF> lois, ReportRPTGConfig config, final String emhName, final String var1, CrueConfigMetier ccm,
boolean main, Map<String, EGAxeVertical> axesY) {
- LoiFF loi1 = findLoi(lois, config.getVarHorizontal(), var1, ccm);
+ LoiFF loi1 = OtfaReportExecutorDelegateRPTG.findLoi(lois, config.getVarHorizontal(), var1, ccm);
if (loi1 != null) {
PropertyNature property1 = reportResultProviderService.getPropertyNature(var1);
ItemVariable varX = reportResultProviderService.getCcmVariable(config.getVarHorizontal());
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-04-02 22:31:00
|
Revision: 8692
http://sourceforge.net/p/fudaa/svn/8692
Author: deniger
Date: 2014-04-02 22:30:52 +0000 (Wed, 02 Apr 2014)
Log Message:
-----------
CRUE-640
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/Bundle.properties
trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties
trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/calcul/Bundle.properties
trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties
trunk/soft/fudaa-crue/ui-post/src/main/resources/org/fudaa/fudaa/crue/post/Bundle.properties
trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/Bundle.properties
trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties
trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/rptg/Bundle.properties
trunk/soft/fudaa-crue/ui-study/src/main/resources/org/fudaa/fudaa/crue/study/Bundle.properties
Modified: trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
===================================================================
--- trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -1276,7 +1276,7 @@
ProfilEnLong.Type=Profils en long
Temporel.Type=Temporel
MultiVar.Type=Multi-Variables
-RPTG.Type=Pr\u00e9-traitement g\u00e9om\u00e9trique
+RPTG.Type=Pr\u00e9traitement g\u00e9om\u00e9trique
Planimetry.Type=Planim\u00e9trie
otfa.report.typeUnknown=Le rapport {0} est de type inconnu
otfa.report.notFound=Le rapport {0} n''a pas \u00e9t\u00e9 trouv\u00e9
Modified: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2014-04-02 22:30:52 UTC (rev 8692)
@@ -52,7 +52,7 @@
}
@Override
- @Messages("FudaaCrueClosing.Label=Fudaa-Crue est cours de fermeture...")
+ @Messages("FudaaCrueClosing.Label=Fudaa-Crue est en cours de fermeture...")
public boolean closing() {
SelectedPerspectiveService selectedPerspectiveService = Lookup.getDefault().lookup(SelectedPerspectiveService.class);
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -11,8 +11,8 @@
HINT_ModellingVisualTopComponent= Vue planim\u00e9trique
CTL_ModellingNetworkTopComponent=R\u00e9seau
HINT_ModellingNetworkTopComponent=R\u00e9seau
-CTL_ModellingEMHTopComponent=EMHs
-HINT_ModellingEMHTopComponent=EMH
+CTL_ModellingEMHTopComponent=Explorateur EMHs
+HINT_ModellingEMHTopComponent=Explorateur EMHs
CTL_ModellingComputeDataTopComponent=Liste des calculs
HINT_ModellingComputeDataTopComponent=Liste des calculs
emhTopComponent.NoScenarioLoadedInformations=<Vide>
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/action/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -42,10 +42,10 @@
ModellingOpenListeCLimMsNodeAction.Name=Liste des CLimMs du sc\u00e9nario
ModellingOpenListeCLimMsNodeAction.NewFrame.Name=Liste des CLimMs du sc\u00e9nario (nouvelle fen\u00eatre)
-ModellingModeleOPTGNodeAction.Name=Ordre de pr\u00e9-traitement g\u00e9om\u00e9trique
-ModellingModeleOPTGNodeAction.NewFrame.Name=Ordre de pr\u00e9-traitement g\u00e9om\u00e9trique (nouvelle fen\u00eatre)
-ModellingModeleOPTRNodeAction.Name=Ordre de pr\u00e9-traitement r\u00e9seau
-ModellingModeleOPTRNodeAction.NewFrame.Name=Ordre de pr\u00e9-traitement r\u00e9seau (nouvelle fen\u00eatre)
+ModellingModeleOPTGNodeAction.Name=Ordre de pr\u00e9traitement g\u00e9om\u00e9trique
+ModellingModeleOPTGNodeAction.NewFrame.Name=Ordre de pr\u00e9traitement g\u00e9om\u00e9trique (nouvelle fen\u00eatre)
+ModellingModeleOPTRNodeAction.Name=Ordre de pr\u00e9traitement r\u00e9seau
+ModellingModeleOPTRNodeAction.NewFrame.Name=Ordre de pr\u00e9traitement r\u00e9seau (nouvelle fen\u00eatre)
ModellingModelePNUMNodeAction.Name=Param\u00e8tres num\u00e9riques
ModellingModelePNUMNodeAction.NewFrame.Name=Param\u00e8tres num\u00e9riques (nouvelle fen\u00eatre)
ModellingModeleOPTINodeAction.Name=Ordre de pr\u00e9-traitement des conditions initiales
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/calcul/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/calcul/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/resources/org/fudaa/fudaa/crue/modelling/calcul/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -12,12 +12,12 @@
PNUM.ParamNumCalcVraiPerm.DisplayName=Calcul permanent
-CTL_ModellingModeleOPTGTopComponent=Ordre de pr\u00e9-traitement g\u00e9om\u00e9trique
-HINT_ModellingModeleOPTGTopComponent=Ordre de pr\u00e9-traitement g\u00e9om\u00e9trique
-CTL_ModellingModeleOPTRTopComponent=Ordre de pr\u00e9-traitement r\u00e9seau
-HINT_ModellingModeleOPTRTopComponent=Ordre de pr\u00e9-traitement r\u00e9seau
-CTL_ModellingModeleOPTITopComponent=Ordre de pr\u00e9-traitement des conditions initiales
-HINT_ModellingModeleOPTITopComponent=Ordre de pr\u00e9-traitement des conditions initiales
+CTL_ModellingModeleOPTGTopComponent=Ordre de pr\u00e9traitement g\u00e9om\u00e9trique
+HINT_ModellingModeleOPTGTopComponent=Ordre de pr\u00e9traitement g\u00e9om\u00e9trique
+CTL_ModellingModeleOPTRTopComponent=Ordre de pr\u00e9traitement r\u00e9seau
+HINT_ModellingModeleOPTRTopComponent=Ordre de pr\u00e9traitement r\u00e9seau
+CTL_ModellingModeleOPTITopComponent=Ordre de pr\u00e9traitement des conditions initiales
+HINT_ModellingModeleOPTITopComponent=Ordre de pr\u00e9traitement des conditions initiales
CTL_ModellingScenarioORESTopComponent=Demandes de r\u00e9sultats
HINT_ModellingScenarioORESTopComponent=Demandes de r\u00e9sultats
CTL_ModellingModelePNUMTopComponent=Param\u00e8tres num\u00e9riques
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -7,8 +7,8 @@
CTL_SomeAction=Lancer tout
OtfaBilanExecution.DialogTitle=Bilan de l'ex\u00e9cution OTFA
CTL_OtfaCampagneTopComponentAction=Test
-CTL_OTFAPropertiesAction=Propri\u00e9t\u00e9s OTFA
-HINT_OTFAPropertiesAction=Propri\u00e9t\u00e9s OTFA
+CTL_OTFAPropertiesAction=Propri\u00e9t\u00e9s
+HINT_OTFAPropertiesAction=Propri\u00e9t\u00e9s
ExecuterCampagneAction.Title=Executer la campagne
OtfaCampagneTopComponent.jLabel7.text=Date cr\u00e9ation :
OtfaCampagneTopComponent.dateCreation.text=
Modified: trunk/soft/fudaa-crue/ui-post/src/main/resources/org/fudaa/fudaa/crue/post/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-post/src/main/resources/org/fudaa/fudaa/crue/post/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-post/src/main/resources/org/fudaa/fudaa/crue/post/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -14,8 +14,8 @@
CTL_PostPropertiesTopComponent=Propri\u00e9t\u00e9s
HINT_PostPropertiesTopComponent=Propri\u00e9t\u00e9s
PostReportsTopComponent.FirstColumn=Compte-Rendus
-CTL_PostEmhExplorerTopComponent=Exploreur EMHs
-HINT_PostEmhExplorerTopComponent=Exploreur EMHs
+CTL_PostEmhExplorerTopComponent=Explorateur EMHs
+HINT_PostEmhExplorerTopComponent=Explorateur EMHs
CTL_PostCtuluLogTopComponent=Compte-rendu op\u00e9ration
HINT_PostCtuluLogTopComponent=Compte-rendu de la derni\u00e8re op\u00e9ration
postMainTopComponent.NoRunLoadedInformations=<Aucun run charg\u00e9>
Modified: trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -12,14 +12,14 @@
HINT_ReportSelectRunTopComponent=S\u00e9lection des fichiers r\u00e9sultats
CTL_ReportTimeTopComponent=Gestionnaire temporel
HINT_ReportTimeTopComponent=Gestionnaire temporel
-CTL_ReportVariableTopComponent=Variables
-HINT_ReportVariableTopComponent=Variables
+CTL_ReportVariableTopComponent=VariablesFC
+HINT_ReportVariableTopComponent=VariablesFC
CTL_ReportViewManagerTopComponent=Gestionnaire de vues r\u00e9sultats
HINT_ReportViewManagerTopComponent=Gestionnaire de vues r\u00e9sultats
CTL_ReportVisualTopComponent=Vue planim\u00e9trique
HINT_ReportVisualTopComponent=Vue planim\u00e9trique
-CTL_ReportLayersTreeComponent=Calques
-HINT_ReportLayersTreeComponent=Calques
+CTL_ReportLayersTreeComponent=Gestionnaire de calques
+HINT_ReportLayersTreeComponent=Gestionnaire de calques
CTL_ReportDFRTTopComponent=Frottements
HINT_ReportDFRTTopComponent=Frottements
CTL_ReportDLHYTopComponent=Lois hydrauliques
Modified: trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/actions/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -5,7 +5,7 @@
ReportSetAsAlternatifNodeAction.DisplayName=Utiliser comme run alternatif
ReportUnsetAsAlternatifNodeAction.DisplayName=Ne plus utiliser comme run alternatif
OpenProfilTransversal.ActionName=Profil en travers
-OpenRPTG.ActionName=Pr\u00e9-traitement g\u00e9om\u00e9trique
+OpenRPTG.ActionName=Pr\u00e9traitement g\u00e9om\u00e9trique
OpenProfilLongitudinal.ActionName=Profil longitudinal
OpenTemporal.ActionName=Courbe temporelle
OpenMulitVar.ActionName=Multi-Variables
Modified: trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/rptg/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/rptg/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/rptg/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -1,11 +1,11 @@
-CTL_ReportRPTGTopComponent=Pr\u00e9-traitement g\u00e9om\u00e9trique
-HINT_ReportRPTGTopComponent=Pr\u00e9-traitement g\u00e9om\u00e9trique
+CTL_ReportRPTGTopComponent=Pr\u00e9traitement g\u00e9om\u00e9trique
+HINT_ReportRPTGTopComponent=Pr\u00e9traitement g\u00e9om\u00e9trique
ChooseEMH.ButtonName=Changer EMH
ChoosePrevious.ButtonName=Pr\u00e9c\u00e9dent
ChooseNext.ButtonName=Suivante
ChooseVariable.ButtonName=Variables
ChooseEMHName.Label=EMH \u00e0 utiliser:
-ChooseEMHName.DialogTitle=Pr\u00e9-traitement g\u00e9om\u00e9trique
+ChooseEMHName.DialogTitle=Pr\u00e9traitement g\u00e9om\u00e9trique
ChooseVariable.LabelHorizontal=Variable horizontal:
ChooseVariable.LabelFirst=Variable 1:
ChooseVariable.LabelSecond=Variable 2:
Modified: trunk/soft/fudaa-crue/ui-study/src/main/resources/org/fudaa/fudaa/crue/study/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-study/src/main/resources/org/fudaa/fudaa/crue/study/Bundle.properties 2014-04-02 22:21:23 UTC (rev 8691)
+++ trunk/soft/fudaa-crue/ui-study/src/main/resources/org/fudaa/fudaa/crue/study/Bundle.properties 2014-04-02 22:30:52 UTC (rev 8692)
@@ -13,8 +13,8 @@
CTL_ScenariosTopComponent=Sc\u00e9narios
CTL_FileListTopComponent=Fichiers
CTL_SousModeleListTopComponent=Sous-Mod\u00e8les
-CTL_StudyPropertiesAction=Propri\u00e9t\u00e9s \u00e9tudes
-HINT_StudyPropertiesAction=Propri\u00e9t\u00e9s \u00e9tudes
+CTL_StudyPropertiesAction=Propri\u00e9t\u00e9s
+HINT_StudyPropertiesAction=Propri\u00e9t\u00e9s
HINT_ModeleListTopComponent=Liste des mod\u00e8les disponibles
HINT_FileListTopComponent=Liste des fichiers
HINT_ScenariosTopComponent=Liste des sc\u00e9narios
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-05-28 21:05:03
|
Revision: 8750
http://sourceforge.net/p/fudaa/svn/8750
Author: deniger
Date: 2014-05-28 21:04:56 +0000 (Wed, 28 May 2014)
Log Message:
-----------
correction bogues
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
trunk/soft/fudaa-crue/pom.xml
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingVisualTopComponent.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/service/LaunchOtfaCampagneRunner.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaCampagneLine.java 2014-05-28 21:04:56 UTC (rev 8750)
@@ -10,7 +10,7 @@
* @author deniger
*/
public class OtfaCampagneLine {
-
+
private OtfaCampagneItem reference;
private OtfaCampagneItem cible;
private String commentaire;
@@ -20,18 +20,18 @@
* correspond à l'indice de la ligne dans la liste de {@link OtfaCampagne}
*/
private int indice;
-
+
public OtfaCampagneLine() {
}
-
+
public boolean isLancerComparaison() {
return lancerComparaison;
}
-
+
public void setLancerComparaison(boolean lancerComparaison) {
this.lancerComparaison = lancerComparaison;
}
-
+
public OtfaCampagneLine(OtfaCampagneLine toCopy) {
if (toCopy != null) {
if (toCopy.reference != null) {
@@ -70,10 +70,11 @@
}
return (StringUtils.isBlank(cible.getScenarioNom()) && StringUtils.isBlank(cible.getEtuPath()));
}
-
+
public OtfaCampagneItem getFinalReference() {
return reference;
}
+
/**
* @return if the cible is a conversion return the final etu file and scenario
@@ -86,11 +87,11 @@
newCible.setCoeurName(cible.getCoeurName());
ConversionNameConverter converter = new ConversionNameConverter(cible.isCrue9() ? CrueVersionType.CRUE9 : CrueVersionType.CRUE10);
newCible.setScenarioNom(converter.convert(reference.getScenarioNom()));
-
+
return newCible;
}
return cible;
-
+
}
/**
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java 2014-05-28 21:04:56 UTC (rev 8750)
@@ -287,7 +287,7 @@
private boolean rapportIsBlankOrExists(OtfaCampagne campagne, OtfaCampagneItem item, CtuluLog log) {
if (StringUtils.isNotBlank(item.getRapport())) {
File etuFile = item.getEtuFile(campagne.getOtfaDir());
- if (etuFile.exists()) {
+ if (etuFile != null && etuFile.exists()) {
final ReportContentType contentType = ReportViewLineInfoAndType.getContentType(item.getRapport());
if (contentType == null) {
return false;
@@ -317,7 +317,7 @@
if (!rapportIsBlankOrExists(campagne, line.getReference(), log)) {
log.addSevereError("otfa.validator.reportNotFoundReference", line.getReference().getRapport());
}
- if (!rapportIsBlankOrExists(campagne, line.getCible(), log)) {
+ if (!rapportIsBlankOrExists(campagne, line.getFinalCible(), log)) {
log.addSevereError("otfa.validator.reportNotFoundCible", line.getReference().getRapport());
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-05-28 21:04:56 UTC (rev 8750)
@@ -82,7 +82,7 @@
OutOfMemoryError oomError = null;
FileLocker locker = new FileLocker();
Set<File> allEtu = new HashSet<File>();
- ProgressionUpdater updater = new ProgressionUpdater(progress);
+ ProgressionUpdater updater = new ProgressionUpdater(progress, false);
try {
if (!lineSaver.isStarted()) {
lineSaver.start(false);
@@ -108,8 +108,7 @@
}
List<OtfaCampagneLine> lines = in.getLines();
- final int size = lines.size();
- updater.setValue(size, size);
+
updater.majProgessionStateOnly(BusinessMessages.getString("otfa.avancement.lock"));
for (OtfaCampagneLine line : lines) {
@@ -120,7 +119,6 @@
if (stoppedAskedByUser()) {
return result;
}
- updater.majAvancement();
}
try {
for (File file : allEtu) {
@@ -169,13 +167,15 @@
deleteRuns(in, in.getReferenceOptions().isEffacerRunAvant(), in.getCibleOptions().isEffacerRunAvant(), logsBefore);
}
int size = in.getLines().size();
+ updater.setValue(size, size);
for (OtfaCampagneLine line : in.getLines()) {
- updater.majProgessionStateOnly(BusinessMessages.getString("otfa.avancement.line", Integer.toString(line.getIndice() + 1), size));
+ updater.majProgessionStateOnly(BusinessMessages.getString("otfa.avancement.line", Integer.toString(line.getIndice()), size));
lineSaver.addResult(this.launch(in, line));
final boolean isStopped = stoppedAskedByUser();
if (isStopped) {
return;
}
+ updater.majAvancement();
}
if (in.getReferenceOptions().isEffacerRunApres() || in.getCibleOptions().isEffacerRunApres()) {
updater.majProgessionStateOnly(BusinessMessages.getString("otfa.avancement.deleteRunApres"));
Modified: trunk/soft/fudaa-crue/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/pom.xml 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/pom.xml 2014-05-28 21:04:56 UTC (rev 8750)
@@ -4,7 +4,7 @@
<parent>
<groupId>org.fudaa.pom</groupId>
<artifactId>soft-pom</artifactId>
- <version>1.4</version>
+ <version>1.5</version>
</parent>
<groupId>org.fudaa.soft.fudaa-crue</groupId>
<artifactId>fudaa-crue</artifactId>
@@ -20,7 +20,7 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<javaCompiler>1.7</javaCompiler>
<targetJdk>1.7</targetJdk>
- <fudaa-sig.version>1.4-SNAPSHOT</fudaa-sig.version>
+ <fudaa-sig.version>1.5-SNAPSHOT</fudaa-sig.version>
<netbeans.run.params.ide/>
<netbeans.run.params>${netbeans.run.params.ide}</netbeans.run.params>
<!--<netbeans.version>RELEASE731</netbeans.version>-->
Modified: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2014-05-28 21:04:56 UTC (rev 8750)
@@ -21,6 +21,7 @@
import org.fudaa.fudaa.crue.common.services.PerspectiveService;
import org.fudaa.fudaa.crue.common.services.SelectedPerspectiveService;
import org.openide.modules.ModuleInstall;
+import org.openide.nodes.NodeOp;
import org.openide.util.Lookup;
import org.openide.util.Lookup.Item;
import org.openide.util.NbBundle.Messages;
@@ -96,6 +97,7 @@
//La version 7.4 corrige le probleme mais apporte des régressions sur la persistances des informations sur les OutlineView. <br>
PropertyEditorManager.registerEditor(File.class, FileEditor.class);
PropertyEditorManager.registerEditor(Color.class, CustomColorChooser.class);
+ PropertyEditorManager.setEditorSearchPath(new String[]{"org.netbeans.beaninfo.editors"});
Set<TopComponent> opened = WindowManager.getDefault().getRegistry().getOpened();
for (TopComponent topComponent : opened) {
topComponent.close();
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingVisualTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingVisualTopComponent.java 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingVisualTopComponent.java 2014-05-28 21:04:56 UTC (rev 8750)
@@ -96,6 +96,9 @@
protected void componentActivated() {
super.componentActivated();
ExplorerUtils.activateActions(em, true);
+ if (panel != null) {
+ panel.requestFocusInWindow();
+ }
}
@Override
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/service/LaunchOtfaCampagneRunner.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/service/LaunchOtfaCampagneRunner.java 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/service/LaunchOtfaCampagneRunner.java 2014-05-28 21:04:56 UTC (rev 8750)
@@ -69,7 +69,8 @@
@Override
public void setProgression(int _v) {
- ph.progress(_v);
+ ph.progress(Math.max(100, _v));
+ ph.progress("prog " + _v);
}
@Override
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java 2014-05-28 21:00:47 UTC (rev 8749)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/ReportVisualTopComponent.java 2014-05-28 21:04:56 UTC (rev 8750)
@@ -82,7 +82,7 @@
preferredID = ReportVisualTopComponent.TOPCOMPONENT_ID)
public final class ReportVisualTopComponent extends AbstractReportTimeTopComponent implements LookupListener, ExplorerManager.Provider,
CtuluImageProducer, ReportTopComponentConfigurable<ReportPlanimetryConfig>, PropertyChangeListener {
-
+
public static final String TOPCOMPONENT_ID = "ReportVisualTopComponent";
public static final String TOPCOMPONENT_ACTION = "CTL_" + TOPCOMPONENT_ID;
public static final String TOPCOMPONENT_ACTION_DISPLAYNAME = "#" + TOPCOMPONENT_ACTION;
@@ -95,7 +95,7 @@
private final ExplorerManager em = new ExplorerManager();
ReportPlanimetryConfig reportPlanimetryConfig = new ReportPlanimetryConfig();
private final ReportPlanimetryConfigurer reportPlanimetryConfigurer = new ReportPlanimetryConfigurer();
-
+
public ReportVisualTopComponent() {
initComponents();
setDefaultName();
@@ -107,27 +107,27 @@
ActionMap map = this.getActionMap();
associateLookup(ExplorerUtils.createLookup(em, map));
}
-
+
@Override
protected String getHelpCtxId() {
return SysdocUrlBuilder.getTopComponentHelpCtxId("vuePlanimetrie", PerspectiveEnum.REPORT);
}
-
+
@Override
public ReportPlanimetryConfig getReportConfig() {
return reportPlanimetryConfig;
}
-
+
@Override
public boolean isClosable() {
return false;
}
-
+
@Override
public void rangeChanged() {
setReportConfig(getReportConfig(), false);
}
-
+
@Override
public void setReportConfig(ReportPlanimetryConfig newConfig, boolean fromTemplate) {
super.updating = true;
@@ -154,27 +154,27 @@
}
}
private ReportViewLineInfo info;
-
+
@Override
public void setReportInfo(ReportViewLineInfo info) {
this.info = info;
}
-
+
@Override
public AbstractReportTopComponent getTopComponent() {
return this;
}
-
+
@Override
public void updateFrameName() {
setName(info == null ? "" : info.getNom());
updateTopComponentName();
}
-
+
public ReportPlanimetryConfigurer getReportPlanimetryConfigurer() {
return reportPlanimetryConfigurer;
}
-
+
private void updateConfigurer() {
if (panel != null) {
final PlanimetryController planimetryController = panel.getPlanimetryController();
@@ -199,40 +199,43 @@
panel.getVueCalque().repaint(0);
}
}
-
+
@Override
public BufferedImage produceImage(Map params) {
return panel.produceImage(params);
}
-
+
@Override
public BufferedImage produceImage(int w, int h, Map params) {
return panel.produceImage(w, h, params);
}
-
+
@Override
public Dimension getDefaultImageDimension() {
return panel.getDefaultImageDimension();
}
-
+
@Override
protected void componentActivated() {
super.componentActivated();
ExplorerUtils.activateActions(em, true);
+ if (panel != null) {
+ panel.requestFocusInWindow();
+ }
}
-
+
@Override
protected void componentDeactivated() {
super.componentDeactivated();
ExplorerUtils.activateActions(em, false);
}
-
+
@Override
public ExplorerManager getExplorerManager() {
return em;
}
Map<String, Long> calcByName;
-
+
@Override
public void selectedTimeChanged() {
if (reportService.getRunCourant() != null & panel != null) {
@@ -245,11 +248,11 @@
panel.getPlanimetryController().setEditedCalcul(calcSelected);
}
}
-
+
@Override
public void timeFormatChanged() {
}
-
+
@Override
public void setEditable(boolean b) {
this.editable = b;
@@ -258,7 +261,7 @@
planimetryVisuPanel.getPlanimetryController().setEditable(b, false);
}
}
-
+
@Override
public void setModified(boolean modified) {
super.setModified(modified);
@@ -268,7 +271,7 @@
}
}
}
-
+
@Override
protected void runLoadedHandler() {
if (reportVisuService.getPlanimetryVisuPanel() != null) {
@@ -276,10 +279,10 @@
}
}
VisuConfiguration initConfiguration;
-
+
protected void scenarioVisuLoaded() {
this.removeAll();
-
+
panel = reportVisuService.getPlanimetryVisuPanel();
List<BCalque> mainLayers = panel.getPlanimetryController().getMainLayers();
for (BCalque bCalque : mainLayers) {
@@ -315,20 +318,20 @@
}
private final Set<String> ignoreProperties = new TreeSet<String>(Arrays.asList("versEcran", "versReel"));
VisuChangerListener modificationChangeListener = new VisuChangerListener();
-
+
@Override
public void propertyChange(PropertyChangeEvent evt) {
if (panel != null && !updating) {
reportPlanimetryConfig.setVisibility(panel.getPlanimetryController().getLayerVisibility());
reportViewServiceContrat.changesDoneIn(ReportVisualTopComponent.this);
-
+
}
-
+
}
private PlanimetryVisuPanel panel;
private LayerSelectionListener selectionListener = null;
SelectedEMHsLookupListener selectedEMHsLookupListener;
-
+
public void buildCalcMapIfNeeded() {
if (calcByName == null) {
calcByName = new HashMap<String, Long>();
@@ -339,7 +342,7 @@
}
}
}
-
+
@Override
public void clearReportModifications() {
updating = true;
@@ -352,11 +355,11 @@
clearModificationState();
updating = false;
}
-
+
private void setDefaultName() throws MissingResourceException {
setName(NbBundle.getMessage(ReportVisualTopComponent.class, TOPCOMPONENT_ACTION));
}
-
+
private void restoreDefaultConfigurationData() {
ReportTemplateFileProvider template = new ReportTemplateFileProvider();
reportPlanimetryConfig = (ReportPlanimetryConfig) template.loadTemplate(ReportContentType.PLANIMETRY);
@@ -370,19 +373,19 @@
setDefaultName();
setModified(false);
}
-
+
private void clearModificationState() {
setModified(false);
}
-
+
private class LayerSelectionListener implements ZSelectionListener {
-
+
@Override
public void selectionChanged(ZSelectionEvent _evt) {
selectionChangedInPanel();
}
}
-
+
protected void selectionChangedInPanel() {
if (updating) {
return;
@@ -409,12 +412,12 @@
//met à jour la sélection des EMHs.
reportSelectedEMHService.setSelectedEMHs(selected);
}
-
+
protected JComponent createToolbar(PlanimetryVisuPanel panel) {
SaveTemplateAction action = new SaveTemplateAction(this);
return PlanimetryVisuPanelBuilder.buildTopComponent(panel, action.buildButton(EbliComponentFactory.INSTANCE));
}
-
+
@Override
protected void runUnloadedHandler() {
updating = true;
@@ -427,7 +430,7 @@
bCalque.removePropertyChangeListener(BSelecteurCheckBox.PROP_USER_VISIBLE, this);
}
}
-
+
panel = null;
calcByName = null;
this.removeAll();
@@ -459,7 +462,7 @@
}
}
VisuPanelLookupListener visuLookupListener;
-
+
@Override
protected void componentOpenedHandler() {
if (resultatVisuPanel == null) {
@@ -475,14 +478,14 @@
if (info != null) {
updateFrameName();
}
-
+
}
-
+
private class SelectedEMHsLookupListener implements LookupListener {
-
+
@Override
public void resultChanged(LookupEvent ev) {
-
+
if (panel == null || WindowManager.getDefault().getRegistry().getActivated() == ReportVisualTopComponent.this) {
return;
}
@@ -493,14 +496,14 @@
Collection<Long> uids = new ArrayList<Long>(allItems.size());
for (Long uid : allItems) {
uids.add(uid);
-
+
}
updating = true;
panel.setSelectedEMHFromUids(uids);
updating = false;
}
}
-
+
@Override
protected void componentClosedDefinitlyHandler() {
if (resultatVisuPanel != null) {
@@ -512,28 +515,28 @@
resultatEMHsSelected = null;
}
}
-
+
@Override
public void componentClosedTemporarily() {
super.componentClosedTemporarily();
}
-
+
void writeProperties(java.util.Properties p) {
// better to version settings since initial version as advocated at
// http://wiki.apidesign.org/wiki/PropertyFiles
p.setProperty("version", "1.0");
// TODO store your settings
}
-
+
void readProperties(java.util.Properties p) {
// TODO read your settings according to their version
}
-
+
private class VisuChangerListener implements PropertyChangeListener, Observer {
-
+
public VisuChangerListener() {
}
-
+
@Override
public void update(Observable o, Object arg) {
if (!updating && "visible".equals(arg)) {
@@ -541,16 +544,16 @@
reportViewServiceContrat.changesDoneIn(ReportVisualTopComponent.this);
}
}
-
+
@Override
public void propertyChange(PropertyChangeEvent evt) {
-
+
if (panel == null) {
return;
}
if (evt.getSource() == panel.getCqLegend() && (!editable || ignoreProperties.contains(evt.getPropertyName()))) {
return;
-
+
}
if (updating) {
return;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-06-03 22:04:08
|
Revision: 8752
http://sourceforge.net/p/fudaa/svn/8752
Author: deniger
Date: 2014-06-03 22:04:01 +0000 (Tue, 03 Jun 2014)
Log Message:
-----------
correction bogues OTFA/Rapport
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportProperty.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportPropertyEditorSupport.java
trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/ScenarioProperty.java
Modified: trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
===================================================================
--- trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-06-03 22:04:01 UTC (rev 8752)
@@ -3,6 +3,7 @@
otfa.validator.cibleEtuFileNotFound=Le fichier etu cible {0} n''existe pas
otfa.validator.reportNotFoundReference=Le rapport {0} n''existe pas pour la r\u00e9f\u00e9rence
otfa.validator.reportNotFoundCible=Le rapport {0} n''existe pas pour la cible
+otfa.validator.reportNotEmptyButCibleEmpty=Un rapport est d\u00e9fini pour une cible vide
otfa.scenarionNotFound.detail=Le sc\u00e9nario {0} n''a pas \u00e9t\u00e9 trouv\u00e9
otfa.scenarioNotFound=Sc\u00e9nario introuvable
migrate.isChildrenFilesTester.isNotChild=Le fichier {0} n''est pas contenu dans le r\u00e9pertoire de l''\u00e9tude initiale
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaContentValidator.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -318,8 +318,11 @@
log.addSevereError("otfa.validator.reportNotFoundReference", line.getReference().getRapport());
}
if (!rapportIsBlankOrExists(campagne, line.getFinalCible(), log)) {
- log.addSevereError("otfa.validator.reportNotFoundCible", line.getReference().getRapport());
+ log.addSevereError("otfa.validator.reportNotFoundCible", line.getFinalCible().getRapport());
}
+ if (StringUtils.isNotEmpty(line.getCible().getRapport()) && line.getCible().isEmpty()) {
+ log.addSevereError("otfa.validator.reportNotEmptyButCibleEmpty");
+ }
}
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaExecutor.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -373,14 +373,9 @@
final CtuluLogGroup reportGroup = logs.createGroup("otfa.reportCreation");
reportGroup.setDescriptionArgs(item.getRapport());
- if (managerScenario.getRunCourant() == null) {
- reportGroup.createNewLog("otfa.report.loading").addSevereError("otfa.report.notGenerated.NoCurrentRun");
- } else {
- OtfaReportExecutor report = new OtfaReportExecutor(projet, managerScenario, emhScenario, item, campagne);
- report.exportCSV(reportGroup);
+ OtfaReportExecutor report = new OtfaReportExecutor(projet, managerScenario, emhScenario, item, campagne);
+ report.exportCSV(reportGroup);
- }
-
}
}
Modified: trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java
===================================================================
--- trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/crue-otfa/src/main/java/org/fudaa/dodico/crue/projet/otfa/OtfaReportExecutor.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -76,6 +76,9 @@
void exportCSV(CtuluLogGroup logs) {
final EMHRun run = managerScenario.getRunCourant();
CtuluLog log = logs.createNewLog("otfa.report.loading");
+ if (run == null) {
+ log.addWarn("otfa.report.notGenerated.NoCurrentRun");
+ }
ReportIndexReaderHelper helper = new ReportIndexReaderHelper(projet);
final ReportContentType contentType = ReportViewLineInfoAndType.getContentType(item.getRapport());
if (contentType == null) {
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/node/OtfaCampagneLineNode.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -276,7 +276,7 @@
rapport.setName("referenceRapport");
rapport.setDisplayName(NbBundle.getMessage(OtfaCampagneLineNode.class, "rapportName"));
rapport.setShortDescription(NbBundle.getMessage(OtfaCampagneLineNode.class, "rapportDescription"));
-
+ PropertyCrueUtils.configureNoEditAsText(rapport);
set.put(etude);
set.put(scenario);
set.put(coeur);
@@ -355,6 +355,7 @@
rapport.setName("cibleRapport");
rapport.setDisplayName(NbBundle.getMessage(OtfaCampagneLineNode.class, "rapportName"));
rapport.setShortDescription(NbBundle.getMessage(OtfaCampagneLineNode.class, "rapportDescription"));
+ PropertyCrueUtils.configureNoEditAsText(rapport);
set.put(etude);
set.put(scenario);
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportCustomEditor.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -44,7 +44,15 @@
@Override
protected JComponent createComponent() {
RapportPropertyEditorSupport scenarioEditor = (RapportPropertyEditorSupport) editor;
- File etuFile = scenarioEditor.getCampagneItem().getEtuFile(scenarioEditor.getCampagne().getOtfaDir());
+ //test == voulu car test sur référence
+ boolean isCible = scenarioEditor.getCampagneligne().getCible() == scenarioEditor.getCampagneItem();
+ File etuFile = null;
+ if (isCible && StringUtils.isEmpty(scenarioEditor.getCampagneItem().getEtuPath())) {
+ //dans ce cas on tente avec la référence
+ etuFile = scenarioEditor.getCampagneligne().getReference().getEtuFile(scenarioEditor.getCampagne().getOtfaDir());
+ } else {
+ etuFile = scenarioEditor.getCampagneItem().getEtuFile(scenarioEditor.getCampagne().getOtfaDir());
+ }
if (etuFile == null || !etuFile.isFile()) {
JLabel lb = new JLabel();
lb.setForeground(Color.RED);
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportProperty.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportProperty.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportProperty.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -4,18 +4,14 @@
*/
package org.fudaa.fudaa.crue.otfa.property;
-import java.awt.Component;
import java.beans.PropertyEditor;
-import java.beans.PropertyEditorSupport;
-import java.io.File;
+import org.fudaa.dodico.crue.io.rtfa.RTFAResultLine;
import org.fudaa.dodico.crue.projet.otfa.OtfaCampagne;
import org.fudaa.dodico.crue.projet.otfa.OtfaCampagneItem;
import org.fudaa.fudaa.crue.common.property.AbstractNodeFirable;
+import org.fudaa.fudaa.crue.common.property.PropertyCrueUtils;
import org.fudaa.fudaa.crue.common.property.PropertySupportReflection;
-import org.fudaa.fudaa.crue.options.services.ConfigurationManagerService;
import org.fudaa.fudaa.crue.otfa.perspective.PerspectiveServiceOtfa;
-import org.openide.explorer.propertysheet.ExPropertyEditor;
-import org.openide.explorer.propertysheet.PropertyEnv;
import org.openide.util.Lookup;
/**
@@ -30,6 +26,7 @@
public RapportProperty(AbstractNodeFirable node, OtfaCampagne campagne, OtfaCampagneItem instance, String getter, String setter) throws NoSuchMethodException {
super(node, instance, String.class, getter, setter);
this.campagne = campagne;
+
}
@Override
@@ -39,6 +36,7 @@
@Override
public PropertyEditor getPropertyEditor() {
- return new RapportPropertyEditorSupport(campagne, (OtfaCampagneItem) instance);
+ final RTFAResultLine line = node.getLookup().lookup(RTFAResultLine.class);
+ return new RapportPropertyEditorSupport(campagne, line == null ? null : line.getInitialLine(), (OtfaCampagneItem) instance);
}
}
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportPropertyEditorSupport.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportPropertyEditorSupport.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/RapportPropertyEditorSupport.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -9,6 +9,8 @@
import java.io.File;
import org.fudaa.dodico.crue.projet.otfa.OtfaCampagne;
import org.fudaa.dodico.crue.projet.otfa.OtfaCampagneItem;
+import org.fudaa.dodico.crue.projet.otfa.OtfaCampagneLine;
+import org.fudaa.fudaa.crue.common.property.PropertyCrueUtils;
import org.openide.explorer.propertysheet.ExPropertyEditor;
import org.openide.explorer.propertysheet.PropertyEnv;
@@ -19,13 +21,20 @@
public class RapportPropertyEditorSupport extends PropertyEditorSupport implements ExPropertyEditor {
private final OtfaCampagne campagne;
private final OtfaCampagneItem campagneItem;
+ private final OtfaCampagneLine campagneligne;
private PropertyEnv env;
- public RapportPropertyEditorSupport(OtfaCampagne campagne, OtfaCampagneItem item) {
+ public RapportPropertyEditorSupport(OtfaCampagne campagne, OtfaCampagneLine ligne, OtfaCampagneItem item) {
this.campagne = campagne;
+ this.campagneligne = ligne;
this.campagneItem = item;
}
+ public OtfaCampagneLine getCampagneligne() {
+ return campagneligne;
+ }
+
+
public OtfaCampagne getCampagne() {
return campagne;
}
@@ -46,8 +55,7 @@
@Override
public boolean supportsCustomEditor() {
- final File etuFile = campagneItem.getEtuFile(campagne.getOtfaDir());
- return etuFile != null && etuFile.isFile();
+ return true;
}
@Override
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/ScenarioProperty.java
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/ScenarioProperty.java 2014-06-03 21:11:23 UTC (rev 8751)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/java/org/fudaa/fudaa/crue/otfa/property/ScenarioProperty.java 2014-06-03 22:04:01 UTC (rev 8752)
@@ -4,18 +4,12 @@
*/
package org.fudaa.fudaa.crue.otfa.property;
-import java.awt.Component;
import java.beans.PropertyEditor;
-import java.beans.PropertyEditorSupport;
-import java.io.File;
import org.fudaa.dodico.crue.projet.otfa.OtfaCampagne;
import org.fudaa.dodico.crue.projet.otfa.OtfaCampagneItem;
import org.fudaa.fudaa.crue.common.property.AbstractNodeFirable;
import org.fudaa.fudaa.crue.common.property.PropertySupportReflection;
-import org.fudaa.fudaa.crue.options.services.ConfigurationManagerService;
import org.fudaa.fudaa.crue.otfa.perspective.PerspectiveServiceOtfa;
-import org.openide.explorer.propertysheet.ExPropertyEditor;
-import org.openide.explorer.propertysheet.PropertyEnv;
import org.openide.util.Lookup;
/**
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-06-09 19:54:28
|
Revision: 8755
http://sourceforge.net/p/fudaa/svn/8755
Author: deniger
Date: 2014-06-09 19:54:19 +0000 (Mon, 09 Jun 2014)
Log Message:
-----------
CRUE-597
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ModellingListSectionTopComponent.java
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/loi/ProfilSectionTopComponent.java
trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/transversal/ReportProfilTransversalTopComponent.java
trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/transversal/Bundle.properties
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ModellingListSectionTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ModellingListSectionTopComponent.java 2014-06-04 11:12:37 UTC (rev 8754)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/list/ModellingListSectionTopComponent.java 2014-06-09 19:54:19 UTC (rev 8755)
@@ -157,6 +157,7 @@
protected void openAddNodeTopComponent(final AddSectionInBranchePanelContentData data) {
Runnable runnable = new Runnable() {
+ @Override
public void run() {
ModellingOpenListSectionAddNodeAction.open(getSousModele(), data);
}
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/loi/ProfilSectionTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/loi/ProfilSectionTopComponent.java 2014-06-04 11:12:37 UTC (rev 8754)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/loi/ProfilSectionTopComponent.java 2014-06-09 19:54:19 UTC (rev 8755)
@@ -73,8 +73,8 @@
public static final String PROPERTY_INIT_UID = "initUid";
public static final String MODE = "loi-profilSectionEditor"; //NOI18N
public static final String TOPCOMPONENT_ID = "ProfilSectionTopComponent"; //NOI18N
- private ProfilSectionLoiUiController profilUiController;
- private JTextField txtCommentaire;
+ private final ProfilSectionLoiUiController profilUiController;
+ private final JTextField txtCommentaire;
/**
* permet de sélectionner le profil précédent
*/
@@ -83,14 +83,14 @@
* permet de sélectionner le profil suivant
*/
private JButton btDown;
- private JTextField txtNom;
- private JLabel lbNomValidation;
- private JLabel lbCreationSection;
+ private final JTextField txtNom;
+ private final JLabel lbNomValidation;
+ private final JLabel lbCreationSection;
private Action delete;
private Action duplicate;
private Action create;
protected String initName;
- private ViewCourbeManager viewCourbeManager;
+ private final ViewCourbeManager viewCourbeManager;
private ModellingConfigService modellingConfigService = Lookup.getDefault().lookup(ModellingConfigService.class);
/**
* Contient la liste des profils dans l'ordre
@@ -663,12 +663,12 @@
}
void selectNextProfil() {
- selectProfil(1);
+ selectProfilFromDelta(1);
}
void selectPreviousProfil() {
- selectProfil(-1);
+ selectProfilFromDelta(-1);
}
@Override
@@ -742,7 +742,7 @@
return pnActions;
}
- private void selectProfil(int delta) {
+ private void selectProfilFromDelta(int delta) {
if (CollectionUtils.isEmpty(profils)) {
return;
}
Modified: trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/transversal/ReportProfilTransversalTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/transversal/ReportProfilTransversalTopComponent.java 2014-06-04 11:12:37 UTC (rev 8754)
+++ trunk/soft/fudaa-crue/ui-report/src/main/java/org/fudaa/fudaa/crue/report/transversal/ReportProfilTransversalTopComponent.java 2014-06-09 19:54:19 UTC (rev 8755)
@@ -5,19 +5,16 @@
import java.awt.event.ActionEvent;
import java.util.ArrayList;
import java.util.Arrays;
-import java.util.Collections;
import java.util.Iterator;
import java.util.List;
import java.util.Set;
import javax.swing.JPanel;
import javax.swing.JSplitPane;
-import org.apache.commons.collections.CollectionUtils;
+import org.fudaa.ctulu.CtuluLibArray;
import org.fudaa.dodico.crue.common.transformer.TransformerHelper;
-import org.fudaa.dodico.crue.metier.emh.CatEMHBranche;
import org.fudaa.dodico.crue.metier.emh.CatEMHSection;
import org.fudaa.dodico.crue.metier.emh.OrdResScenario;
import org.fudaa.dodico.crue.metier.emh.OrdResSection;
-import org.fudaa.dodico.crue.metier.emh.RelationEMHSectionDansBranche;
import org.fudaa.dodico.crue.metier.result.OrdResExtractor;
import org.fudaa.dodico.crue.metier.result.OrdResVariableSelection;
import org.fudaa.ebli.commun.EbliActionInterface;
@@ -146,7 +143,7 @@
protected void chooseSection() {
final List<CatEMHSection> sections = reportService.getModele().getSections();
List<String> sectionNames = TransformerHelper.toNom(sections);
- ChooseInListHelper<String> chooser = new ChooseInListHelper<String>();
+ ChooseInListHelper<String> chooser = new ChooseInListHelper<>();
chooser.setLabel(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "ChooseSectionName.Label"));
chooser.setDialogTitle(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "ChooseSection.DialogTitle"));
String newSection = chooser.choose(sectionNames, content.getSectionName());
@@ -157,76 +154,34 @@
}
protected void chooseAval() {
- choose(1);
+ chooseFromDelta(1);
}
protected void chooseAmont() {
- choose(-1);
+ chooseFromDelta(-1);
}
private CatEMHSection findSection(CatEMHSection current, int inc) {
if (current == null) {
return null;
}
- CatEMHBranche branche = current.getBranche();
- if (branche != null) {
- List<RelationEMHSectionDansBranche> listeSections = branche.getListeSections();
- int idx = indexOf(listeSections, current) + inc;
- if (idx >= listeSections.size()) {
- List<CatEMHBranche> branchesAval = branche.getNoeudAval().getBranchesAval();
- final boolean empty = CollectionUtils.isEmpty(branchesAval);
- if (empty || branchesAval.size() > 1) {
- if (empty) {
- DialogHelper.showInfo(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SectionNavigation.InfoDialog"),
- NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "NoAvalSectionWithResultat.DialogContent"));
- } else {
- DialogHelper.showInfo(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SectionNavigation.InfoDialog"),
- NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SeveralAvalBranche.DialogContent"));
-
- }
- return null;
- }
- branche = branchesAval.get(0);
- listeSections = branche.getListeSections();
- CatEMHSection first = listeSections.get(0).getEmh();
- return first;
- } else if (idx < 0) {
- List<CatEMHBranche> branchesAmont = branche.getNoeudAmont().getBranchesAmont();
- final boolean empty = CollectionUtils.isEmpty(branchesAmont);
- if (empty || branchesAmont.size() > 1) {
- if (empty) {
- DialogHelper.showInfo(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SectionNavigation.InfoDialog"),
- NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "NoAmontSectionWithResultat.DialogContent"));
- } else {
- DialogHelper.showInfo(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SectionNavigation.InfoDialog"),
- NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SeveralAmontBranche.DialogContent"));
-
- }
- return null;
-
- }
- branche = branchesAmont.get(0);
- listeSections = branche.getListeSections();
- CatEMHSection last = listeSections.get(listeSections.size() - 1).getEmh();
- return last;
- } else {
- CatEMHSection emh = listeSections.get(idx).getEmh();
- return emh;
- }
+ final List<CatEMHSection> sections = reportService.getModele().getSections();
+ int idx = CtuluLibArray.findObjectEgalEgal(sections, current) + inc;
+ if (idx < 0) {
+ DialogHelper.showInfo(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SectionNavigation.InfoDialog"),
+ NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "NoAmontSectionWithResultat.DialogContent"));
+ return null;
}
- return null;
- }
-
- private int indexOf(List<RelationEMHSectionDansBranche> listeSections, CatEMHSection section) {
- for (int i = 0; i < listeSections.size(); i++) {
- RelationEMHSectionDansBranche relationEMHSectionDansBranche = listeSections.get(i);
- if (relationEMHSectionDansBranche.getEmh() == section) {
- return i;
- }
+ if (idx >= sections.size()) {
+ DialogHelper.showInfo(NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "SectionNavigation.InfoDialog"),
+ NbBundle.getMessage(ReportProfilTransversalTopComponent.class, "NoAvalSectionWithResultat.DialogContent"));
+ return null;
}
- return -1;
+ return sections.get(idx);
}
+
+
/**
* This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always
* regenerated by the Form Editor.
@@ -294,7 +249,7 @@
@Override
public List<ReportVariableKey> getTitleAvailableVariables() {
- List<ReportVariableKey> res = new ArrayList<ReportVariableKey>();
+ List<ReportVariableKey> res = new ArrayList<>();
res.add(new ReportVariableKey(ReportVariableTypeEnum.EXPR, ReportExpressionHelper.EXPR_NOM));
res.add(new ReportVariableKey(ReportVariableTypeEnum.EXPR, ReportExpressionHelper.EXPR_COMMENTAIRE));
res.add(new ReportVariableKey(ReportVariableTypeEnum.EXPR, ReportExpressionHelper.EXPR_PROFIL_COMMENTAIRE));
@@ -312,7 +267,7 @@
return res;
}
- public void choose(final int inc) {
+ public void chooseFromDelta(final int inc) {
CatEMHSection section = (CatEMHSection) reportService.getRunCourant().getEMH(content.getSectionName());
CatEMHSection findSection = findSection(section, inc);
if (findSection != null) {
Modified: trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/transversal/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/transversal/Bundle.properties 2014-06-04 11:12:37 UTC (rev 8754)
+++ trunk/soft/fudaa-crue/ui-report/src/main/resources/org/fudaa/fudaa/crue/report/transversal/Bundle.properties 2014-06-09 19:54:19 UTC (rev 8755)
@@ -3,13 +3,11 @@
ChooseVariable.DialogTitle=Choix des variables
AddVariable.ButtonName=Variables
ChooseSection.ButtonName=Section
-ChooseSectionAmont.ButtonName=Amont
-ChooseSectionAval.ButtonName=Aval
+ChooseSectionAmont.ButtonName=Pr\u00e9c.
+ChooseSectionAval.ButtonName=Suiv.
ChooseSectionName.Label=Section \u00e0 utiliser:
ChooseSection.DialogTitle=Profil en travers
SectionNavigation.InfoDialog=Navigation
-NoAmontSectionWithResultat.DialogContent=Aucune section amont n'a \u00e9t\u00e9 trouv\u00e9e
-SeveralAmontBranche.DialogContent=La navigation vers l'amont est impossible: plusieurs branches amont
+NoAmontSectionWithResultat.DialogContent=Aucune section amont n'a \u00e9t\u00e9 trouv\u00e9e
NoAvalSectionWithResultat.DialogContent=Aucune section aval n'a \u00e9t\u00e9 trouv\u00e9e
-SeveralAvalBranche.DialogContent=La navigation vers l'aval est impossible: plusieurs branches aval
ConfigureTitle.Action=Configurer le titre
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-06-09 21:19:04
|
Revision: 8759
http://sourceforge.net/p/fudaa/svn/8759
Author: deniger
Date: 2014-06-09 21:19:00 +0000 (Mon, 09 Jun 2014)
Log Message:
-----------
CRUE-583
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/report-longitudinalWsmode.xml
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingNetworkTopComponent.java
trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/explorer.xml
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output.wsmode
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output_1Wsmode.xml
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/properties.xml
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/rightSlidingSide.xml
Added: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/explorer.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/explorer.xml (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/explorer.xml 2014-06-09 21:19:00 UTC (rev 8759)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<mode version="2.4">
+ <module name="org.netbeans.core.ui/1" spec="1.2" />
+ <name unique="explorer" />
+ <kind type="view" />
+ <state type="joined" />
+ <constraints>
+ <path orientation="horizontal" number="20" weight="0.3"/>
+ <path orientation="vertical" number="20" weight="0.5"/>
+ </constraints>
+ <bounds x="168" y="224" width="537" height="510" />
+ <frame state="0"/>
+ <empty-behavior permanent="true"/>
+</mode>
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml 2014-06-09 20:56:21 UTC (rev 8758)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml 2014-06-09 21:19:00 UTC (rev 8759)
@@ -114,7 +114,7 @@
<file name="properties.settings_hidden"/>
</folder>
<folder name="Modes">
- <file name="sysdoc.wsmode" url="sysdocWsmode.xml"/>
+ <file name="sysdoc.wsmode" url="sysdocWsmode.xml"/>
<file name="study-editor.wsmode" url="study-editorWsmode.xml"/>
<file name="study-bottomLeft.wsmode" url="study-bottomLeftWsmode.xml"/>
<file name="study-bottomRight.wsmode" url="study-bottomRightWsmode.xml"/>
@@ -177,6 +177,12 @@
<file name="otfa-topLeft.wsmode" url="otfa-topLeftWsmode.xml"/>
<file name="otfa-editor.wsmode" url="otfa-editorWsmode.xml"/>
+
+
+ <file name="rightSlidingSide.wsmode" url="rightSlidingSide.xml"/>
+ <file name="explorer.wsmode" url="explorer.xml"/>
+ <file name="properties.wsmode" url="properties.xml"/>
+ <file name="output.wsmode" url="output.xml"/>
</folder>
</folder>
<folder name="Windows2Local">
Added: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output.wsmode
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output.wsmode (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output.wsmode 2014-06-09 21:19:00 UTC (rev 8759)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<mode version="2.4">
+ <name unique="output" />
+ <kind type="view" />
+ <state type="joined" />
+ <constraints>
+ <path orientation="horizontal" number="60" weight="0.6965352449223416"/>
+ <path orientation="vertical" number="80" weight="0.3"/>
+ <path orientation="horizontal" number="30" weight="0.8"/>
+ </constraints>
+ <bounds x="168" y="693" width="672" height="204" />
+ <frame state="0"/>
+ <empty-behavior permanent="true"/>
+</mode>
Added: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output_1Wsmode.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output_1Wsmode.xml (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/output_1Wsmode.xml 2014-06-09 21:19:00 UTC (rev 8759)
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<mode version="2.4">
+ <name unique="output" />
+ <kind type="view" />
+ <state type="joined" />
+ <constraints>
+ <path orientation="horizontal" number="60" weight="0.6965352449223416"/>
+ <path orientation="vertical" number="80" weight="0.3"/>
+ <path orientation="horizontal" number="30" weight="0.8"/>
+ </constraints>
+ <bounds x="168" y="693" width="672" height="204" />
+ <frame state="0"/>
+ <empty-behavior permanent="true"/>
+</mode>
Added: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/properties.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/properties.xml (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/properties.xml 2014-06-09 21:19:00 UTC (rev 8759)
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<mode version="2.4">
+ <name unique="properties" />
+ <kind type="view" />
+ <state type="joined" />
+ <constraints>
+ <path orientation="horizontal" number="60" weight="0.6965352449223416"/>
+ <path orientation="vertical" number="40" weight="0.7"/>
+ <path orientation="horizontal" number="80" weight="0.3"/>
+ <path orientation="vertical" number="80" weight="0.5"/>
+ </constraints>
+ <bounds x="1260" y="571" width="252" height="326" />
+ <frame state="0"/>
+ <empty-behavior permanent="true"/>
+</mode>
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/report-longitudinalWsmode.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/report-longitudinalWsmode.xml 2014-06-09 20:56:21 UTC (rev 8758)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/report-longitudinalWsmode.xml 2014-06-09 21:19:00 UTC (rev 8759)
@@ -6,7 +6,7 @@
<constraints>
<path orientation="horizontal" number="238" weight="0.5"/>
</constraints>
- <bounds x="350" y="50" width="1000" height="850" />
+ <bounds x="333" y="52" width="1159" height="921" />
<frame state="0"/>
<empty-behavior permanent="true"/>
</mode>
Added: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/rightSlidingSide.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/rightSlidingSide.xml (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/rightSlidingSide.xml 2014-06-09 21:19:00 UTC (rev 8759)
@@ -0,0 +1,12 @@
+<?xml version="1.0" encoding="UTF-8"?>
+
+<mode version="2.4">
+ <module name="org.netbeans.core.ui/1" spec="1.2" />
+ <name unique="rightSlidingSide" />
+ <kind type="sliding" />
+ <slidingSide side="right" />
+ <state type="joined" />
+ <bounds x="1" y="0" width="1262" height="964" />
+ <frame state="0"/>
+ <empty-behavior permanent="true"/>
+</mode>
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingNetworkTopComponent.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingNetworkTopComponent.java 2014-06-09 20:56:21 UTC (rev 8758)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/ModellingNetworkTopComponent.java 2014-06-09 21:19:00 UTC (rev 8759)
@@ -26,7 +26,6 @@
import org.fudaa.dodico.crue.edition.SimplificationProcessor;
import org.fudaa.dodico.crue.edition.SimplificationSeuils;
import org.fudaa.fudaa.crue.common.helper.DialogHelper;
-import org.fudaa.fudaa.crue.common.helper.DisableSortHelper;
import org.fudaa.fudaa.crue.modelling.loi.SimplificationSeuilsChooser;
import org.fudaa.fudaa.crue.modelling.node.ModellingNodeEMHFactory;
import org.fudaa.fudaa.crue.modelling.services.ModellingSelectedEMHService;
@@ -245,7 +244,7 @@
return;
}
updating = true;
- Set<Long> selectedUid = new HashSet<Long>(resultatEMHsSelected.allInstances());
+ Set<Long> selectedUid = new HashSet<>(resultatEMHsSelected.allInstances());
selectEMHs(selectedUid);
updating = false;
}
Modified: trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java
===================================================================
--- trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java 2014-06-09 20:56:21 UTC (rev 8758)
+++ trunk/soft/fudaa-crue/ui-planimetry/src/main/java/org/fudaa/fudaa/crue/planimetry/layer/PlanimetryBrancheModel.java 2014-06-09 21:19:00 UTC (rev 8759)
@@ -134,7 +134,7 @@
@Override
public boolean addGeometry(GrPolyligne _p, CtuluCommandContainer _cmd, CtuluUI _ui, ZEditionAttributesDataI _d) {
- if (_p.nombre() == 0) {
+ if (_p.nombre() < 2) {
return false;
}
PlanimetryControllerHelper helper = super.getLayerController().getHelper();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-06-10 22:27:25
|
Revision: 8762
http://sourceforge.net/p/fudaa/svn/8762
Author: deniger
Date: 2014-06-10 22:27:20 +0000 (Tue, 10 Jun 2014)
Log Message:
-----------
CRUE-648
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/projet/ScenarioRunCleaner.java
trunk/soft/fudaa-crue/crue-validation/src/main/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSection.java
trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSectionTest.java
trunk/soft/fudaa-crue/ui-loader/src/main/java/org/fudaa/fudaa/crue/loader/ScenarioLoaderServiceAbstract.java
trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/section/ProfilSectionLoiUiController.java
Added Paths:
-----------
trunk/soft/fudaa-crue/crue-validation/src/test/resources/
trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dc
trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dh
Modified: trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/projet/ScenarioRunCleaner.java
===================================================================
--- trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/projet/ScenarioRunCleaner.java 2014-06-09 21:22:31 UTC (rev 8761)
+++ trunk/soft/fudaa-crue/crue-project/src/main/java/org/fudaa/dodico/crue/projet/ScenarioRunCleaner.java 2014-06-10 22:27:20 UTC (rev 8762)
@@ -49,7 +49,13 @@
return toDelete;
}
File dirOfRuns = projet.getInfos().getDirOfRuns();
+ if (dirOfRuns == null) {
+ return toDelete;
+ }
File[] listFilesScenarios = dirOfRuns.listFiles();
+ if (listFilesScenarios == null) {
+ return toDelete;
+ }
for (File scenarioFile : listFilesScenarios) {
if (scenarioFile.isDirectory()) {
if (expectedScenarioDir.contains(scenarioFile.getAbsolutePath())) {
Modified: trunk/soft/fudaa-crue/crue-validation/src/main/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSection.java
===================================================================
--- trunk/soft/fudaa-crue/crue-validation/src/main/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSection.java 2014-06-09 21:22:31 UTC (rev 8761)
+++ trunk/soft/fudaa-crue/crue-validation/src/main/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSection.java 2014-06-10 22:27:20 UTC (rev 8762)
@@ -590,7 +590,7 @@
// tous les lits actifs sont parcourus dans l'ordre et le dernier point rencontré avec la cote la plus basse est choisi.
CrueConfigMetierLitNomme litNomme = props.getLitNomme();
for (LitNommeIndexed litNommeIndexed : litNommes) {
- if (litNomme.isActif(litNommeIndexed.getLitNomme())) {
+ if (litNommeIndexed.getLitNumerotesSize() > 0 && litNomme.isActif(litNommeIndexed.getLitNomme())) {
for (int i = litNommeIndexed.getFirstIdx(); i <= litNommeIndexed.getlastIdx(); i++) {
double z = section.getPtProfil().get(i).getZ();
if (foundIdx < 0 || z <= minZ) {
Modified: trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSectionTest.java
===================================================================
--- trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSectionTest.java 2014-06-09 21:22:31 UTC (rev 8761)
+++ trunk/soft/fudaa-crue/crue-validation/src/test/java/org/fudaa/dodico/crue/validation/ValidateAndRebuildProfilSectionTest.java 2014-06-10 22:27:20 UTC (rev 8762)
@@ -24,6 +24,8 @@
import org.fudaa.dodico.crue.metier.emh.LitNumerote;
import org.fudaa.dodico.crue.metier.helper.DonPrtHelper;
import org.fudaa.dodico.crue.metier.helper.EtiquetteIndexed;
+import org.fudaa.dodico.crue.metier.helper.LitNommeIndexed;
+import org.fudaa.dodico.crue.metier.helper.LitNumeroteIndex;
import org.fudaa.dodico.crue.test.AbstractTestCase;
/**
@@ -81,11 +83,13 @@
assertDoubleEquals(66d, axeHyd.getPoint().getXt());
assertDoubleEquals(0.5d, axeHyd.getPoint().getZ());
ScenarioAutoModifiedState modifiedState = new ScenarioAutoModifiedState();
- CrueIOResu<List<EtiquetteIndexed>> etiquettesAsIndexed = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState).getEtiquettesAsIndexed(profilSection);
+ CrueIOResu<List<EtiquetteIndexed>> etiquettesAsIndexed = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT,
+ modifiedState).getEtiquettesAsIndexed(profilSection);
assertTrue(etiquettesAsIndexed.getAnalyse().isEmpty());
List<EtiquetteIndexed> etiquettesList = etiquettesAsIndexed.getMetier();
assertEquals(2, etiquettesList.size());
- assertEquals(CrueConfigMetierLoaderDefaultTest.DEFAULT.getLitNomme().getEtiquetteThalweg(), etiquettesList.get(0).getEtiquette().getTypeEtiquette());
+ assertEquals(CrueConfigMetierLoaderDefaultTest.DEFAULT.getLitNomme().getEtiquetteThalweg(), etiquettesList.get(0).getEtiquette().
+ getTypeEtiquette());
assertEquals(5, etiquettesList.get(0).getIdx());
assertEquals(CrueConfigMetierLoaderDefaultTest.DEFAULT.getLitNomme().getEtiquetteAxeHyd(), etiquettesList.get(1).getEtiquette().getTypeEtiquette());
assertEquals(4, etiquettesList.get(1).getIdx());
@@ -99,7 +103,8 @@
thalweg.setPoint(profilSection.getPtProfil().get(0));
profilSection.setEtiquettes(Arrays.asList(thalweg));
ScenarioAutoModifiedState modifiedState = new ScenarioAutoModifiedState();
- CtuluLog log = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState).validateAndRebuildDonPrtGeoProfilSection(profilSection);
+ CtuluLog log = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState).
+ validateAndRebuildDonPrtGeoProfilSection(profilSection);
assertTrue(log.containsSevereError());
CtuluLogRecord record = log.getRecords().get(0);
assertEquals("validate.thalweg.NotInLitMineur.Fente", record.getMsg());
@@ -108,7 +113,8 @@
axeHyd.setTypeEtiquette(CrueConfigMetierLoaderDefaultTest.DEFAULT.getLitNomme().getEtiquetteAxeHyd());
axeHyd.setPoint(profilSection.getPtProfil().get(0));
profilSection.setEtiquettes(Arrays.asList(thalweg, axeHyd));
- log = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState).validateAndRebuildDonPrtGeoProfilSection(profilSection);
+ log = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState).validateAndRebuildDonPrtGeoProfilSection(
+ profilSection);
assertTrue(log.containsSevereError());
assertEquals(2, log.getRecords().size());
record = log.getRecords().get(0);
@@ -126,13 +132,28 @@
etiquettes.add(etiquettes.get(0));//on definit l'étiquette thalweg 2 fois.
profilSection.setEtiquettes(etiquettes);
ScenarioAutoModifiedState modifiedState = new ScenarioAutoModifiedState();
- CtuluLog log = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState).validateAndRebuildDonPrtGeoProfilSection(profilSection);
+ CtuluLog log = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState).
+ validateAndRebuildDonPrtGeoProfilSection(profilSection);
assertTrue(log.containsSevereError());
CtuluLogRecord record = log.getRecords().get(0);
assertEquals("validate.etiquette.definedSeveralTimes", record.getMsg());
assertEquals(CrueConfigMetierLoaderDefaultTest.DEFAULT.getLitNomme().getEtiquetteThalweg().geti18n(), record.getArgs()[0]);
assertEquals(Integer.toString(2), record.getArgs()[1]);
+ }
+ public void testJIRA648KiPlantePas() {
+ final EMHSectionProfil sectionProfil = getSectionProfil("PCC2", "/KiPlantePas_c9.dc", "/KiPlantePas_c9.dh");
+ assertNotNull(sectionProfil);
+ ScenarioAutoModifiedState modifiedState = new ScenarioAutoModifiedState();
+ ValidateAndRebuildProfilSection rebuilder = new ValidateAndRebuildProfilSection(CrueConfigMetierLoaderDefaultTest.DEFAULT, modifiedState);
+ List<LitNommeIndexed> asIndexedData = rebuilder.getAsIndexedData(DonPrtHelper.getProfilSection(sectionProfil)).getMetier();
+ final LitNommeIndexed first = asIndexedData.get(0);
+ final LitNumeroteIndex litNumeroteIndex = first.getLitNumeroteIndex(0);
+ assertEquals("FkSto_K0", litNumeroteIndex.getLitNumerote().getFrotId());
+ int idxStart = litNumeroteIndex.getIdxStart();
+ int idxEnd = litNumeroteIndex.getIdxEnd();
+ assertEquals(0, idxStart);
+ assertEquals(0, idxEnd);
}
protected EMHSectionProfil getSectionProfil() {
@@ -143,9 +164,14 @@
return getSectionProfil("St_PROF2");
}
- private EMHSectionProfil getSectionProfil(final String sectionName) {
+ private static EMHSectionProfil getSectionProfil(final String sectionName) {
+ return getSectionProfil(sectionName, "/crue9/201.dc", "/crue9/201.dh");
+
+ }
+
+ private static EMHSectionProfil getSectionProfil(final String sectionName, String dc, String dh) {
CtuluLog log = new CtuluLog();
- CrueIOResu<CrueData> read = ReadHelper.readModeleAndDefaultORES(log, "/crue9/201.dc", "/crue9/201.dh");
+ CrueIOResu<CrueData> read = ReadHelper.readModeleAndDefaultORES(log, dc, dh);
assertFalse(log.containsErrorOrSevereError());
EMHScenario scenario = read.getMetier().getScenarioData();
assertNotNull(scenario);
Added: trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dc
===================================================================
--- trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dc (rev 0)
+++ trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dc 2014-06-10 22:27:20 UTC (rev 8762)
@@ -0,0 +1,103 @@
+*
+TITRE CrueX - Structuration des donn\xE9es
+TITRE
+TITRE Mod\xE8le de test utilisant une unique branche de Saint-Venant
+TITRE
+TITRE NJB
+*
+*
+* Configuration generale
+ZREF 0.0
+COEFF 1.0 0.75 1
+* DECAL
+R_DECAL 0.2
+* LARG_SEUIL
+R_SLARGE 100.0
+* PDX_MAX
+R_DXMAX 200.0
+* PENTE_MAX
+R_PENMAX 1.0
+* PENTE_RUPTURE
+R_RUPENT 1.0E-5
+* PROF_PLAT
+R_PRPLAT 0.01
+* REB_DEB
+R_REBDEB
+* VAR_PDX_MAX
+R_VDXMAX 1
+*
+*
+* Definition des Noeuds
+NOEUD Nd_N1 Nd_N2
+*
+*
+* Definition des Branches
+*
+BRANCHE Br_B1 Nd_N1 Nd_N2 20
+*PROF St_PROF1 St_PROF2 St_PROF3
+PROF PCC1 PCC2
+DISTANCE 100.0 100.0
+CPOND 0.5 0.5
+CDIV 0.0 0.0
+CCONV 0.0 0.0
+RUIS 1.0
+* Coeff SINUO DPTG CRUE 10: 1.0. Ce coef vaut 'longeur Lit Mineur/Longueur Lit Majeur' avec Longueur Mineur= longueur branche
+SINUO 200.0 200.0
+*
+*
+* Definition des Frottements
+STRIREF FkSto_K0 0.0
+*
+STRIREFZ PCC1MAJ 0.00 10 50.00 15
+STRIREFZ PCC1MIN 0.00 10 50.00 15
+*
+STRIREFZ PCC2MAJ 0.00 10 50.00 15
+STRIREFZ PCC2MIN 0.00 10 50.00 15
+*
+*
+*
+* Definition des Profils
+*
+PROFIL PCC1
+LIMITEJ 1 1 1 4 4 4
+STRIC FkSto_K0 PCC1MAJ PCC1MIN PCC1MAJ FkSto_K0
+X/Z 0.00 30.00 0.01 17.15 5.35 17.15 5.36 30.00
+ACTIF 3
+LIT MINEUR 3
+*
+PROFIL PCC2
+LIMITEJ 1 1 2 3 4 4
+STRIC FkSto_K0 PCC2MAJ pcc2MIN PCC2MIN FkSto_K0
+X/Z 0.00 30.00 0.01 17.15 5.35 17.15 5.36 30.00
+ACTIF 3
+LIT MINEUR 3
+*
+* Avec FCv1.1, la conversion c9 de PCC2 donne le r\xE9sultat ci-dessous :
+*PROFIL St_PCC2
+*LIMITEJ 1 2 2 3 3 4
+*STRIC Fk_PCC2MAJ FkSto_K0 Fk_PCC2MIN FkSto_K0 Fk_PCC2MIN
+*X/Z 0.0 30.0 0.01 17.15 5.35 17.15
+*X/Z 5.36 30.0
+*ACTIF 2 3 4
+*LIT Lt_MajD 2
+*LIT Lt_MajG 4
+*LIT Lt_Mineur 3
+*LIT Lt_StoD 1
+*LIT Lt_StoG 5
+*
+* Elle devrait donner le r\xE9sultat ci-dessous, tout en produisant \xE0 chaque chargement des erreurs non bloquantes (frottements non-nuls sur des lits de stockage).
+* FCv1.1 d\xE9place tr\xE8s bizarrement les frottements et rend actives des portions du profil qui ne l'\xE9taient pas dans la d\xE9finition initiale de l'utilisateur, ce qu'il ne faut surtout pas faire.
+* Il faut en fait r\xE9soudre le probl\xE8me en ajoutant des lits vides dans le lit actif pour Lt_MajD et Lt_MajG.
+*PROFIL St_PCC2
+*LIMITEJ 1 1 2 2 3 3 4 4
+*STRIC FkSto_K0 Fk_PCC2MAJ Fk_PCC2MIN Fk_PCC2MIN Fk_PCC2MIN Fk_PCC2MAJ FkSto_K0
+*X/Z 0.0 30.0 0.01 17.15 5.35 17.15
+*X/Z 5.36 30.0
+*ACTIF 3 4 5
+*LIT Lt_MajD 3
+*LIT Lt_MajG 5
+*LIT Lt_Mineur 4
+*LIT Lt_StoD 1 2
+*LIT Lt_StoG 6 7
+*
+* Definition des Casiers
Added: trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dh
===================================================================
--- trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dh (rev 0)
+++ trunk/soft/fudaa-crue/crue-validation/src/test/resources/KiPlantePas_c9.dh 2014-06-10 22:27:20 UTC (rev 8762)
@@ -0,0 +1,38 @@
+*
+* Donnees generales
+*
+CrueX - Structuration des donn\xE9es
+
+Mod\xE8le de test utilisant les \xE9l\xE9ments de mod\xE9lisation hydraulique les plus courants
+
+NJB
+*
+SEUIL_FROUDE 1E+30 1.0
+COEFF_RELAX_DQ 1.0
+COEFF_RELAX_DZ 1.0
+NB_COURANT_MAX 1E+30 1E+30
+*
+* ical cru cofqrq isorti ile trepr
+1 0.0 0 1 1 0 0 0 0
+*
+* Debits initiaux dans les branches
+Br_B1 125.0
+FIN
+*
+* Niveaux initiaux aux noeuds
+Nd_N1 3.68 Nd_N2 3.67
+FIN
+*
+* Donnees pseudo-permanentes
+*
+* dtperm tolz tolq icalmx iprint ndecou
+0 1 0 0 0.0010 0.01 40 0 1
+*
+* Definition des types des conditions aux limites
+Nd_N1 2
+Nd_N2 1
+FIN
+*
+* Valeurs des conditions aux limites (regimes pseudo-permanents)
+125.0 3.5
+FIN
Modified: trunk/soft/fudaa-crue/ui-loader/src/main/java/org/fudaa/fudaa/crue/loader/ScenarioLoaderServiceAbstract.java
===================================================================
--- trunk/soft/fudaa-crue/ui-loader/src/main/java/org/fudaa/fudaa/crue/loader/ScenarioLoaderServiceAbstract.java 2014-06-09 21:22:31 UTC (rev 8761)
+++ trunk/soft/fudaa-crue/ui-loader/src/main/java/org/fudaa/fudaa/crue/loader/ScenarioLoaderServiceAbstract.java 2014-06-10 22:27:20 UTC (rev 8762)
@@ -103,7 +103,7 @@
EventQueue.invokeLater(new Runnable() {
@Override
public void run() {
- final EMHScenario result = load.getResult();
+ final EMHScenario result = load == null ? null : load.getResult();
if (result != null) {
service.activePerspective(perspectiveToActive);
unloadScenario();
Modified: trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/section/ProfilSectionLoiUiController.java
===================================================================
--- trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/section/ProfilSectionLoiUiController.java 2014-06-09 21:22:31 UTC (rev 8761)
+++ trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/section/ProfilSectionLoiUiController.java 2014-06-10 22:27:20 UTC (rev 8762)
@@ -361,6 +361,9 @@
int limiteIdx = 0;
model.getLoiLine(litNommes.get(0).getFirstIdx()).addEtiquette(etiquettesByLimites.get(limites.get(limiteIdx++)));
for (LitNommeIndexed litNommeIndexed : litNommes) {
+ if (litNommeIndexed.getLitNumerotesSize() == 0) {
+ continue;
+ }
int last = litNommeIndexed.getlastIdx();
ProfilSectionEtiquette litNommeEtiquette = etiquettesByLimites.get(limites.get(limiteIdx++));
model.getLoiLine(last).addEtiquette(litNommeEtiquette);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-06-26 21:21:36
|
Revision: 8780
http://sourceforge.net/p/fudaa/svn/8780
Author: deniger
Date: 2014-06-26 21:21:30 +0000 (Thu, 26 Jun 2014)
Log Message:
-----------
avancement OTFA
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml
trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/services/ModellingSaveScenarioCallable.java
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml 2014-06-25 21:48:36 UTC (rev 8779)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml 2014-06-26 21:21:30 UTC (rev 8780)
@@ -111,6 +111,7 @@
<file name="ReportVariableTopComponent.settings" url="ReportVariableTopComponentSettings.xml"/>
<file name="ReportViewManagerTopComponent.settings" url="ReportViewManagerTopComponentSettings.xml"/>
<file name="SysdocTopComponent.settings" url="SysdocTopComponentSettings.xml"/>
+ <file name="ScenariosTopComponent.settings" url="ScenariosTopComponentSettings.xml"/>
<file name="properties.settings_hidden"/>
</folder>
<folder name="Modes">
Modified: trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/services/ModellingSaveScenarioCallable.java
===================================================================
--- trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/services/ModellingSaveScenarioCallable.java 2014-06-25 21:48:36 UTC (rev 8779)
+++ trunk/soft/fudaa-crue/ui-modelling/src/main/java/org/fudaa/fudaa/crue/modelling/services/ModellingSaveScenarioCallable.java 2014-06-26 21:21:30 UTC (rev 8780)
@@ -59,9 +59,19 @@
return saveWithScenarioType;
}
CtuluLogGroup res = new CtuluLogGroup(BusinessMessages.RESOURCE_BUNDLE);
+ res.setDescription("save.scenario.log");
CtuluLog log = res.createNewLog("save.scenario.done");
Map<String, File> savedFiles = modellingScenarioServiceImpl.getSelectedProjet().getInputFiles(managerScenarioLoaded, dir);
Map<String, File> destFiles = modellingScenarioServiceImpl.getSelectedProjet().getInputFiles(managerScenarioLoaded);
+ for (File dest : destFiles.values()) {
+ String error = CtuluLibFile.canWrite(dest);
+ if (error != null) {
+ log.addSevereError(error);
+ }
+ }
+ if (log.containsSevereError()) {
+ return res;
+ }
for (Map.Entry<String, File> entry : savedFiles.entrySet()) {
String id = entry.getKey();
File savedFile = entry.getValue();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2014-06-26 22:11:50
|
Revision: 8781
http://sourceforge.net/p/fudaa/svn/8781
Author: deniger
Date: 2014-06-26 22:11:47 +0000 (Thu, 26 Jun 2014)
Log Message:
-----------
shortucts
Modified Paths:
--------------
trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr.properties
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-actions.jar/org/openide/actions/Bundle_fr.properties
trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml
trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/layer.xml
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr_FR.properties
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr.properties
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr_FR.properties
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle.properties
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle_fr_FR.properties
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/org/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/org/openide/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/org/openide/awt/
trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/org/openide/awt/Bundle_fr.properties
Modified: trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties
===================================================================
--- trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-06-26 21:21:30 UTC (rev 8780)
+++ trunk/soft/fudaa-crue/crue-core/src/main/resources/org/fudaa/dodico/crue/common/businessMessages.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -868,7 +868,8 @@
save.geoloc.done=Donn\u00e9es de g\u00e9olocalisation enregistr\u00e9es
save.configEtu.done=Configuration de niveau \u00e9tude enregistr\u00e9e
save.configEtuExtern.done=Configuration des ressources externes enregistr\u00e9e
-save.scenario.done=Sc\u00e9nario enregistr\u00e9
+save.scenario.done=Enregistrement du sc\u00e9nario
+save.scenario.log=Enregistrement
save.scenario.file.done=Fichier {0} enregistr\u00e9
valid.ptProfil.MinDelta.NotRespected={0}: l''\u00e9cart minimum entre 2 Xt successifs n''est pas respect\u00e9 \u00e0 l''indice {1}
io.profilSectionNotLinkedToSection.error=Les ProfilSections suivants ne sont pas attach\u00e9s \u00e0 une section: {0}
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr.properties 2014-06-26 21:21:30 UTC (rev 8780)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -5,7 +5,7 @@
CTL_CollapseTabGroupAction=Fermer l'onglet
CTL_MaximizeWindowAction=Maximi&ser
CTL_MinimizeModeAction=Minimi&ser Groupe
-CTL_MinimizeWindowAction=Minimis&er
+CTL_MinimizeWindowAction=Minimiser
CTL_MoveModeAction=&D\u00e9placer Groupe
CTL_MoveWindowAction=D\u00e9&placer
CTL_NewTabGroupAction=Nouveau groupe d'onglets de document
@@ -20,5 +20,6 @@
CTL_CloseWindowAction_MainMenu=Fermer le fen\u00eatre
LBL_ToggleWindowTransparencyAction=Fen\u00eatre transparente
LBL_WindowTransparencyHint=Maintenir la touche [Ctrl+clavier num\u00e9rique 0] pour rendre transparente une fen\u00eatre minimis\u00e9e
+CTL_CloseModeAction=Fermer le groupe
Added: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr_FR.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr_FR.properties (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-core-windows.jar/org/netbeans/core/windows/actions/Bundle_fr_FR.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -0,0 +1,2 @@
+CTL_MinimizeModeAction=Minimiser le groupe
+CTL_MinimizeWindowAction=Minimiser
Added: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr.properties (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -0,0 +1 @@
+MSG_MinimizeWindowAction=&Minimiser la fen\u00eatre
Added: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr_FR.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr_FR.properties (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-modules-applemenu.jar/org/netbeans/modules/applemenu/Bundle_fr_FR.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -0,0 +1 @@
+MSG_MinimizeWindowAction=&Minimiser la fen\u00eatre
Added: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle.properties (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -0,0 +1,2 @@
+Tip_Close_Window=Fermer la fen\u00eatre
+Tip_Close_Window_Group=Fermer le groupe de fen\u00eatre
Added: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle_fr_FR.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle_fr_FR.properties (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-netbeans-swing-tabcontrol.jar/org/netbeans/swing/tabcontrol/plaf/Bundle_fr_FR.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -0,0 +1,5 @@
+Tip_Close_Window=Fermer la fen\u00eatre
+Tip_Close_Window_Group=Fermer le groupe de fen\u00eatre
+Tip_Maximize_Window=maximiser la fen\u00eatre
+Tip_Minimize_Window=Minimiser la fen\u00eatre
+Tip_Minimize_Window_Group=Minimiser le groupe de fen\u00eatres
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-actions.jar/org/openide/actions/Bundle_fr.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-actions.jar/org/openide/actions/Bundle_fr.properties 2014-06-26 21:21:30 UTC (rev 8780)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-actions.jar/org/openide/actions/Bundle_fr.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -8,3 +8,4 @@
UndoSimple=&D\u00e9faire
CTL_Tools=Outils
CloseView=Fermer
+
Added: trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/org/openide/awt/Bundle_fr.properties
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/org/openide/awt/Bundle_fr.properties (rev 0)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/nbm-branding/modules/org-openide-awt.jar/org/openide/awt/Bundle_fr.properties 2014-06-26 22:11:47 UTC (rev 8781)
@@ -0,0 +1 @@
+Close=Fermer
Modified: trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml 2014-06-26 21:21:30 UTC (rev 8780)
+++ trunk/soft/fudaa-crue/ui-branding/src/main/resources/org/fudaa/fudaa/crue/branding/layer.xml 2014-06-26 22:11:47 UTC (rev 8781)
@@ -24,7 +24,19 @@
-->
<filesystem>
<folder name="Actions">
- <folder name="Window">
+ <folder name="Edit">
+ <file name="org-netbeans-core-ui-sysopen-SystemOpenAction.instance_hidden"/>
+ <file name="org-netbeans-modules-quicksearch-QuickSearchAction.instance_hidden"/>
+ <file name="org-openide-actions-GotoAction.instance_hidden"/>
+ </folder>
+ <folder name="Help">
+ <file name="master-help.xml_hidden"/>
+ <file name="org-netbeans-core-actions-AboutAction.instance_hidden"/>
+ <file name="org-netbeans-modules-javahelp-HelpAction.instance_hidden"/>
+ </folder>
+ <file name="Profile_hidden"/>
+ <file name="System_hidden"/>
+ <folder name="Window">
<file name="org-netbeans-core-windows-actions-CloneDocumentAction.instance_hidden"/>
<file name="org-netbeans-core-windows-actions-CloseAllButThisAction.instance_hidden"/>
<file name="org-netbeans-core-windows-actions-CloseAllDocumentsAction.instance_hidden"/>
@@ -90,7 +102,15 @@
</folder>
</folder>
</folder>
- <folder name="Shortcuts"/>
+ <folder name="Shortcuts">
+ <file name="AS-Y.shadow_hidden"/>
+ <file name="D-4.shadow_hidden"/>
+ <file name="D-I.shadow_hidden"/>
+ <file name="DOS-P.shadow_hidden"/>
+ <file name="DS-DELETE.shadow_hidden"/>
+ <file name="OS-D.shadow_hidden"/>
+ <file name="OS-ENTER.shadow_hidden"/>
+ </folder>
<folder name="Toolbars">
<file name="Standard.xml_hidden"/>
<file name="UndoRedo_hidden"/>
Modified: trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/layer.xml
===================================================================
--- trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/layer.xml 2014-06-26 21:21:30 UTC (rev 8780)
+++ trunk/soft/fudaa-crue/ui-otfa/src/main/resources/org/fudaa/fudaa/crue/otfa/layer.xml 2014-06-26 22:11:47 UTC (rev 8781)
@@ -1,7 +1,33 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE filesystem PUBLIC "-//NetBeans//DTD Filesystem 1.0//EN" "http://www.netbeans.org/dtds/filesystem-1_0.dtd">
<filesystem>
- <folder name="Menu">
+ <folder name="Actions">
+ <folder name="Edit">
+ <file name="org-netbeans-core-ui-options-filetypes-OpenAsAction.instance_hidden"/>
+ <file name="org-netbeans-core-ui-sysopen-SystemOpenAction.instance_hidden"/>
+ <file name="org-netbeans-modules-quicksearch-QuickSearchAction.instance_hidden"/>
+ <file name="org-openide-actions-GotoAction.instance_hidden"/>
+ <file name="org-openide-actions-RedoAction.instance_hidden"/>
+ <file name="org-openide-actions-ReplaceAction.instance_hidden"/>
+ <file name="org-openide-actions-UndoAction.instance_hidden"/>
+ </folder>
+ <folder name="File">
+ <file name="org-netbeans-modules-print-action-PageSetupAction.instance_hidden"/>
+ <file name="org-netbeans-modules-print-action-PrintAction.instance_hidden"/>
+ </folder>
+ <file name="Profile_hidden"/>
+ <file name="System_hidden"/>
+ <folder name="View">
+ <file name="org-netbeans-core-actions-LogAction.instance_hidden"/>
+ </folder>
+ <folder name="Window">
+ <file name="SelectDocumentNode_hidden"/>
+ <file name="org-netbeans-core-actions-NextViewCallbackAction.instance_hidden"/>
+ <file name="org-netbeans-core-windows-actions-CloneDocumentAction.instance_hidden"/>
+ <file name="org-netbeans-core-windows-actions-CloseAllButThisAction.instance_hidden"/>
+ </folder>
+ </folder>
+ <folder name="Menu">
<folder name="Window">
<folder name="OTFA">
<attr name="displayName" bundlevalue="org.fudaa.fudaa.crue.otfa.Bundle#Menu/OTFA"/>
@@ -9,7 +35,13 @@
</folder>
</folder>
</folder>
- <folder name="Shortcuts"/>
+ <folder name="Shortcuts">
+ <file name="AS-Y.shadow_hidden"/>
+ <file name="D-4.shadow_hidden"/>
+ <file name="D-I.shadow_hidden"/>
+ <file name="DOS-P.shadow_hidden"/>
+ <file name="DS-DELETE.shadow_hidden"/>
+ </folder>
<folder name="Toolbars">
<folder name="Perspective">
<file name="org-fudaa-fudaa-crue-otfa-perspective-ActiveOtfa.shadow">
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2015-09-10 14:41:13
|
Revision: 9164
http://sourceforge.net/p/fudaa/svn/9164
Author: deniger
Date: 2015-09-10 14:41:11 +0000 (Thu, 10 Sep 2015)
Log Message:
-----------
CRUE-657
Modified Paths:
--------------
trunk/soft/fudaa-crue/nb-configuration.xml
trunk/soft/fudaa-crue/pom.xml
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
Modified: trunk/soft/fudaa-crue/nb-configuration.xml
===================================================================
--- trunk/soft/fudaa-crue/nb-configuration.xml 2015-09-10 14:41:00 UTC (rev 9163)
+++ trunk/soft/fudaa-crue/nb-configuration.xml 2015-09-10 14:41:11 UTC (rev 9164)
@@ -12,4 +12,13 @@
<configuration id="release" profiles="release"/>
</configurations>
</config-data>
+ <properties xmlns="http://www.netbeans.org/ns/maven-properties-data/1">
+ <!--
+Properties that influence various parts of the IDE, especially code formatting and the like.
+You can copy and paste the single properties, into the pom.xml file and the IDE will pick them up.
+That way multiple projects can share the same settings (useful for formatting rules for example).
+Any value defined here will override the pom.xml file value but is only applicable to the current project.
+-->
+ <netbeans.hint.jdkPlatform>JDK_1.7</netbeans.hint.jdkPlatform>
+ </properties>
</project-shared-configuration>
Modified: trunk/soft/fudaa-crue/pom.xml
===================================================================
--- trunk/soft/fudaa-crue/pom.xml 2015-09-10 14:41:00 UTC (rev 9163)
+++ trunk/soft/fudaa-crue/pom.xml 2015-09-10 14:41:11 UTC (rev 9164)
@@ -20,7 +20,7 @@
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<javaCompiler>1.7</javaCompiler>
<targetJdk>1.7</targetJdk>
- <fudaa-sig.version>1.5</fudaa-sig.version>
+ <fudaa-sig.version>1.7-SNAPSHOT</fudaa-sig.version>
<netbeans.run.params.ide />
<netbeans.run.params>${netbeans.run.params.ide}</netbeans.run.params>
<!--<netbeans.version>RELEASE731</netbeans.version>-->
Modified: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2015-09-10 14:41:00 UTC (rev 9163)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2015-09-10 14:41:11 UTC (rev 9164)
@@ -1,5 +1,6 @@
package org.fudaa.fudaa.crue.common;
+import com.jidesoft.plaf.UIDefaultsLookup;
import com.memoire.bu.BuResource;
import java.awt.BorderLayout;
import java.awt.Color;
@@ -11,6 +12,8 @@
import javax.swing.JDialog;
import javax.swing.JLabel;
import javax.swing.JPanel;
+import javax.swing.UIManager;
+import org.fudaa.ebli.commun.EbliComponentFactory;
import org.fudaa.ebli.palette.BPalettePlage;
import static org.fudaa.fudaa.crue.common.Bundle.*;
import org.fudaa.fudaa.crue.common.editor.CustomColorChooser;
@@ -21,7 +24,6 @@
import org.fudaa.fudaa.crue.common.services.PerspectiveService;
import org.fudaa.fudaa.crue.common.services.SelectedPerspectiveService;
import org.openide.modules.ModuleInstall;
-import org.openide.nodes.NodeOp;
import org.openide.util.Lookup;
import org.openide.util.Lookup.Item;
import org.openide.util.NbBundle.Messages;
@@ -89,6 +91,10 @@
@Override
public void run() {
+ UIManager.put("ToggleButton.select", Color.RED);
+ UIManager.put("ToggleButton.focus", Color.RED);
+ UIManager.put("ToggleButton.highlight", Color.RED);
+ EbliComponentFactory.INSTANCE.setUseSelectedIcon(UIDefaultsLookup.getColor("JideButton.highlight"));
DurationPropertyEditor.registerEditor();
LocalDateTimeEditor.registerEditor();
PrendreClicheFinPermanentEditor.registerAllClicheEditors();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <de...@us...> - 2015-09-10 16:57:19
|
Revision: 9166
http://sourceforge.net/p/fudaa/svn/9166
Author: deniger
Date: 2015-09-10 16:57:17 +0000 (Thu, 10 Sep 2015)
Log Message:
-----------
CRUE-657
Modified Paths:
--------------
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/common/LoiDefaultCourbeModel.java
Added Paths:
-----------
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/CrueBasicComponentFactory.java
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JidePaletteButton.java
trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JideToolButton.java
Modified: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2015-09-10 16:56:03 UTC (rev 9165)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/InitPerspectiveInstaller.java 2015-09-10 16:57:17 UTC (rev 9166)
@@ -1,6 +1,5 @@
package org.fudaa.fudaa.crue.common;
-import com.jidesoft.plaf.UIDefaultsLookup;
import com.memoire.bu.BuResource;
import java.awt.BorderLayout;
import java.awt.Color;
@@ -23,6 +22,7 @@
import org.fudaa.fudaa.crue.common.pdt.PrendreClicheFinPermanentEditor;
import org.fudaa.fudaa.crue.common.services.PerspectiveService;
import org.fudaa.fudaa.crue.common.services.SelectedPerspectiveService;
+import org.fudaa.fudaa.crue.common.swing.CrueBasicComponentFactory;
import org.openide.modules.ModuleInstall;
import org.openide.util.Lookup;
import org.openide.util.Lookup.Item;
@@ -33,31 +33,31 @@
import org.openide.windows.WindowManager;
public class InitPerspectiveInstaller extends ModuleInstall implements Runnable {
-
+
@Override
protected void initialize() {
BuResource.BU.setIconFamily("crystal");
BPalettePlage.setDisplayReversed();
WindowManager.getDefault().invokeWhenUIReady(this);
}
-
+
@Override
public void validate() throws IllegalStateException {
super.validate();
}
-
+
@Override
public void restored() {
BuResource.BU.setIconFamily("crystal");
BPalettePlage.setDisplayReversed();
-
+
WindowManager.getDefault().invokeWhenUIReady(this);
}
-
+
@Override
@Messages("FudaaCrueClosing.Label=Fudaa-Crue est en cours de fermeture...")
public boolean closing() {
-
+
SelectedPerspectiveService selectedPerspectiveService = Lookup.getDefault().lookup(SelectedPerspectiveService.class);
boolean closing = true;
if (selectedPerspectiveService.getCurrentPerspectiveService() != null) {
@@ -72,7 +72,7 @@
if (perspectiveService != null) {
closing = perspectiveService.closing();
}
-
+
JDialog d = new JDialog();
JLabel jLabel = new JLabel(FudaaCrueClosing_Label());
d.setTitle(jLabel.getText());
@@ -88,13 +88,13 @@
}
return closing;
}
-
+
@Override
public void run() {
UIManager.put("ToggleButton.select", Color.RED);
UIManager.put("ToggleButton.focus", Color.RED);
UIManager.put("ToggleButton.highlight", Color.RED);
- EbliComponentFactory.INSTANCE.setUseSelectedIcon(UIDefaultsLookup.getColor("JideButton.highlight"));
+ EbliComponentFactory.INSTANCE.setComponentFactory(new CrueBasicComponentFactory());
DurationPropertyEditor.registerEditor();
LocalDateTimeEditor.registerEditor();
PrendreClicheFinPermanentEditor.registerAllClicheEditors();
Added: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/CrueBasicComponentFactory.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/CrueBasicComponentFactory.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/CrueBasicComponentFactory.java 2015-09-10 16:57:17 UTC (rev 9166)
@@ -0,0 +1,51 @@
+/*
+ GPL 2
+ */
+package org.fudaa.fudaa.crue.common.swing;
+
+import com.jidesoft.swing.JideButton;
+import com.jidesoft.swing.JideMenu;
+import com.jidesoft.swing.JideToggleButton;
+import javax.swing.AbstractButton;
+import javax.swing.JMenuItem;
+import org.fudaa.ebli.commun.EbliActionPaletteAbstract;
+import org.fudaa.ebli.commun.EbliActionSimple;
+import org.fudaa.ebli.commun.EbliBasicComponentFactory;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class CrueBasicComponentFactory extends EbliBasicComponentFactory {
+
+ @Override
+ public AbstractButton createToolToggleButton() {
+ final JideToggleButton jideToggleButton = new JideToggleButton();
+ jideToggleButton.setButtonStyle(JideButton.TOOLBAR_STYLE);
+ return jideToggleButton;
+ }
+
+ @Override
+ public AbstractButton createToggleButton() {
+ return new JideToggleButton();
+ }
+
+
+ @Override
+ public AbstractButton createToolButton(EbliActionSimple _a) {
+ JideButton button = new JideToolButton(_a);
+ return button;
+ }
+
+ @Override
+ public AbstractButton createButton() {
+ return new JideButton();
+ }
+
+
+ @Override
+ public AbstractButton createPaletteButton(EbliActionPaletteAbstract _a) {
+ return new JidePaletteButton(_a);
+ }
+
+}
Added: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JidePaletteButton.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JidePaletteButton.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JidePaletteButton.java 2015-09-10 16:57:17 UTC (rev 9166)
@@ -0,0 +1,37 @@
+/*
+ GPL 2
+ */
+package org.fudaa.fudaa.crue.common.swing;
+
+import com.jidesoft.swing.JideToggleButton;
+import com.memoire.bu.BuDesktop;
+import org.fudaa.ebli.commun.EbliActionPaletteAbstract;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class JidePaletteButton extends JideToggleButton {
+
+ EbliActionPaletteAbstract ac_;
+
+ /**
+ *
+ */
+ public JidePaletteButton(final EbliActionPaletteAbstract _ac) {
+ ac_ = _ac;
+ }
+
+ @Override
+ public final void setVisible(final boolean _b) {
+ if (_b != isVisible()) {
+ ac_.setMainButtonVisible(_b);
+ super.setVisible(_b);
+ }
+
+ }
+
+ public void setDesktop(final BuDesktop _d) {
+ ac_.setDesktop(_d);
+ }
+}
Added: trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JideToolButton.java
===================================================================
--- trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JideToolButton.java (rev 0)
+++ trunk/soft/fudaa-crue/ui-common/src/main/java/org/fudaa/fudaa/crue/common/swing/JideToolButton.java 2015-09-10 16:57:17 UTC (rev 9166)
@@ -0,0 +1,60 @@
+/*
+ GPL 2
+ */
+package org.fudaa.fudaa.crue.common.swing;
+
+import com.jidesoft.swing.JideButton;
+import java.awt.event.KeyEvent;
+import javax.swing.Action;
+import javax.swing.KeyStroke;
+import javax.swing.SwingUtilities;
+import javax.swing.UIManager;
+import org.fudaa.ebli.commun.EbliActionInterface;
+
+/**
+ *
+ * @author Frederic Deniger
+ */
+public class JideToolButton extends JideButton {
+
+ KeyStroke key_;
+
+ public JideToolButton(final EbliActionInterface _action) {
+ super(null, null);
+ setAction(_action);
+ setFocusable(true);
+ setButtonStyle(JideButton.TOOLBAR_STYLE);
+ key_ = (KeyStroke) _action.getValue(Action.ACCELERATOR_KEY);
+ if (key_ != null) {
+ final KeyStroke accelerator = key_;
+ final String acceleratorDelimiter
+ = UIManager.getString("MenuItem.acceleratorDelimiter");
+ String acceleratorText = "";
+ if (accelerator != null) {
+ final int modifiers = accelerator.getModifiers();
+ if (modifiers > 0) {
+ acceleratorText = KeyEvent.getKeyModifiersText(modifiers);
+ //acceleratorText += "-";
+ acceleratorText += acceleratorDelimiter;
+ }
+
+ final int keyCode = accelerator.getKeyCode();
+ if (keyCode == 0) {
+ acceleratorText += accelerator.getKeyChar();
+ } else {
+ acceleratorText += KeyEvent.getKeyText(keyCode);
+ }
+ }
+ setToolTipText(super.getToolTipText() + " " + acceleratorText);
+ }
+ }
+
+ @Override
+ protected boolean processKeyBinding(final KeyStroke _ks, final KeyEvent _e, final int _condition, final boolean _pressed) {
+ if (isEnabled() && key_ != null && key_.equals(_ks)) {
+ return SwingUtilities.notifyAction(getAction(), _ks, _e, this, _e.getModifiers());
+ }
+ return super.processKeyBinding(_ks, _e, _condition, _pressed);
+ }
+
+}
Modified: trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/common/LoiDefaultCourbeModel.java
===================================================================
--- trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/common/LoiDefaultCourbeModel.java 2015-09-10 16:56:03 UTC (rev 9165)
+++ trunk/soft/fudaa-crue/ui-loi/src/main/java/org/fudaa/fudaa/crue/loi/common/LoiDefaultCourbeModel.java 2015-09-10 16:57:17 UTC (rev 9166)
@@ -204,7 +204,6 @@
@Override
public void fillWithInfo(InfoData _table, CtuluListSelectionInterface _selectedPt) {
- throw new UnsupportedOperationException("Not supported yet.");
}
@Override
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|