| Line 4... |
Line 4... |
| 4 |
import org.tela_botanica.client.interfaces.Rafraichissable;
|
4 |
import org.tela_botanica.client.interfaces.Rafraichissable;
|
| 5 |
import org.tela_botanica.client.modeles.Information;
|
5 |
import org.tela_botanica.client.modeles.Information;
|
| 6 |
import org.tela_botanica.client.modeles.ValeurListe;
|
6 |
import org.tela_botanica.client.modeles.ValeurListe;
|
| 7 |
import org.tela_botanica.client.modeles.projet.Projet;
|
7 |
import org.tela_botanica.client.modeles.projet.Projet;
|
| 8 |
import org.tela_botanica.client.modeles.projet.ProjetListe;
|
8 |
import org.tela_botanica.client.modeles.projet.ProjetListe;
|
| - |
|
9 |
import org.tela_botanica.client.synchronisation.Sequenceur;
|
| 9 |
import org.tela_botanica.client.util.Debug;
|
10 |
import org.tela_botanica.client.util.Debug;
|
| Line 10... |
Line 11... |
| 10 |
|
11 |
|
| 11 |
import com.extjs.gxt.ui.client.Style.LayoutRegion;
|
12 |
import com.extjs.gxt.ui.client.Style.LayoutRegion;
|
| 12 |
import com.extjs.gxt.ui.client.util.Margins;
|
13 |
import com.extjs.gxt.ui.client.util.Margins;
|
| Line 18... |
Line 19... |
| 18 |
public class ProjetVue extends LayoutContainer implements Rafraichissable {
|
19 |
public class ProjetVue extends LayoutContainer implements Rafraichissable {
|
| Line 19... |
Line 20... |
| 19 |
|
20 |
|
| 20 |
private ProjetListeVue panneauProjetListe;
|
21 |
private ProjetListeVue panneauProjetListe;
|
| 21 |
private ProjetDetailVue panneauProjetDetail;
|
22 |
private ProjetDetailVue panneauProjetDetail;
|
| - |
|
23 |
private Mediateur mediateur = null;
|
| Line 22... |
Line 24... |
| 22 |
private Mediateur mediateur = null;
|
24 |
private Sequenceur sequenceur = new Sequenceur();
|
| 23 |
|
25 |
|
| 24 |
public ProjetVue(Mediateur mediateurCourant) {
|
26 |
public ProjetVue(Mediateur mediateurCourant) {
|
| Line 30... |
Line 32... |
| 30 |
setLayout(layout);
|
32 |
setLayout(layout);
|
| Line 31... |
Line 33... |
| 31 |
|
33 |
|
| 32 |
panneauProjetListe = new ProjetListeVue(mediateur);
|
34 |
panneauProjetListe = new ProjetListeVue(mediateur);
|
| Line 33... |
Line 35... |
| 33 |
this.add(panneauProjetListe, new BorderLayoutData(LayoutRegion.CENTER));
|
35 |
this.add(panneauProjetListe, new BorderLayoutData(LayoutRegion.CENTER));
|
| 34 |
|
36 |
|
| 35 |
panneauProjetDetail = new ProjetDetailVue(mediateur);
|
37 |
panneauProjetDetail = new ProjetDetailVue(mediateur, sequenceur);
|
| 36 |
BorderLayoutData southData = new BorderLayoutData(LayoutRegion.SOUTH, .5f, 200, 1000);
|
38 |
BorderLayoutData southData = new BorderLayoutData(LayoutRegion.SOUTH, .5f, 200, 1000);
|
| 37 |
southData.setSplit(true);
|
39 |
southData.setSplit(true);
|
| 38 |
southData.setMargins(new Margins(5, 0, 0, 0));
|
40 |
southData.setMargins(new Margins(5, 0, 0, 0));
|
| Line 39... |
Line 41... |
| 39 |
this.add(panneauProjetDetail, southData);
|
41 |
this.add(panneauProjetDetail, southData);
|
| 40 |
}
|
42 |
}
|
| 41 |
|
43 |
|
| - |
|
44 |
public void rafraichir(Object nouvellesDonnees) {
|
| 42 |
public void rafraichir(Object nouvellesDonnees) {
|
45 |
if (nouvellesDonnees instanceof Projet) {
|
| 43 |
if (nouvellesDonnees instanceof Projet) {
|
46 |
//panneauProjetDetail.rafraichir((Projet) nouvellesDonnees);
|
| 44 |
panneauProjetDetail.rafraichir((Projet) nouvellesDonnees);
|
- |
|
| 45 |
} else if (nouvellesDonnees instanceof ProjetListe) {
|
47 |
sequenceur.empilerRafraichissement(panneauProjetDetail, (Projet) nouvellesDonnees);
|
| 46 |
panneauProjetListe.rafraichir((ProjetListe) nouvellesDonnees);
|
48 |
} else if (nouvellesDonnees instanceof ProjetListe) {
|
| 47 |
mediateur.desactiverChargement();
|
49 |
panneauProjetListe.rafraichir((ProjetListe) nouvellesDonnees);
|
| 48 |
} else if (nouvellesDonnees instanceof Information) {
|
50 |
} else if (nouvellesDonnees instanceof Information) {
|
| 49 |
Information info = (Information) nouvellesDonnees;
|
51 |
Information info = (Information) nouvellesDonnees;
|