Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/client/ui/MainMenu.java @ 4558:9d7497f5be05
Remove the new project button from the menue
author | Björn Ricks <bjoern.ricks@intevation.de> |
---|---|
date | Fri, 16 Nov 2012 14:25:05 +0100 |
parents | a04862abce42 |
children |
comparison
equal
deleted
inserted
replaced
4557:ebc22575e413 | 4558:9d7497f5be05 |
---|---|
38 protected Label userText; | 38 protected Label userText; |
39 | 39 |
40 /** The button to log the current user out.*/ | 40 /** The button to log the current user out.*/ |
41 protected Button logout; | 41 protected Button logout; |
42 | 42 |
43 /** The button to add new projects.*/ | |
44 protected Button newProject; | |
45 | |
46 /** The button to open the project list.*/ | 43 /** The button to open the project list.*/ |
47 protected Button projectList; | 44 protected Button projectList; |
48 | 45 |
49 /** The button to switch between the english and german version.*/ | 46 /** The button to switch between the english and german version.*/ |
50 protected Button language; | 47 protected Button language; |
62 this.flys = flys; | 59 this.flys = flys; |
63 | 60 |
64 String guest = messages.user() + " " + messages.guest(); | 61 String guest = messages.user() + " " + messages.guest(); |
65 | 62 |
66 userText = new Label(guest); | 63 userText = new Label(guest); |
67 newProject = new Button(messages.new_project()); | |
68 projectList = new Button(messages.manage_projects()); | 64 projectList = new Button(messages.manage_projects()); |
69 logout = new Button(messages.logout()); | 65 logout = new Button(messages.logout()); |
70 language = new Button(messages.switch_language()); | 66 language = new Button(messages.switch_language()); |
71 info = new Button(messages.info()); | 67 info = new Button(messages.info()); |
72 | |
73 newProject.addClickHandler(new ClickHandler() { | |
74 @Override | |
75 public void onClick(ClickEvent event) { | |
76 GWT.log("Clicked 'New Project' button."); | |
77 createNewProject(); | |
78 } | |
79 }); | |
80 | 68 |
81 projectList.addClickHandler(new ClickHandler() { | 69 projectList.addClickHandler(new ClickHandler() { |
82 @Override | 70 @Override |
83 public void onClick(ClickEvent event) { | 71 public void onClick(ClickEvent event) { |
84 GWT.log("Clicked 'Open ProjectList' button."); | 72 GWT.log("Clicked 'Open ProjectList' button."); |
149 protected void init() { | 137 protected void init() { |
150 setStyleName("bgBlueDark"); | 138 setStyleName("bgBlueDark"); |
151 setHeight("25px"); | 139 setHeight("25px"); |
152 setLayoutMargin(5); | 140 setLayoutMargin(5); |
153 | 141 |
154 newProject.setStyleName("fontLightSmall"); | |
155 projectList.setStyleName("fontLightSmall"); | 142 projectList.setStyleName("fontLightSmall"); |
156 userText.setStyleName("fontLightSmall"); | 143 userText.setStyleName("fontLightSmall"); |
157 newProject.setStyleName("fontLightSmall"); | |
158 logout.setStyleName("fontLightSmall"); | 144 logout.setStyleName("fontLightSmall"); |
159 language.setStyleName("fontLightSmall"); | 145 language.setStyleName("fontLightSmall"); |
160 info.setStyleName("fontLightSmall"); | 146 info.setStyleName("fontLightSmall"); |
161 | 147 |
162 projectList.setWidth("140px"); | 148 projectList.setWidth("140px"); |
163 | 149 |
164 HLayout leftPanel = new HLayout(); | 150 HLayout leftPanel = new HLayout(); |
165 leftPanel.setWidth("80%"); | 151 leftPanel.setWidth("80%"); |
166 leftPanel.setMembersMargin(5); | 152 leftPanel.setMembersMargin(5); |
167 leftPanel.addMember(newProject); | |
168 leftPanel.addMember(projectList); | 153 leftPanel.addMember(projectList); |
169 | 154 |
170 userText.setAlign(Alignment.RIGHT); | 155 userText.setAlign(Alignment.RIGHT); |
171 userText.setWidth(200); | 156 userText.setWidth(200); |
172 logout.setWidth(70); | 157 logout.setWidth(70); |