Subversion Repositories eFlore/Applications.cel

Compare Revisions

Ignore whitespace Rev 200 → Rev 201

/trunk/src/org/tela_botanica/client/vues/observation/SaisieMotsClesVue.java
37,9 → 37,9
super("Entrez vos mots clés");
setCls("fenmotcles");
oMediateur = om ;
setWidth(300);
//setWidth(300);
motsClesAjout = new TextArea();
motsClesAjout.setWidth(300);
//motsClesAjout.setWidth(300);
validerAjout = new Button("Valider");
voirCacherNuage= new Button("Afficher les mots clés");
final Rafraichissable r = this ;
/trunk/src/org/tela_botanica/client/vues/observation/filtres/ArbreMotsClesObservationVue.java
106,7 → 106,7
arbreMotsCles.setRootNode(root);
arbreMotsCles.setRootVisible(true);
arbreMotsCles.setBorder(false);
arbreMotsCles.setWidth(500);
// arbreMotsCles.setWidth(500);
arbreMotsCles.getRootNode().addListener(new TreeNodeListenerAdapter() {
public void onClick(Node node, EventObject e) {
/trunk/src/org/tela_botanica/client/vues/observation/FormulaireSaisieObservationVue.java
1,7 → 1,7
package org.tela_botanica.client.vues.observation;
 
// TODO Detecter redim et supprimer ajuster
 
 
import java.util.Iterator;
 
import org.tela_botanica.client.interfaces.Rafraichissable;
31,6 → 31,7
import com.gwtext.client.widgets.event.BoxComponentListenerAdapter;
import com.gwtext.client.widgets.event.ButtonListenerAdapter;
import com.gwtext.client.widgets.event.ContainerListenerAdapter;
import com.gwtext.client.widgets.event.PanelListenerAdapter;
import com.gwtext.client.widgets.form.ComboBox;
import com.gwtext.client.widgets.form.DateField;
import com.gwtext.client.widgets.form.FormPanel;
37,6 → 38,7
import com.gwtext.client.widgets.form.TextArea;
import com.gwtext.client.widgets.form.TextField;
import com.gwtext.client.widgets.form.event.ComboBoxListenerAdapter;
import com.gwtext.client.widgets.layout.AnchorLayoutData;
import com.gwtext.client.widgets.layout.ColumnLayout;
import com.gwtext.client.widgets.layout.ColumnLayoutData;
import com.gwtext.client.widgets.layout.FormLayout;
103,7 → 105,6
private final int KEY_TAB = 9;
private final int KEY_UP = 38;
private int tailleChamps = 350 ;
/**
* Combobox permettant de selectionner le mode
136,15 → 137,13
// on associe le médiateur
observationMediateur = obs ;
setHeader(true);
FormPanel panneauFormulaire = new FormPanel(Position.RIGHT);
panneauFormulaire.setBorder(false);
// Panneau intermediaire qui contient deux colonnes de formulaire
Panel panneauIntermediaire = new Panel();
final Panel panneauIntermediaire = new Panel();
panneauIntermediaire.setLayout(new ColumnLayout());
panneauIntermediaire.setBorder(false);
162,7 → 161,7
// Accesskey pour debugging
commune=new ComboBox("Commune","commune\" accesskey=\"1",tailleChamps );
commune=new ComboBox("Commune","commune\" accesskey=\"1");
final String resultTplCommune = "<div class=\"search-item-commune\">{commune}</div>";
commune.setTpl(resultTplCommune);
175,12 → 174,12
commune.setHideTrigger(true);
commune.setTabIndex(1);
panneauPremierColonne.add(commune);
panneauPremierColonne.add(commune, new AnchorLayoutData("95%"));
 
station = new TextField("Station", "station", tailleChamps);
station = new TextField("Station", "station");
station.setAllowBlank(true);
station.setTabIndex(3);
panneauPremierColonne.add(station);
panneauPremierColonne.add(station, new AnchorLayoutData("95%"));
date = new DateField("Date", "date", 100);
date.setAllowBlank(true);
187,10 → 186,10
formatDate = "d/m/Y";
date.setFormat(formatDate) ;
date.setTabIndex(5);
panneauPremierColonne.add(date);
panneauPremierColonne.add(date, new AnchorLayoutData("60%"));
 
espece=new ComboBox("Espèce","nom",tailleChamps );
espece=new ComboBox("Espèce","nom");
final String resultTplEspece = "<div class=\"search-item-espece\">{nom}</div>";
206,25 → 205,24
espece.setHideTrigger(true);
espece.setTabIndex(6);
 
panneauPremierColonne.add(espece);
panneauPremierColonne.add(espece, new AnchorLayoutData("95%"));
lieudit = new TextField("Lieu-dit", "lieudit", tailleChamps);
lieudit = new TextField("Lieu-dit", "lieudit");
lieudit.setAllowBlank(true);
lieudit.setTabIndex(2);
panneauSecondeColonne.add(lieudit);
panneauSecondeColonne.add(lieudit, new AnchorLayoutData("95%"));
milieu = new TextField("Milieu", "milieu", tailleChamps);
milieu = new TextField("Milieu", "milieu");
milieu.setAllowBlank(true);
milieu.setTabIndex(4);
panneauSecondeColonne.add(milieu);
panneauSecondeColonne.add(milieu, new AnchorLayoutData("95%"));
comment = new TextArea("Notes", "comment");
comment.setAllowBlank(true);
comment.setHeight(50);
comment.setWidth(tailleChamps);
comment.setTabIndex(7);
panneauSecondeColonne.add(comment);
panneauSecondeColonne.add(comment, new AnchorLayoutData("95%") );
panneauIntermediaire.add(panneauPremierColonne, new ColumnLayoutData(.5));
panneauIntermediaire.add(panneauSecondeColonne, new ColumnLayoutData(.5));
270,10 → 268,20
this.setTopToolbar(bt) ;
this.setAutoScroll(true);
//this.setAutoHeight(true);
this.setAutoHeight(true);
panneauFormulaire.addListener(new PanelListenerAdapter() {
public void onResize(BoxComponent component, int adjWidth, int adjHeight, int rawWidth, int rawHeight) {
panneauIntermediaire.setWidth(rawWidth);
panneauIntermediaire.setHeight(rawHeight);
}});
// on ajoute les listeners
ajouterListeners() ;
}
280,6 → 288,10
private void ajouterListeners()
{
// Listener completion communne
commune.addListener(new ComboBoxListenerAdapter() {
525,18 → 537,10
this.addListener(new ContainerListenerAdapter() {
public void onAfterLayout(Container self) {
ajusterTailleChamps();
commune.focus();
}
});
this.addListener(new BoxComponentListenerAdapter() {
public void onResize(BoxComponent component, int adjWidth, int adjHeight, int rawWidth, int rawHeight) {
ajusterTailleChamps();
}
});
}
/**
907,19 → 911,5
}
}
private void ajusterTailleChamps() {
int tailleChamps = (this.getInnerWidth()/100)*40;
this.tailleChamps = tailleChamps ;
commune.setWidth(tailleChamps);
station.setWidth(tailleChamps);
espece.setWidth(tailleChamps);
lieudit.setWidth(tailleChamps);
milieu.setWidth(tailleChamps);
comment.setWidth(tailleChamps);
 
}
 
}