Subversion Repositories eFlore/Applications.coel

Rev

Rev 1093 | Rev 1369 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1093 Rev 1262
Line 6... Line 6...
6
import org.tela_botanica.client.images.Images;
6
import org.tela_botanica.client.images.Images;
7
import org.tela_botanica.client.modeles.Valeur;
7
import org.tela_botanica.client.modeles.Valeur;
8
import org.tela_botanica.client.modeles.aDonnee;
8
import org.tela_botanica.client.modeles.aDonnee;
Line 9... Line 9...
9
 
9
 
-
 
10
import com.extjs.gxt.ui.client.event.ButtonEvent;
-
 
11
import com.extjs.gxt.ui.client.event.Events;
-
 
12
import com.extjs.gxt.ui.client.event.FieldEvent;
10
import com.extjs.gxt.ui.client.event.ButtonEvent;
13
import com.extjs.gxt.ui.client.event.Listener;
11
import com.extjs.gxt.ui.client.event.SelectionListener;
14
import com.extjs.gxt.ui.client.event.SelectionListener;
12
import com.extjs.gxt.ui.client.store.ListStore;
15
import com.extjs.gxt.ui.client.store.ListStore;
13
import com.extjs.gxt.ui.client.widget.LayoutContainer;
16
import com.extjs.gxt.ui.client.widget.LayoutContainer;
14
import com.extjs.gxt.ui.client.widget.MessageBox;
17
import com.extjs.gxt.ui.client.widget.MessageBox;
Line 80... Line 83...
80
		this.estComboBox = estCombobox;
83
		this.estComboBox = estCombobox;
81
		setLargeurType(largeurType);
84
		setLargeurType(largeurType);
82
		initialiserChampMultiValeur(label, largeurTotale);
85
		initialiserChampMultiValeur(label, largeurTotale);
83
	}
86
	}
Line -... Line 87...
-
 
87
	
-
 
88
	public ComboBox<Valeur> getTypes() {
-
 
89
		return this.types;
-
 
90
	}
84
	
91
	
85
	public void setLabel(String label) {
92
	public void setLabel(String label) {
86
		if (label == null) {
93
		if (label == null) {
87
			label = "";
94
			label = "";
88
		}
95
		}
Line 150... Line 157...
150
			types.setDisplayField("nom");
157
			types.setDisplayField("nom");
151
			types.setEmptyText("Choisissez:");			
158
			types.setEmptyText("Choisissez:");			
152
			types.setStore(new ListStore<Valeur>());
159
			types.setStore(new ListStore<Valeur>());
153
			types.setTypeAhead(true);
160
			types.setTypeAhead(true);
154
			types.setTriggerAction(TriggerAction.ALL);
161
			types.setTriggerAction(TriggerAction.ALL);
-
 
162
			
-
 
163
			types.addListener(Events.Select, new Listener<FieldEvent>() {
-
 
164
				public void handleEvent(FieldEvent fe) {
-
 
165
 
-
 
166
				}
-
 
167
			});
-
 
168
			
155
			colonneConteneur.add(types, new ColumnData(largeurType));
169
			colonneConteneur.add(types, new ColumnData(largeurType));
156
		}
170
		}
Line 157... Line 171...
157
		
171
		
158
		if (estComboBox) {
172
		if (estComboBox) {
159
			champValeurCombo = new ComboBox<Valeur>();
173
			champValeurCombo = new ComboBox<Valeur>();
160
			champValeurCombo.setDisplayField("nom");
174
			champValeurCombo.setDisplayField("nom");
161
			champValeurCombo.setStore(new ListStore<Valeur>());
175
			champValeurCombo.setStore(new ListStore<Valeur>());
162
			colonneConteneur.add(champValeurCombo, new ColumnData(largeurChamp));
176
			colonneConteneur.add(champValeurCombo, new ColumnData(largeurChamp));			
163
		} else {
177
		} else {
164
			champValeurTxt = new TextField<String>();
178
			champValeurTxt = new TextField<String>();
165
			colonneConteneur.add(champValeurTxt, new ColumnData(largeurChamp));
179
			colonneConteneur.add(champValeurTxt, new ColumnData(largeurChamp));
166
		}
180
		}