Subversion Repositories eFlore/Applications.cel

Rev

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

Rev 989 Rev 1292
Line 10... Line 10...
10
import org.tela_botanica.client.modeles.objets.Configuration;
10
import org.tela_botanica.client.modeles.objets.Configuration;
11
import org.tela_botanica.client.modeles.objets.EntiteGeographiqueObservation;
11
import org.tela_botanica.client.modeles.objets.EntiteGeographiqueObservation;
12
import org.tela_botanica.client.modeles.objets.ListeObservation;
12
import org.tela_botanica.client.modeles.objets.ListeObservation;
13
import org.tela_botanica.client.modeles.objets.ListeReferentielCommune;
13
import org.tela_botanica.client.modeles.objets.ListeReferentielCommune;
14
import org.tela_botanica.client.modeles.objets.ListeReferentielNom;
14
import org.tela_botanica.client.modeles.objets.ListeReferentielNom;
15
import org.tela_botanica.client.modeles.objets.ListeReferentielPerso;
-
 
16
import org.tela_botanica.client.modeles.objets.Observation;
15
import org.tela_botanica.client.modeles.objets.Observation;
17
import org.tela_botanica.client.modeles.objets.ReferentielCommune;
16
import org.tela_botanica.client.modeles.objets.ReferentielCommune;
18
import org.tela_botanica.client.modeles.objets.ReferentielNom;
17
import org.tela_botanica.client.modeles.objets.ReferentielNom;
19
import org.tela_botanica.client.modeles.objets.ListeReferentielPerso.TypesReferentiels;
18
import org.tela_botanica.client.modeles.objets.ListeReferentielPerso.TypesReferentiels;
20
import org.tela_botanica.client.observation.ObservationMediateur;
19
import org.tela_botanica.client.observation.ObservationMediateur;
21
import org.tela_botanica.client.util.AutoCompletionRefComboBox;
20
import org.tela_botanica.client.util.AutoCompletionRefComboBox;
22
import org.tela_botanica.client.util.Util;
21
import org.tela_botanica.client.util.Util;
Line 23... Line -...
23
 
-
 
24
import com.google.gwt.core.client.GWT;
-
 
25
import com.google.gwt.core.client.JavaScriptObject;
-
 
26
import com.google.gwt.event.dom.client.KeyPressEvent;
22
 
27
import com.google.gwt.maps.client.geom.LatLng;
23
import com.google.gwt.maps.client.geom.LatLng;
28
import com.google.gwt.user.client.Timer;
24
import com.google.gwt.user.client.Timer;
29
import com.google.gwt.user.client.Window;
25
import com.google.gwt.user.client.Window;
30
import com.google.gwt.user.client.ui.HTML;
26
import com.google.gwt.user.client.ui.HTML;
31
import com.gwtext.client.core.EventCallback;
27
import com.gwtext.client.core.EventCallback;
32
import com.gwtext.client.core.EventObject;
28
import com.gwtext.client.core.EventObject;
33
import com.gwtext.client.core.Ext;
29
import com.gwtext.client.core.Ext;
34
import com.gwtext.client.core.ExtElement;
-
 
35
import com.gwtext.client.core.Function;
30
import com.gwtext.client.core.ExtElement;
36
import com.gwtext.client.core.ListenerConfig;
31
import com.gwtext.client.core.ListenerConfig;
37
import com.gwtext.client.core.Position;
32
import com.gwtext.client.core.Position;
38
import com.gwtext.client.data.ArrayReader;
33
import com.gwtext.client.data.ArrayReader;
39
import com.gwtext.client.data.FieldDef;
34
import com.gwtext.client.data.FieldDef;
Line 42... Line 37...
42
import com.gwtext.client.data.SimpleStore;
37
import com.gwtext.client.data.SimpleStore;
43
import com.gwtext.client.data.Store;
38
import com.gwtext.client.data.Store;
44
import com.gwtext.client.data.StringFieldDef;
39
import com.gwtext.client.data.StringFieldDef;
45
import com.gwtext.client.widgets.BoxComponent;
40
import com.gwtext.client.widgets.BoxComponent;
46
import com.gwtext.client.widgets.Button;
41
import com.gwtext.client.widgets.Button;
47
import com.gwtext.client.widgets.Component;
-
 
48
import com.gwtext.client.widgets.Container;
42
import com.gwtext.client.widgets.Container;
49
import com.gwtext.client.widgets.DatePicker;
43
import com.gwtext.client.widgets.DatePicker;
50
import com.gwtext.client.widgets.Panel;
44
import com.gwtext.client.widgets.Panel;
51
import com.gwtext.client.widgets.ToolTip;
45
import com.gwtext.client.widgets.ToolTip;
52
import com.gwtext.client.widgets.Toolbar;
46
import com.gwtext.client.widgets.Toolbar;
Line 60... Line 54...
60
import com.gwtext.client.widgets.form.FormPanel;
54
import com.gwtext.client.widgets.form.FormPanel;
61
import com.gwtext.client.widgets.form.Label;
55
import com.gwtext.client.widgets.form.Label;
62
import com.gwtext.client.widgets.form.MultiFieldPanel;
56
import com.gwtext.client.widgets.form.MultiFieldPanel;
63
import com.gwtext.client.widgets.form.TextArea;
57
import com.gwtext.client.widgets.form.TextArea;
64
import com.gwtext.client.widgets.form.TextField;
58
import com.gwtext.client.widgets.form.TextField;
65
import com.gwtext.client.widgets.form.event.ComboBoxCallback;
-
 
66
import com.gwtext.client.widgets.form.event.ComboBoxListener;
-
 
67
import com.gwtext.client.widgets.form.event.ComboBoxListenerAdapter;
59
import com.gwtext.client.widgets.form.event.ComboBoxListenerAdapter;
68
import com.gwtext.client.widgets.form.event.TextFieldListener;
-
 
69
import com.gwtext.client.widgets.form.event.TextFieldListenerAdapter;
60
import com.gwtext.client.widgets.form.event.TextFieldListenerAdapter;
70
import com.gwtext.client.widgets.layout.AnchorLayoutData;
61
import com.gwtext.client.widgets.layout.AnchorLayoutData;
71
import com.gwtext.client.widgets.layout.ColumnLayout;
62
import com.gwtext.client.widgets.layout.ColumnLayout;
72
import com.gwtext.client.widgets.layout.ColumnLayoutData;
63
import com.gwtext.client.widgets.layout.ColumnLayoutData;
73
import com.gwtext.client.widgets.layout.FormLayout;
64
import com.gwtext.client.widgets.layout.FormLayout;
Line 107... Line 98...
107
	// Pour remise a zero partielle lors d'une validation
98
	// Pour remise a zero partielle lors d'une validation
Line 108... Line 99...
108
	
99
	
109
	private  enum Champs {
100
	private  enum Champs {
Line -... Line 101...
-
 
101
	    DATE, LIEUDIT, STATION, MILIEU, COMMENT, COMMUNE, ESPECE, TOUT, LATITUDE, LONGITUDE ;
110
	    DATE, LIEUDIT, STATION, MILIEU, COMMENT, COMMUNE, ESPECE, TOUT, LATITUDE, LONGITUDE ;
102
	    
Line 111... Line 103...
111
	    
103
	    @Override
112
	    public String toString() {
104
		public String toString() {
113
	    	
105
	    	
Line 319... Line 311...
319
 
311
 
Line 320... Line 312...
320
		panneauPremierColonne.add(htmlCommunePanel);
312
		panneauPremierColonne.add(htmlCommunePanel);
Line -... Line 313...
-
 
313
 
321
 
314
	    station = new AutoCompletionRefComboBox("Station", "station", observationMediateur, TypesReferentiels.REFERENTIEL_STATION) {
322
	    station = new AutoCompletionRefComboBox("Station", "station", observationMediateur, TypesReferentiels.REFERENTIEL_STATION) {
315
 
323
 
316
			@Override
Line -... Line 317...
-
 
317
			public void onModificationValeur() {
324
			public void onModificationValeur() {
318
				stationModifiee = true;
325
				stationModifiee = true;
319
			}
326
			}
320
 
327
 
321
			@Override
328
			public void onValidationSaisie() {
322
			public void onValidationSaisie() {
Line 377... Line 371...
377
						
371
						
Line 378... Line 372...
378
			//ajout d'un listener sur le lien "saisie X/Y"
372
			//ajout d'un listener sur le lien "saisie X/Y"
Line -... Line 373...
-
 
373
			
379
			
374
			coordPanel.addListener(new PanelListenerAdapter() {
Line 380... Line 375...
380
			coordPanel.addListener(new PanelListenerAdapter() {
375
				
381
				
376
				@Override
382
				public void onAfterLayout(Container c) {
377
				public void onAfterLayout(Container c) {
-
 
378
					
383
					
379
					ExtElement lienCoord = Ext.get("lien_coord");
Line 384... Line 380...
384
					ExtElement lienCoord = Ext.get("lien_coord");
380
					lienCoord.removeAllListeners();
Line 385... Line 381...
385
					lienCoord.removeAllListeners();
381
					lienCoord.addListener("click", new EventCallback() {
Line 397... Line 393...
397
					}) ;
393
					}) ;
Line 398... Line 394...
398
					
394
					
399
					ExtElement lienCartoCoord = Ext.get("lien_carto_coord");
395
					ExtElement lienCartoCoord = Ext.get("lien_carto_coord");
400
					lienCartoCoord.removeAllListeners();
396
					lienCartoCoord.removeAllListeners();
-
 
397
					lienCartoCoord.addListener("click", new EventCallback() {
401
					lienCartoCoord.addListener("click", new EventCallback() {
398
						@Override
402
						public void execute(EventObject e) {
399
						public void execute(EventObject e) {
403
							obtenirInformationCoord();
400
							obtenirInformationCoord();
404
						}
401
						}
Line 405... Line 402...
405
					}) ;
402
					}) ;
406
				
403
				
407
					ExtElement lienCarto = Ext.get("lien_carto");
404
					ExtElement lienCarto = Ext.get("lien_carto");
Line -... Line 405...
-
 
405
					lienCarto.removeAllListeners();
408
					lienCarto.removeAllListeners();
406
					lienCarto.addListener("click", new EventCallback() {
Line 409... Line 407...
409
					lienCarto.addListener("click", new EventCallback() {
407
 
410
 
408
						@Override
411
						public void execute(EventObject e) {
409
						public void execute(EventObject e) {
Line 467... Line 465...
467
 
465
 
Line 468... Line 466...
468
	    panneauPremierColonne.add(espece, new AnchorLayoutData("95%"));   
466
	    panneauPremierColonne.add(espece, new AnchorLayoutData("95%"));   
Line -... Line 467...
-
 
467
	    
469
	    
468
	    lieudit = new AutoCompletionRefComboBox("Lieu-dit", "lieudit",observationMediateur,TypesReferentiels.REFERENTIEL_LIEU_DIT) {
470
	    lieudit = new AutoCompletionRefComboBox("Lieu-dit", "lieudit",observationMediateur,TypesReferentiels.REFERENTIEL_LIEU_DIT) {
469
 
471
 
470
			@Override
Line -... Line 471...
-
 
471
			public void onModificationValeur() {
472
			public void onModificationValeur() {
472
				lieuDitModifie = true;			
473
				lieuDitModifie = true;			
473
			}
474
			}
474
 
475
 
475
			@Override
476
			public void onValidationSaisie() {
476
			public void onValidationSaisie() {
Line 477... Line 477...
477
				validerSaisie(Champs.LIEUDIT);
477
				validerSaisie(Champs.LIEUDIT);
Line -... Line 478...
-
 
478
			}
478
			}
479
	    };
479
	    };
480
	    panneauSecondeColonne.add(lieudit,  new AnchorLayoutData("95%"));  
480
	    panneauSecondeColonne.add(lieudit,  new AnchorLayoutData("95%"));  
481
	       	    
Line -... Line 482...
-
 
482
	    milieu = new AutoCompletionRefComboBox("Milieu","milieu",observationMediateur,TypesReferentiels.REFERENTIEL_MILIEU) {
481
	       	    
483
 
482
	    milieu = new AutoCompletionRefComboBox("Milieu","milieu",observationMediateur,TypesReferentiels.REFERENTIEL_MILIEU) {
484
			@Override
483
 
485
			public void onModificationValeur() {
Line 484... Line 486...
484
			public void onModificationValeur() {
486
				milieuModifie = true;
Line 542... Line 544...
542
		}
544
		}
Line 543... Line 545...
543
		
545
		
Line -... Line 546...
-
 
546
		
544
		
547
		selecteurMode.addListener(new ComboBoxListenerAdapter() {
Line 545... Line 548...
545
		selecteurMode.addListener(new ComboBoxListenerAdapter() {
548
 
546
 
549
			@Override
547
			public void onSelect(ComboBox comboBox, Record record, int index) {
550
			public void onSelect(ComboBox comboBox, Record record, int index) {
Line 558... Line 561...
558
		
561
		
Line 559... Line 562...
559
		this.setAutoScroll(true);
562
		this.setAutoScroll(true);
-
 
563
	
560
	
564
		
561
		
565
		panneauFormulaire.addListener(new PanelListenerAdapter() {
562
		panneauFormulaire.addListener(new PanelListenerAdapter() {
566
	        @Override
Line 563... Line 567...
563
	        public void onResize(BoxComponent component, int adjWidth, int adjHeight, int rawWidth, int rawHeight) {
567
			public void onResize(BoxComponent component, int adjWidth, int adjHeight, int rawWidth, int rawHeight) {
564
	        	panneauIntermediaire.setWidth(rawWidth);
568
	        	panneauIntermediaire.setWidth(rawWidth);
Line 586... Line 590...
586
	{	
590
	{	
587
		// Listener completion communne 
591
		// Listener completion communne 
588
		final Rafraichissable r = this;
592
		final Rafraichissable r = this;
Line 589... Line 593...
589
		
593
		
-
 
594
		   commune.addListener(new ComboBoxListenerAdapter() {  
590
		   commune.addListener(new ComboBoxListenerAdapter() {  
595
	             @Override
591
	             public void onSelect(ComboBox comboBox, Record record, int index) {  
596
				public void onSelect(ComboBox comboBox, Record record, int index) {  
592
	                 commune.setValue(record.getAsString("commune"));
597
	                 commune.setValue(record.getAsString("commune"));
593
	                 departement=record.getAsString("departement");
598
	                 departement=record.getAsString("departement");
594
	                 selectionCommune=true;
599
	                 selectionCommune=true;
595
	                 commune.collapse();
600
	                 commune.collapse();
Line -... Line 601...
-
 
601
	             }  
596
	             }  
602
	             
597
	             
603
	             @Override
598
	             public void onExpand(ComboBox comboBox) {
604
				public void onExpand(ComboBox comboBox) {
599
	            	 comboBox.focus();
605
	            	 comboBox.focus();
Line 606... Line 612...
606
			listenerConfigCommune.setStopPropagation(false);
612
			listenerConfigCommune.setStopPropagation(false);
607
			listenerConfigCommune.setStopEvent(false);
613
			listenerConfigCommune.setStopEvent(false);
Line 608... Line 614...
608
			
614
			
Line -... Line 615...
-
 
615
		    commune.addKeyPressListener(new EventCallback()	{
609
		    commune.addKeyPressListener(new EventCallback()	{
616
		    	
Line 610... Line 617...
610
		    	
617
	    	    @Override
Line 611... Line 618...
611
	    	    public void execute(EventObject e) {
618
				public void execute(EventObject e) {
Line 655... Line 662...
655
	    		},    listenerConfigCommune
662
	    		},    listenerConfigCommune
656
			);
663
			);
Line 657... Line 664...
657
		    
664
		    
Line -... Line 665...
-
 
665
		    date.addKeyPressListener(new EventCallback() {
658
		    date.addKeyPressListener(new EventCallback() {
666
 
659
 
667
				@Override
660
				public void execute(EventObject e) {
668
				public void execute(EventObject e) {
Line 661... Line 669...
661
					// TODO Auto-generated method stub
669
					// TODO Auto-generated method stub
Line 690... Line 698...
690
				}
698
				}
691
		    });
699
		    });
Line 692... Line 700...
692
		    
700
		    
Line -... Line 701...
-
 
701
		    date.addListener(new DatePickerListenerAdapter() {
693
		    date.addListener(new DatePickerListenerAdapter() {
702
 
694
 
703
				@Override
695
				public void onSelect(DatePicker dataPicker, Date date) {
704
				public void onSelect(DatePicker dataPicker, Date date) {
696
					dateModifiee = true;
705
					dateModifiee = true;
Line 703... Line 712...
703
		    listenerConfigAutocompletion.setStopEvent(false);
712
		    listenerConfigAutocompletion.setStopEvent(false);
Line 704... Line 713...
704
 
713
 
705
		    			
714
		    			
-
 
715
			// Listener completion espece 
706
			// Listener completion espece 
716
			espece.addListener(new ComboBoxListenerAdapter() {  
707
			espece.addListener(new ComboBoxListenerAdapter() {  
717
	             @Override
708
	             public void onSelect(ComboBox comboBox, Record record, int index) {  
718
				public void onSelect(ComboBox comboBox, Record record, int index) {  
709
	            	 espece.setValue(record.getAsString("nom"));
719
	            	 espece.setValue(record.getAsString("nom"));
710
	            	 numeroNom=record.getAsString("numeroNom");
720
	            	 numeroNom=record.getAsString("numeroNom");
711
	                 selectionEspece=true;
721
	                 selectionEspece=true;
Line 720... Line 730...
720
			listenerConfigEspece.setStopEvent(false);			
730
			listenerConfigEspece.setStopEvent(false);			
Line 721... Line 731...
721
 
731
 
Line -... Line 732...
-
 
732
		
722
		
733
			espece.addKeyPressListener(new EventCallback()	{
Line 723... Line 734...
723
			espece.addKeyPressListener(new EventCallback()	{
734
		    	
Line 773... Line 784...
773
		    	
784
		    	
Line 774... Line 785...
774
			);
785
			);
Line -... Line 786...
-
 
786
			
775
			
787
			comment.addKeyPressListener(new EventCallback() {
776
			comment.addKeyPressListener(new EventCallback() {
788
 
777
 
789
				@Override
778
				public void execute(EventObject e) {
790
				public void execute(EventObject e) {
779
					switch(e.getKey()) { 
791
					switch(e.getKey()) { 
Line 799... Line 811...
799
				}
811
				}
800
		    });
812
		    });
Line 801... Line 813...
801
			
813
			
Line -... Line 814...
-
 
814
			tCoord = new Timer() {
802
			tCoord = new Timer() {
815
 
803
 
816
				@Override
804
				public void run() {
817
				public void run() {
805
    	        	double[] coord = coordonneesValides();
818
    	        	double[] coord = coordonneesValides();
806
    	        	if(!rechercheCommuneEnCours && coord != null && (longModifiee || latModifiee)) {
819
    	        	if(!rechercheCommuneEnCours && coord != null && (longModifiee || latModifiee)) {
Line 812... Line 825...
812
				
825
				
Line 813... Line 826...
813
			};
826
			};
Line -... Line 827...
-
 
827
			
814
			
828
			latitude.addKeyPressListener(new EventCallback() {
815
			latitude.addKeyPressListener(new EventCallback() {
829
 
816
 
830
				@Override
817
				public void execute(EventObject e) {
831
				public void execute(EventObject e) {
818
					switch(e.getKey()) { 
832
					switch(e.getKey()) { 
Line 844... Line 858...
844
				}
858
				}
845
		    });
859
		    });
Line 846... Line 860...
846
			
860
			
Line -... Line 861...
-
 
861
			longitude.addKeyPressListener(new EventCallback() {
847
			longitude.addKeyPressListener(new EventCallback() {
862
 
848
 
863
				@Override
Line 849... Line 864...
849
				public void execute(EventObject e) {
864
				public void execute(EventObject e) {
850
					switch(e.getKey()) { 
865
					switch(e.getKey()) { 
Line 876... Line 891...
876
				}
891
				}
877
		    });
892
		    });
Line 878... Line 893...
878
 
893
 
Line -... Line 894...
-
 
894
		boutonOK.addListener(new ButtonListenerAdapter() {
879
		boutonOK.addListener(new ButtonListenerAdapter() {
895
			
Line 880... Line 896...
880
			
896
			@Override
881
			public void onClick(Button button, EventObject e) {
897
			public void onClick(Button button, EventObject e) {
882
		
898
		
Line 896... Line 912...
896
			
912
			
Line 897... Line 913...
897
		});
913
		});
Line -... Line 914...
-
 
914
		
898
		
915
		boutonAnnuler.addListener(new ButtonListenerAdapter() {
Line 899... Line 916...
899
		boutonAnnuler.addListener(new ButtonListenerAdapter() {
916
			
900
			
917
			@Override
901
			public void onClick(Button button, EventObject e) {
918
			public void onClick(Button button, EventObject e) {
Line 911... Line 928...
911
			}
928
			}
Line 912... Line 929...
912
			
929
			
Line 913... Line 930...
913
		});
930
		});
-
 
931
		
914
		
932
		this.addListener(new ContainerListenerAdapter() {
915
		this.addListener(new ContainerListenerAdapter() {
933
			@Override
916
			public void onAfterLayout(Container self) {
934
			public void onAfterLayout(Container self) {
917
				commune.focus();
935
				commune.focus();
Line 955... Line 973...
955
	public void activerPanneau()
973
	public void activerPanneau()
956
	{
974
	{
957
		this.setDisabled(false) ;
975
		this.setDisabled(false) ;
958
	}
976
	}
Line -... Line 977...
-
 
977
 
959
 
978
	@Override
Line 960... Line 979...
960
	public void rafraichir(Object nouvelleDonnees, boolean repandreRaffraichissement) {
979
	public void rafraichir(Object nouvelleDonnees, boolean repandreRaffraichissement) {
961
		
980
		
962
		// si l'on a reçu une liste du referentiel commune (completion referentiel commune)
981
		// si l'on a reçu une liste du referentiel commune (completion referentiel commune)
Line 968... Line 987...
968
			
987
			
969
				// on la parse et on récupère les informations quiç nous interessent
988
				// on la parse et on récupère les informations quiç nous interessent
970
				for (Iterator it = data.keySet().iterator(); it.hasNext();) 
989
				for (Iterator it = data.keySet().iterator(); it.hasNext();) 
Line 971... Line 990...
971
				{
990
				{
Line 972... Line 991...
972
					
991
					
973
					ReferentielCommune ref=(ReferentielCommune) data.get(it.next());
992
					ReferentielCommune ref=data.get(it.next());
Line 1003... Line 1022...
1003
			{
1022
			{
Line 1004... Line 1023...
1004
				
1023
				
1005
				ListeReferentielNom data = (ListeReferentielNom) nouvelleDonnees ;
1024
				ListeReferentielNom data = (ListeReferentielNom) nouvelleDonnees ;
1006
				Object[][] nomData = new Object[data.size()][3];
1025
				Object[][] nomData = new Object[data.size()][3];
1007
				int i = 0 ;
1026
				int i = 0 ;
1008
			
1027
 
1009
				// on la parse et on récupère les informations quiç nous interessent
1028
				// on la parse et on récupère les informations quiç nous interessent
1010
				for (Iterator it = data.keySet().iterator(); it.hasNext();) 
1029
				for (Iterator it = data.keySet().iterator(); it.hasNext();) 
Line 1011... Line 1030...
1011
				{
1030
				{
Line 1012... Line 1031...
1012
					
1031
					
1013
					ReferentielNom ref=(ReferentielNom) data.get(it.next());
1032
					ReferentielNom ref=data.get(it.next());
1014
					
1033
					
1015
					nomData[i][0]= ref.getNom();
1034
					nomData[i][0]= ref.getNom();
Line 1022... Line 1041...
1022
					}
1041
					}
Line 1023... Line 1042...
1023
					
1042
					
1024
																
1043
																
1025
					i++ ;
1044
					i++ ;
1026
				}
-
 
1027
				
1045
				}
1028
				   //	  creation du store
1046
 
1029
				FieldDef defNom = new StringFieldDef("nom");
1047
				FieldDef defNom = new StringFieldDef("nom");
1030
				FieldDef defNumeroNom = new StringFieldDef("numeroNom");
-
 
1031
				FieldDef indicateurNomRetenu = new StringFieldDef("indicateurNomRetenu");
1048
				FieldDef defNumeroNom = new StringFieldDef("numeroNom");
1032
				
1049
				FieldDef indicateurNomRetenu = new StringFieldDef("indicateurNomRetenu");
Line 1033... Line 1050...
1033
				
1050
						
Line 1034... Line 1051...
1034
				FieldDef[] defTab = { defNom, defNumeroNom, indicateurNomRetenu};
1051
				FieldDef[] defTab = { defNom, defNumeroNom, indicateurNomRetenu};
1035
				
1052
				
Line 1036... Line 1053...
1036
				RecordDef rd = new RecordDef(defTab);
1053
				RecordDef rd = new RecordDef(defTab);
1037
				
-
 
1038
				final MemoryProxy dataProxy = new MemoryProxy(nomData);
-
 
1039
				final ArrayReader reader = new ArrayReader(rd);		
1054
				
1040
				
-
 
-
 
1055
				final MemoryProxy dataProxy = new MemoryProxy(nomData);
1041
				Store store=new Store(dataProxy,reader);
1056
				final ArrayReader reader = new ArrayReader(rd);		
Line 1042... Line 1057...
1042
				store.load() ;
1057
				
Line 1043... Line 1058...
1043
	
1058
				Store store=new Store(dataProxy,reader);	
Line 1098... Line 1113...
1098
			
1113
			
1099
			lienSelectionCommune.setHtml("<a id=\"lien_selection_commune\" tabindex=\"9\">"+nCommune+"</a>");
1114
			lienSelectionCommune.setHtml("<a id=\"lien_selection_commune\" tabindex=\"9\">"+nCommune+"</a>");
Line 1100... Line 1115...
1100
			lienSelectionCommune.setStyleName("img-curseur-depl");
1115
			lienSelectionCommune.setStyleName("img-curseur-depl");
-
 
1116
			
1101
			
1117
			Ext.get("lien_selection_commune").addListener("click",new EventCallback() {
1102
			Ext.get("lien_selection_commune").addListener("click",new EventCallback() {
1118
				@Override
1103
				public void execute(EventObject e) {
1119
				public void execute(EventObject e) {
1104
					rafraichirCommune(infosCom);
1120
					rafraichirCommune(infosCom);
Line 1105... Line 1121...
1105
				}			
1121
				}			
-
 
1122
			});
1106
			});
1123
			
1107
			
1124
			Ext.get("lien_selection_commune").addListener("keypress",new EventCallback() {
1108
			Ext.get("lien_selection_commune").addListener("keypress",new EventCallback() {
1125
				@Override
1109
				public void execute(EventObject e) {
1126
				public void execute(EventObject e) {
1110
					if(e.getCharCode() == KEY_ENTER) {
1127
					if(e.getCharCode() == KEY_ENTER) {
1111
						rafraichirCommune(infosCom);
1128
						rafraichirCommune(infosCom);
Line 1112... Line 1129...
1112
					}
1129
					}
-
 
1130
				}			
1113
				}			
1131
			});
1114
			});
1132
			
1115
			
1133
			Ext.get("lien_selection_commune").addListener("focus",new EventCallback() {
1116
			Ext.get("lien_selection_commune").addListener("focus",new EventCallback() {
1134
				@Override
Line 1117... Line 1135...
1117
				public void execute(EventObject e) {
1135
				public void execute(EventObject e) {
-
 
1136
					Ext.get("lien_selection_commune").toggleClass("lien_sel");
1118
					Ext.get("lien_selection_commune").toggleClass("lien_sel");
1137
				}			
1119
				}			
1138
			});
1120
			});
1139
			
1121
			
1140
			Ext.get("lien_selection_commune").addListener("blur",new EventCallback() {
Line 1715... Line 1734...
1715
		station.setTabIndex(4);
1734
		station.setTabIndex(4);
1716
		milieu.setTabIndex(5);
1735
		milieu.setTabIndex(5);
1717
		coordonnees.setTabIndex(-1);
1736
		coordonnees.setTabIndex(-1);
1718
		coordonnees.addListener(new TextFieldListenerAdapter() {
1737
		coordonnees.addListener(new TextFieldListenerAdapter() {
Line -... Line 1738...
-
 
1738
 
1719
 
1739
			@Override
1720
			public void onFocus(Field field) {
1740
			public void onFocus(Field field) {
1721
				if(coordPanel.isVisible()) {
1741
				if(coordPanel.isVisible()) {
1722
					latitude.focus();
1742
					latitude.focus();
1723
				} else {
1743
				} else {