Subversion Repositories eFlore/Archives.cel-v1

Rev

Rev 11 | Go to most recent revision | Only display areas with differences | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 11 Rev 12
1
package org.tela_botanica.client;
1
package org.tela_botanica.client;
2
 
2
 
3
import com.google.gwt.core.client.EntryPoint;
3
import com.google.gwt.core.client.EntryPoint;
4
import com.google.gwt.user.client.Window;
4
import com.google.gwt.user.client.Window;
5
import com.google.gwt.user.client.ui.DockPanel;
5
import com.google.gwt.user.client.ui.DockPanel;
6
import com.google.gwt.user.client.ui.RootPanel;
6
import com.google.gwt.user.client.ui.RootPanel;
7
 
7
 
8
 
8
 
9
 
9
 
10
/**
10
/**
11
 * Entry point classes define <code>onModuleLoad()</code>.
11
 * Entry point classes define <code>onModuleLoad()</code>.
12
 */
12
 */
13
public class Cel implements EntryPoint {
13
public class Cel implements EntryPoint {
14
 
14
 
15
  
15
  
16
  private TopPanel topPanel = null;
16
  private TopPanel topPanel = null;
17
  private CenterPanel centerPanel = null;
17
  private CenterPanel centerPanel = null;
18
  private LeftPanel leftPanel = null;
18
  private LeftPanel leftPanel = null;
-
 
19
  private EntryPanel entryPanel = null;
19
  
20
  
20
  private Mediator mediator = null;
21
  private Mediator mediator = null;
21
  
22
 
22
 
23
 
23
  /**
24
  /**
24
   * This is the entry point method.
25
   * This is the entry point method.
25
   */
26
   */
26
  public void onModuleLoad() {
27
  public void onModuleLoad() {
27
 
28
 
28
 
29
 
29
	 mediator= new Mediator();
30
	 mediator= new Mediator();
30
	 mediator.registerCel(this);
31
	 mediator.registerCel(this);
31
	 mediator.initUser(); // Appelle initAsync suivant
32
	 mediator.initUser(); // Appelle initAsync suivant
32
		
33
		
33
		
34
		
34
  }
35
  }
35
  
36
  
36
  public void initAsync() {
37
  public void initAsync() {
37
	  
38
	  
38
 
39
 
39
	  centerPanel = new CenterPanel(mediator);
40
	  centerPanel = new CenterPanel(mediator);
-
 
41
	  
40
	  topPanel = new TopPanel(mediator);
42
	  topPanel = new TopPanel(mediator);
41
	  leftPanel = new LeftPanel(mediator);
43
	  leftPanel = new LeftPanel(mediator);
-
 
44
 
42
 
45
	  entryPanel = new EntryPanel(mediator);
43
	  
46
	  
44
	  // Information haut de page (nom application, connexion ... etc).
47
	  // Information haut de page (nom application, connexion ... etc).
45
	  // A regler 
48
	  // A regler 
46
	  
49
	  
-
 
50
	  entryPanel.setStyleName("item-Input");
47
	  topPanel.setWidth("100%");
51
	  
48
 
52
 
49
	  
53
	  
50
	  // DockPanel permet d'arranger plusieurs panneaux au coins cardinaux, le panneau central remplissant
54
	  // DockPanel permet d'arranger plusieurs panneaux au coins cardinaux, le panneau central remplissant
51
	  // l'espace laissé.
55
	  // l'espace laissé.
52
	  
56
	  
53
	  
57
	  
54
	  DockPanel outer = new DockPanel();
58
	  DockPanel outer = new DockPanel();
55
	  outer.add(topPanel, DockPanel.NORTH);
59
	  outer.add(topPanel, DockPanel.NORTH);
56
	  outer.add(centerPanel, DockPanel.CENTER);
60
	  outer.add(centerPanel, DockPanel.CENTER);
57
	  outer.add(leftPanel, DockPanel.WEST);
61
	  outer.add(leftPanel, DockPanel.WEST);
-
 
62
//	  outer.add(bottomPanel, DockPanel.SOUTH);
58
	  
63
	  
59
	  centerPanel.setWidth("100%");
64
	  centerPanel.setWidth("100%");
60
	  // LeftPanel : 
65
	  // LeftPanel : 
61
	  // Pour l'instant : relevés.
66
	  // Pour l'instant : relevés.
62
	  
67
	  
63
	  outer.setWidth("100%");
68
	  outer.setWidth("100%");
64
 
69
 
65
	  outer.setSpacing(4);
70
	  outer.setSpacing(4);
66
	  outer.setCellWidth(centerPanel, "85%");
71
	  outer.setCellWidth(centerPanel, "85%");
67
	 
72
	 
68
//	  Window.enableScrolling(false);
73
//	  Window.enableScrolling(false);
69
	  Window.setMargin("0px");
74
	  Window.setMargin("0px");
-
 
75
 
-
 
76
	  mediator.onInit();
-
 
77
	  
-
 
78
	  entryPanel.show();
70
 
79
	  
-
 
80
	  RootPanel.get().add(outer);
71
	  RootPanel.get().add(outer);
81
 
72
 
82
	  
73
 
83
 
74
  }
84
  }
75
  
85
  
76
  
86
  
-
 
87
 
77
 
88
  
78
 
89
 
79
}
90
}