|
From: <de...@us...> - 2010-06-10 21:39:22
|
Revision: 5764
http://fudaa.svn.sourceforge.net/fudaa/?rev=5764&view=rev
Author: deniger
Date: 2010-06-10 21:39:15 +0000 (Thu, 10 Jun 2010)
Log Message:
-----------
Modified Paths:
--------------
trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/TrLauncherDefault.java
trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/actions/TrPostActionController.java
trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreatedExpr.java
trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreationPanel.java
trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostPersistenceManager.java
trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostSourceProjectedPersistReplay.java
trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/rubar/TrRubarDonneesBrutesLayer.java
trunk/soft/fudaa-prepro/ui/src/main/resources/org/fudaa/fudaa/tr/common/tr_en.fr_txt
Modified: trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/TrLauncherDefault.java
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/TrLauncherDefault.java 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/TrLauncherDefault.java 2010-06-10 21:39:15 UTC (rev 5764)
@@ -111,8 +111,8 @@
infoSoft = new BuInformationsSoftware();
infoSoft.name = "prepro";
- infoSoft.version = "1.1RC4";
- infoSoft.date = "2010-06-01";
+ infoSoft.version = "1.1RC6";
+ infoSoft.date = "2010-06-10";
// infoSoft.version = "1.00";
// infoSoft.date = "2010-01-27";
infoSoft.rights = TrResource.getS("Tous droits r\xE9serv\xE9s") + ". CETMEF (c)2003-2009";
Modified: trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/actions/TrPostActionController.java
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/actions/TrPostActionController.java 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/actions/TrPostActionController.java 2010-06-10 21:39:15 UTC (rev 5764)
@@ -1,6 +1,5 @@
/**
- * Licence GPL
- * Copyright Genesis
+ * Licence GPL Copyright Genesis
*/
package org.fudaa.fudaa.tr.post.actions;
@@ -12,11 +11,13 @@
import java.util.Map;
import javax.swing.Action;
+import javax.swing.JComponent;
+import javax.swing.JTabbedPane;
+import javax.swing.SwingUtilities;
import org.fudaa.ctulu.CtuluUI;
import org.fudaa.ebli.commun.EbliActionInterface;
import org.fudaa.ebli.commun.EbliActionPaletteAbstract;
-import org.fudaa.ebli.palette.BPaletteInfo;
import org.fudaa.fudaa.sig.layer.FSigVisuPanel;
import org.fudaa.fudaa.sig.layer.FSigVisuPanelController;
@@ -34,7 +35,7 @@
Map<String, EbliActionPaletteAbstract> mapTabPalettes_ = new HashMap<String, EbliActionPaletteAbstract>(2);
Collection<EbliActionPaletteAbstract> tabPalettes_ = null;
- Collection<String> useAsPalette = Arrays.asList("CONFIGURE", "CHANGE_REFERENCE","GLOBAL_MOVE","GLOBAL_ROTATE");
+ Collection<String> useAsPalette = Arrays.asList("CONFIGURE", "CHANGE_REFERENCE", "GLOBAL_MOVE", "GLOBAL_ROTATE");
Collection<String> useAsTab = Arrays.asList("INFOS", "PALETTE_EDTION", "NAVIGATE");
@@ -89,22 +90,30 @@
return tabPalettes_;
}
- public BPaletteInfo getPaletteInfoModel() {
- return ((BPaletteInfo) mapTabPalettes_.get("INFOS").buildContentPane());
- }
@Override
public FSigVisuPanel getVisuPanel() {
return super.getVisuPanel();
}
+ public final void setInfoPaletteActive() {
+ JComponent paletteContent = mapTabPalettes_.get("INFOS").getPaletteContent();
+ if (paletteContent != null) {
+ JTabbedPane parent = (JTabbedPane) SwingUtilities.getAncestorOfClass(JTabbedPane.class, paletteContent);
+ if (parent != null) {
+ parent.setSelectedComponent(paletteContent);
+ }
+ }
+
+ }
+
@Override
protected EbliActionInterface[] getApplicationActions() {
return removePalettes(pn_.getApplicationActions());
}
-
- private List<EbliActionPaletteAbstract> toHide=new ArrayList<EbliActionPaletteAbstract>();
+ private List<EbliActionPaletteAbstract> toHide = new ArrayList<EbliActionPaletteAbstract>();
+
/**
* @param actions les actions a trier
* @return la listes des actions a ajouter dans les menus et autres. Les autres ( les palettes) seront visible tout le
@@ -119,9 +128,9 @@
if (action == null) continue;
final String value = (String) action.getValue(Action.ACTION_COMMAND_KEY);
final boolean isPalette = action instanceof EbliActionPaletteAbstract;
- if("GLOBAL_MOVE".equals(value)||"GLOBAL_ROTATE".equals(value)){
- if(toHide.add((EbliActionPaletteAbstract) action));
- ((EbliActionPaletteAbstract)action).setDialogIsModal(false);
+ if ("GLOBAL_MOVE".equals(value) || "GLOBAL_ROTATE".equals(value)) {
+ if (toHide.add((EbliActionPaletteAbstract) action)) ;
+ ((EbliActionPaletteAbstract) action).setDialogIsModal(false);
action.updateStateBeforeShow();
}
if (!isPalette || useAsPalette.contains(value)) {
@@ -129,6 +138,7 @@
}
if (isPalette && useAsTab.contains(value)) {
mapTabPalettes_.put(value, (EbliActionPaletteAbstract) action);
+ ((EbliActionPaletteAbstract) action).setUsedAsTab(true);
}
}
return acts.toArray(new EbliActionInterface[acts.size()]);
@@ -137,9 +147,9 @@
public void editStop() {
for (EbliActionPaletteAbstract action : toHide) {
action.setSelected(false);
-
+
}
-
+
}
}
Modified: trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreatedExpr.java
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreatedExpr.java 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreatedExpr.java 2010-06-10 21:39:15 UTC (rev 5764)
@@ -115,7 +115,7 @@
}
public EfData getDataFor(final int _idxTime) {
- final double[] res = new double[src_.isRubar() ? src_.getGrid().getEltNb() : src_.getGrid().getPtsNb()];
+ final double[] res = new double[src_.containsOnlyElementVar() ? src_.getGrid().getEltNb() : src_.getGrid().getPtsNb()];
final EfData[] ds = new EfData[usedVar_.length];
// on enregistre les donnees pour chaque variable necessaire.
for (int i = usedVar_.length - 1; i >= 0; i--) {
@@ -128,7 +128,7 @@
}
res[i] = expr_.getValue();
}
- return src_.isRubar() ? (EfData) new EfDataElement(res) : new EfDataNode(res);
+ return src_.containsOnlyElementVar() ? (EfData) new EfDataElement(res) : new EfDataNode(res);
}
Modified: trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreationPanel.java
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreationPanel.java 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/data/TrPostDataCreationPanel.java 2010-06-10 21:39:15 UTC (rev 5764)
@@ -682,7 +682,7 @@
final ProgressionInterface _prog, final CtuluCommandContainer _cmd) {
_toProject.buildDefaultVarUpdateLists();
final TrPostSourceProjected pro = new TrPostSourceProjected(_toProject, _dest.getGrid(), _dest.getTime()
- .getInitTimeSteps(), _dest.isRubar(), _sameGrid, _impl.getImpl(), new TrPostSourceProjectedPersistReplay(
+ .getInitTimeSteps(), _dest.containsOnlyElementVar(), _sameGrid, _impl.getImpl(), new TrPostSourceProjectedPersistReplay(
_toProject.getId(), _dest.getId(), _sameGrid));
pro.openDatas(_prog, new CtuluAnalyze(), _impl.getImpl());
Modified: trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostPersistenceManager.java
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostPersistenceManager.java 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostPersistenceManager.java 2010-06-10 21:39:15 UTC (rev 5764)
@@ -11,7 +11,6 @@
import java.io.ObjectOutputStream;
import java.io.OutputStream;
import java.util.ArrayList;
-import java.util.Collection;
import java.util.Collections;
import java.util.HashMap;
import java.util.HashSet;
@@ -364,7 +363,7 @@
// -- ecriture de la classe xstream
ObjectOutputStream out = null;
try {
- out = getParser().createObjectOutputStream(new FileWriter(file));
+ out = EbliLib.createObjectOutpuStream(file, getParser());
// -- readme --//
out.writeObject(XmlCommentaire.getCommentaireLayout());
@@ -505,7 +504,7 @@
// -- g\xE9n\xE9ration du xml pour la scene --//
try {
final File fichier = new File(projet + File.separator + setupProject);
- out = getParser().createObjectOutputStream(new FileWriter(fichier));
+ out=EbliLib.createObjectOutpuStream(fichier, getParser());
// --enregistrement du path relatif --//
final File pathRelatif = CtuluLibFile.getRelativePathnameTo(fichier, projet_);
@@ -541,7 +540,8 @@
ObjectOutputStream out = null;
// -- g\xE9n\xE9ration du xml pour la scene --//
try {
- out = getParser().createObjectOutputStream(new FileWriter(file));
+ out = EbliLib.createObjectOutpuStream(file, getParser());
+
// -- redame --//
out.writeObject(XmlCommentaire.getCommentaireSources());
@@ -1182,7 +1182,7 @@
// -- outputstream du xstream --//
ObjectOutputStream out = null;
try {
- out = getParser().createObjectOutputStream(new FileWriter(file));
+ out = EbliLib.createObjectOutpuStream(file, getParser());
// -- g\xE9n\xE9ration du xml pour la scene --//
out.writeObject(new EbliSceneSerializeXml(scene, title, (Dimension) parametres.get("dimensions"),
Modified: trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostSourceProjectedPersistReplay.java
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostSourceProjectedPersistReplay.java 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/post/persist/TrPostSourceProjectedPersistReplay.java 2010-06-10 21:39:15 UTC (rev 5764)
@@ -33,7 +33,7 @@
TrPostSource init = projet.getSources().getSource(refSourceId);
TrPostSource dest = projet.getSources().getSource(destSourceId);
TrPostSourceProjected res = new TrPostSourceProjected(init, dest.getGrid(), dest.getTime().getInitTimeSteps(), dest
- .isRubar(), gridEquals, projet.getImpl(), this);
+ .containsOnlyElementVar(), gridEquals, projet.getImpl(), this);
res.setId(id);
return res;
}
Modified: trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/rubar/TrRubarDonneesBrutesLayer.java
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/rubar/TrRubarDonneesBrutesLayer.java 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/java/org/fudaa/fudaa/tr/rubar/TrRubarDonneesBrutesLayer.java 2010-06-10 21:39:15 UTC (rev 5764)
@@ -191,6 +191,20 @@
return 4;
}
+ public boolean getCentre(GrPoint pt, int idx, boolean force) {
+ final H2dParallelogrammeDataAbstract d = target_.getParall(idx);
+ pt.x_ = 0;
+ pt.y_ = 0;
+ for (int i = 0; i < 4; i++) {
+ pt.x_ += d.getX(i);
+ pt.y_ += d.getY(i);
+ }
+ pt.x_ = pt.x_ / 4;
+ pt.y_ = pt.y_ / 4;
+ return true;
+
+ }
+
public boolean polygone(final GrPolygone _p, final int _i, final boolean _force) {
if (_p.nombre() != 4) {
_p.sommets_.setSize(4);
Modified: trunk/soft/fudaa-prepro/ui/src/main/resources/org/fudaa/fudaa/tr/common/tr_en.fr_txt
===================================================================
--- trunk/soft/fudaa-prepro/ui/src/main/resources/org/fudaa/fudaa/tr/common/tr_en.fr_txt 2010-06-10 21:37:04 UTC (rev 5763)
+++ trunk/soft/fudaa-prepro/ui/src/main/resources/org/fudaa/fudaa/tr/common/tr_en.fr_txt 2010-06-10 21:39:15 UTC (rev 5764)
@@ -1,4 +1,6 @@
Afficher les \xE9volutions temporelles dans une nouvelle fen\xEAtre=Display time evolutions in a new frame
+Choisir un autre fichier r\xE9sultat=Choose another result file
+Un seul r\xE9sultat est charg\xE9=only one file is loaded
Pas de variables \xE0 afficher. Avez-vous bien charg\xE9 un des fichiers TRC ou HYC ?=No variable to display. Have you loaded the file TRC or HYC ?
Pas de variables=No variables
Erreur, la frame calque ne trouve pas le fichier r\xE9sultat qui correspond \xE0 l'ID =Error, the layer widget didn't find the matching file
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|