Author: tchemit Date: 2012-08-03 16:54:11 +0200 (Fri, 03 Aug 2012) New Revision: 355 Url: http://forge.codelutin.com/repositories/revision/sammoa/355 Log: add missing svn properties + file headers remove obsolete methods refs #1203: Export SHP (changing campaign refresh species + speciesType list) Added: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/Species2.java Removed: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/SpeciesDAOImpl.java Modified: trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/ReferentialService.java trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapModel.java trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapService.java trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/RouteType.java trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRef.java trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRefs.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.css trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.jaxx trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.css trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.jaxx trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIHandler.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIModel.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanel.css trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanelHandler.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ForceSelectionSelectionModel.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ObservationTableModel.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/RouteTableModel.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextEditableCellAction.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextRowEditableAction.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousEditableCellAction.java trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousRowEditableAction.java trunk/sammoa-ui-swing/src/main/resources/icons/action-accept.png trunk/sammoa-ui-swing/src/main/resources/icons/action-cancel.png trunk/sammoa-ui-swing/src/main/resources/icons/action-fileChooser.png trunk/sammoa-ui-swing/src/test/resources/logback-test.xml trunk/src/site/resources/ulr-sammoa-echange-data.svg Modified: trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/ReferentialService.java =================================================================== --- trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/ReferentialService.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/ReferentialService.java 2012-08-03 14:54:11 UTC (rev 355) @@ -615,25 +615,6 @@ return result; } - public List<String> getAllSpeciesTypes() { - TopiaContext tx = persistence.beginTransaction(); - try { - - List<String> result = - SammoaDAOHelper.getSpeciesDAO(tx).findAllSpeciesTypes(); - - Collections.sort(result); - - return result; - } catch (TopiaException e) { - throw new TopiaRuntimeException(e); - - } finally { - persistence.endTransaction(tx); - } - - } - public List<Species> getAllSpecies() { TopiaContext tx = persistence.beginTransaction(); try { Modified: trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapModel.java =================================================================== --- trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapModel.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapModel.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.application.map; +/* + * #%L + * SAMMOA :: Application + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import com.google.common.collect.Lists; import fr.ulr.sammoa.persistence.Campaign; Property changes on: trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapModel.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapService.java =================================================================== --- trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapService.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapService.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.application.map; +/* + * #%L + * SAMMOA :: Application + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import fr.ulr.sammoa.application.SammoaConfig; import fr.ulr.sammoa.application.SammoaContext; Property changes on: trunk/sammoa-application/src/main/java/fr/ulr/sammoa/application/map/ExportMapService.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/RouteType.java =================================================================== --- trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/RouteType.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/RouteType.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.persistence; +/* + * #%L + * SAMMOA :: Persistence + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ public enum RouteType { TRANSIT, Property changes on: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/RouteType.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Added: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/Species2.java =================================================================== --- trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/Species2.java (rev 0) +++ trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/Species2.java 2012-08-03 14:54:11 UTC (rev 355) @@ -0,0 +1,52 @@ +package fr.ulr.sammoa.persistence; +/* + * #%L + * SAMMOA :: Persistence + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ + +import com.google.common.collect.Lists; +import com.google.common.collect.Sets; + +import java.util.Collection; +import java.util.List; +import java.util.Set; + +/** + * Useful methods around {@link Species}. + * + * @author tchemit <chemit@codelutin.com> + * @since 0.5 + */ +public class Species2 { + + private Species2() { + // no instance on util class + } + + public static List<String> toSpeciesTypes(Collection<Species> species) { + Set<String> types = Sets.newHashSet(); + for (Species specy : species) { + types.add(specy.getType()); + } + return Lists.newArrayList(types); + } +} Property changes on: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/Species2.java ___________________________________________________________________ Added: svn:keywords + Author Date Id Revision HeadURL Added: svn:eol-style + native Deleted: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/SpeciesDAOImpl.java =================================================================== --- trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/SpeciesDAOImpl.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/SpeciesDAOImpl.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,21 +0,0 @@ -package fr.ulr.sammoa.persistence; - -import com.google.common.collect.Lists; -import com.google.common.collect.Sets; -import org.nuiton.topia.TopiaException; - -import java.util.List; -import java.util.Set; - -public class SpeciesDAOImpl<E extends Species> extends SpeciesDAOAbstract<E> { - - public List<String> findAllSpeciesTypes() throws TopiaException { - Set<String> result = Sets.newHashSet(); - List<E> all = findAll(); - for (E e : all) { - result.add(e.getType()); - } - return Lists.newArrayList(result); - } - -} //SpeciesDAOImpl<E extends Species> Modified: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRef.java =================================================================== --- trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRef.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRef.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.persistence; +/* + * #%L + * SAMMOA :: Persistence + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import java.io.Serializable; Property changes on: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRef.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRefs.java =================================================================== --- trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRefs.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRefs.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.persistence; +/* + * #%L + * SAMMOA :: Persistence + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import com.google.common.base.Function; import com.google.common.collect.Iterables; Property changes on: trunk/sammoa-persistence/src/main/java/fr/ulr/sammoa/persistence/StringRefs.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.css =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.css 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.css 2012-08-03 14:54:11 UTC (rev 355) @@ -1,3 +1,26 @@ +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ #exportMapDirectoryFileChooseAction { actionIcon:"fileChooser"; } Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.css ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.jaxx =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.jaxx 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.jaxx 2012-08-03 14:54:11 UTC (rev 355) @@ -1,3 +1,26 @@ +<!-- + #%L + SAMMOA :: UI Swing + $Id$ + $HeadURL$ + %% + Copyright (C) 2012 UMS 3462, Code Lutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public + License along with this program. If not, see + <http://www.gnu.org/licenses/gpl-3.0.html>. + #L% + --> <JPanel layout='{new BorderLayout()}'> <import> Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapLauncherUI.jaxx ___________________________________________________________________ Added: svn:keywords + Author Date Id Revision HeadURL Added: svn:eol-style + native Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.css =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.css 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.css 2012-08-03 14:54:11 UTC (rev 355) @@ -1,3 +1,26 @@ +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ BeanListHeader { i18nPrefix: "sammoa.common."; } Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.css ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.jaxx =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.jaxx 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.jaxx 2012-08-03 14:54:11 UTC (rev 355) @@ -1,3 +1,26 @@ +<!-- + #%L + SAMMOA :: UI Swing + $Id$ + $HeadURL$ + %% + Copyright (C) 2012 UMS 3462, Code Lutin + %% + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as + published by the Free Software Foundation, either version 3 of the + License, or (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public + License along with this program. If not, see + <http://www.gnu.org/licenses/gpl-3.0.html>. + #L% + --> <JPanel id='exportMapUI' layout='{new BorderLayout()}' implements='fr.ulr.sammoa.ui.swing.SammoaUI<ExportMapUIHandler>'> Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUI.jaxx ___________________________________________________________________ Added: svn:keywords + Author Date Id Revision HeadURL Added: svn:eol-style + native Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIHandler.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIHandler.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIHandler.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.ui.swing.io.exportMap; +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import com.google.common.base.Preconditions; import com.google.common.collect.Lists; @@ -8,7 +31,9 @@ import fr.ulr.sammoa.persistence.Campaign; import fr.ulr.sammoa.persistence.RouteType; import fr.ulr.sammoa.persistence.Species; +import fr.ulr.sammoa.persistence.Species2; import fr.ulr.sammoa.persistence.Strate; +import fr.ulr.sammoa.persistence.StringRef; import fr.ulr.sammoa.persistence.StringRefs; import fr.ulr.sammoa.ui.swing.SammoaDecoratorProvider; import fr.ulr.sammoa.ui.swing.SammoaUIContext; @@ -84,12 +109,12 @@ campaigns.add(0, null); model.setCampaigns(campaigns); - List<String> speciesTypes = getReferentialService().getAllSpeciesTypes(); - model.setSpeciesTypes(StringRefs.toRefs(speciesTypes)); +// List<String> speciesTypes = getReferentialService().getAllSpeciesTypes(); +// model.setSpeciesTypes(StringRefs.toRefs(speciesTypes)); +// +// List<Species> species = getReferentialService().getAllSpecies(); +// model.setSpecies(species); - List<Species> species = getReferentialService().getAllSpecies(); - model.setSpecies(species); - model.setRouteTypes(Lists.newArrayList(RouteType.values())); String campaignId = context.getCampaignId(); @@ -114,9 +139,14 @@ Campaign newValue = (Campaign) evt.getNewValue(); onSelectedCampaignChanged(newValue); } else if (ExportMapUIModel.PROPERTY_STRATES.equals(evt.getPropertyName())) { - List<Strate> newValue = (List<Strate>) evt.getNewValue(); onStratesChanged(newValue); + } else if (ExportMapUIModel.PROPERTY_SPECIES.equals(evt.getPropertyName())) { + List<Species> newValue = (List<Species>) evt.getNewValue(); + onSpeciesChanged(newValue); + } else if (ExportMapUIModel.PROPERTY_SPECIES_TYPES.equals(evt.getPropertyName())) { + List<StringRef> newValue = (List<StringRef>) evt.getNewValue(); + onSpeciesTypesChanged(newValue); } } }); @@ -159,6 +189,20 @@ ui.getStrateFilterListHeader().setData(newValue); } + protected void onSpeciesChanged(List<Species> newValue) { + if (logger.isInfoEnabled()) { + logger.info("New species to use: {}", newValue.size()); + } + ui.getSpeciesFilterListHeader().setData(newValue); + } + + protected void onSpeciesTypesChanged(List<StringRef> newValue) { + if (logger.isInfoEnabled()) { + logger.info("New species types to use: {}", newValue.size()); + } + ui.getSpeciesTypeFilterListHeader().setData(newValue); + } + protected void onSelectedCampaignChanged(Campaign newCampaign) { // reset strates,... @@ -170,6 +214,8 @@ ExportMapUIModel model = ui.getModel(); model.setSelectedStrates(Collections.<Strate>emptyList()); + model.setSelectedSpecies(Collections.<Species>emptyList()); + model.setSelectedSpeciesTypes(Collections.<StringRef>emptyList()); List<Strate> strates; if (newCampaign == null) { @@ -181,6 +227,20 @@ logger.debug("New strates: {}", strates.size()); } model.setStrates(strates); + + List<Species> species; + List<StringRef> speciesTypes; + + if (newCampaign == null) { + species = Collections.emptyList(); + speciesTypes = Collections.emptyList(); + + } else { + species = getReferentialService().getAllSpecies(newCampaign); + speciesTypes = StringRefs.toRefs(Species2.toSpeciesTypes(species)); + } + model.setSpecies(species); + model.setSpeciesTypes(speciesTypes); } public void close() { Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIHandler.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIModel.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIModel.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIModel.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.ui.swing.io.exportMap; +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import com.google.common.collect.Lists; import fr.ulr.sammoa.application.map.ExportMapModel; Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/io/exportMap/ExportMapUIModel.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanel.css =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanel.css 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanel.css 2012-08-03 14:54:11 UTC (rev 355) @@ -2,7 +2,7 @@ * #%L * SAMMOA :: UI Swing * $Id$ - * $HeadURL:$ + * $HeadURL$ * %% * Copyright (C) 2012 UMS 3462, Code Lutin * %% Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanel.css ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanelHandler.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanelHandler.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanelHandler.java 2012-08-03 14:54:11 UTC (rev 355) @@ -3,7 +3,7 @@ * #%L * SAMMOA :: UI Swing * $Id$ - * $HeadURL:$ + * $HeadURL$ * %% * Copyright (C) 2012 UMS 3462, Code Lutin * %% Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/EffortPanelHandler.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ForceSelectionSelectionModel.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ForceSelectionSelectionModel.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ForceSelectionSelectionModel.java 2012-08-03 14:54:11 UTC (rev 355) @@ -3,7 +3,7 @@ * SAMMOA :: UI Swing * * $Id$ - * $HeadURL: http://svn.forge.codelutin.com/svn/sammoa/trunk/sammoa-ui-swing/src/main/jav... $ + * $HeadURL$ * %% * Copyright (C) 2012 UMS 3462, Code Lutin * %% Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ForceSelectionSelectionModel.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ObservationTableModel.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ObservationTableModel.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ObservationTableModel.java 2012-08-03 14:54:11 UTC (rev 355) @@ -3,7 +3,7 @@ * SAMMOA :: UI Swing * * * $Id$ - * $HeadURL: http://svn.forge.codelutin.com/svn/sammoa/trunk/sammoa-ui-swing/src/main/jav... $ + * $HeadURL$ * %% * Copyright (C) 2012 UMS 3462, Code Lutin * %% Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/ObservationTableModel.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/RouteTableModel.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/RouteTableModel.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/RouteTableModel.java 2012-08-03 14:54:11 UTC (rev 355) @@ -3,7 +3,7 @@ * SAMMOA :: UI Swing * * * $Id$ - * $HeadURL: http://svn.forge.codelutin.com/svn/sammoa/trunk/sammoa-ui-swing/src/main/jav... $ + * $HeadURL$ * %% * Copyright (C) 2012 UMS 3462, Code Lutin * %% Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/RouteTableModel.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextEditableCellAction.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextEditableCellAction.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextEditableCellAction.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.ui.swing.observations.action; +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import org.slf4j.Logger; import org.slf4j.LoggerFactory; Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextEditableCellAction.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextRowEditableAction.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextRowEditableAction.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextRowEditableAction.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.ui.swing.observations.action; +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import org.slf4j.Logger; import org.slf4j.LoggerFactory; Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToNextRowEditableAction.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousEditableCellAction.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousEditableCellAction.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousEditableCellAction.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.ui.swing.observations.action; +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import org.slf4j.Logger; import org.slf4j.LoggerFactory; Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousEditableCellAction.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousRowEditableAction.java =================================================================== --- trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousRowEditableAction.java 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousRowEditableAction.java 2012-08-03 14:54:11 UTC (rev 355) @@ -1,4 +1,27 @@ package fr.ulr.sammoa.ui.swing.observations.action; +/* + * #%L + * SAMMOA :: UI Swing + * $Id$ + * $HeadURL$ + * %% + * Copyright (C) 2012 UMS 3462, Code Lutin + * %% + * This program is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as + * published by the Free Software Foundation, either version 3 of the + * License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public + * License along with this program. If not, see + * <http://www.gnu.org/licenses/gpl-3.0.html>. + * #L% + */ import org.slf4j.Logger; import org.slf4j.LoggerFactory; Property changes on: trunk/sammoa-ui-swing/src/main/java/fr/ulr/sammoa/ui/swing/observations/action/MoveToPreviousRowEditableAction.java ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Property changes on: trunk/sammoa-ui-swing/src/main/resources/icons/action-accept.png ___________________________________________________________________ Added: svn:keywords + Author Date Id Revision HeadURL Property changes on: trunk/sammoa-ui-swing/src/main/resources/icons/action-cancel.png ___________________________________________________________________ Added: svn:keywords + Author Date Id Revision HeadURL Property changes on: trunk/sammoa-ui-swing/src/main/resources/icons/action-fileChooser.png ___________________________________________________________________ Added: svn:keywords + Author Date Id Revision HeadURL Modified: trunk/sammoa-ui-swing/src/test/resources/logback-test.xml =================================================================== --- trunk/sammoa-ui-swing/src/test/resources/logback-test.xml 2012-08-03 14:28:31 UTC (rev 354) +++ trunk/sammoa-ui-swing/src/test/resources/logback-test.xml 2012-08-03 14:54:11 UTC (rev 355) @@ -4,7 +4,7 @@ SAMMOA :: Application $Id$ - $HeadURL: http://svn.forge.codelutin.com/svn/sammoa/trunk/sammoa-ui-swing/src/main/res... $ + $HeadURL$ %% Copyright (C) 2012 UMS 3462, Code Lutin %% Property changes on: trunk/sammoa-ui-swing/src/test/resources/logback-test.xml ___________________________________________________________________ Modified: svn:keywords - Author Date Id Revision + Author Date Id Revision HeadURL Property changes on: trunk/src/site/resources/ulr-sammoa-echange-data.svg ___________________________________________________________________ Added: svn:keywords + Author Date Id Revision HeadURL