1,3 → 1,21 |
/** |
David Delon david.delon@clapas.net 2007 |
|
*/ |
|
/* |
* Cel.java (Point d'entree de l'application carnet en ligne) |
* |
* Cas d'utilisation : |
* Initialisation de l'application |
* |
* 1: Le programme initialise la classe intercesseur (mediator), classe ou sont decrites les actions de l'application. |
* 2: Le programme s'enregistre aupres de la classe intercesseur |
* 3: Le programme recherche les informations de connections (utilisateur ou anonyme) |
* 4: Le programme initialise les differents panneaux composant l'affichage |
* |
*/ |
|
package org.tela_botanica.client; |
|
import com.google.gwt.core.client.EntryPoint; |
16,55 → 34,60 |
*/ |
public class Cel implements EntryPoint, WindowResizeListener { |
|
|
|
private TopPanel topPanel = null; // Identifiant de connexion et titre |
private CenterPanel centerPanel = null; // Liste de releves |
private LeftPanel leftPanel = null; // Filtres sur liste de releves |
private EntryPanel entryPanel = null; // Saisie d'un releve |
private ActionPanel actionPanel = null; // Action sur les relevés saisis |
private SearchPanel searchPanel = null; // Recherche dans les relevés saisis |
|
private TopPanel topPanel = null; |
private CenterPanel centerPanel = null; |
private LeftPanel leftPanel = null; |
private EntryPanel entryPanel = null; |
private ActionPanel actionPanel = null; |
private SearchPanel searchPanel = null; |
private InfoPopup infoPopup = null; |
private VerticalPanel rightPanel = null; // Container panneau précedents (sauf left et popup) |
|
private VerticalPanel rightPanel = null; |
private Mediator mediator = null; |
private Mediator mediator = null; // Intermediaire entre les differents classes |
|
|
/** |
* This is the entry point method. |
* Point d'entree : recherche du pres-requis : information de connection. |
*/ |
|
public void onModuleLoad() { |
|
|
mediator= new Mediator(); |
mediator.registerCel(this); |
mediator.initUser(); // Appelle initAsync suivant |
|
mediator.registerCel(this); // Declaration point d'entree aupres de la classe intercesseur |
mediator.initUser(); // Initialisation environnement utilisateur (Cette methode appelle la methode initAsync() suivante) |
|
} |
|
|
/** |
* Fin de l'initialisation |
* |
*/ |
|
public void initAsync() { |
|
|
centerPanel = new CenterPanel(mediator); |
centerPanel = new CenterPanel(mediator); // Liste de releves |
|
topPanel = new TopPanel(mediator); // Identifiant de connection |
|
leftPanel = new LeftPanel(mediator); // Filte de liste de releves |
|
|
entryPanel = new EntryPanel(mediator); // Formulaire de saisie |
|
topPanel = new TopPanel(mediator); |
leftPanel = new LeftPanel(mediator); |
actionPanel = new ActionPanel(mediator); // Action sur releves saisis |
searchPanel = new SearchPanel(mediator); // Recherche dans releves |
|
rightPanel = new VerticalPanel(); // Container des panneaux precedents |
|
entryPanel.setStyleName("item-Input"); |
|
entryPanel = new EntryPanel(mediator); |
actionPanel = new ActionPanel(mediator); |
searchPanel = new SearchPanel(mediator); |
rightPanel = new VerticalPanel(); |
infoPopup = new InfoPopup(mediator); |
|
|
// Information haut de page (nom application, connexion ... etc). |
// A regler |
// Assemblage des differents panneaux |
|
entryPanel.setStyleName("item-Input"); |
|
rightPanel.add(searchPanel); |
rightPanel.add(entryPanel); |
rightPanel.add(centerPanel); |
73,27 → 96,18 |
|
rightPanel.setWidth("100%"); |
centerPanel.setWidth("100%"); |
|
entryPanel.setWidth("100%"); |
topPanel.setWidth("100%"); |
|
|
rightPanel.setSpacing(2); |
|
// Disposition générale : |
|
// DockPanel permet d'arranger plusieurs panneaux au coins cardinaux, le panneau central remplissant |
// l'espace laissé. |
|
|
DockPanel outer = new DockPanel(); |
outer.add(topPanel, DockPanel.NORTH); |
outer.add(rightPanel, DockPanel.CENTER); |
outer.add(leftPanel, DockPanel.WEST); |
// outer.add(bottomPanel, DockPanel.SOUTH); |
|
// LeftPanel : |
// Pour l'instant : relevés. |
|
outer.setWidth("100%"); |
|
outer.setSpacing(2); |
102,6 → 116,8 |
// Window.enableScrolling(false); |
Window.setMargin("0px"); |
|
// Initialisation des differents contenus ... |
|
mediator.onInit(); |
|
RootPanel.get().add(outer); |
135,3 → 151,8 |
|
|
} |
|
/* +--Fin du code ---------------------------------------------------------------------------------------+ |
* $Log$ |
* |
*/ |