Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/client/ui/PeriodPanel.java @ 4184:03de5c424f95
Fix warnings and minor TODOs in flys-client.
author | Christian Lins <christian.lins@intevation.de> |
---|---|
date | Fri, 19 Oct 2012 09:29:57 +0200 |
parents | 0de61fc9d281 |
children |
comparison
equal
deleted
inserted
replaced
4183:1755a1bfe5ce | 4184:03de5c424f95 |
---|---|
1 package de.intevation.flys.client.client.ui; | 1 package de.intevation.flys.client.client.ui; |
2 | 2 |
3 import com.google.gwt.core.client.GWT; | 3 import com.google.gwt.core.client.GWT; |
4 | |
5 import com.google.gwt.i18n.client.DateTimeFormat.PredefinedFormat; | |
6 | |
7 import com.google.gwt.i18n.client.DateTimeFormat; | 4 import com.google.gwt.i18n.client.DateTimeFormat; |
8 | 5 |
9 import com.smartgwt.client.util.SC; | 6 import com.smartgwt.client.util.SC; |
10 | |
11 import com.smartgwt.client.widgets.Canvas; | 7 import com.smartgwt.client.widgets.Canvas; |
12 import com.smartgwt.client.widgets.Label; | 8 import com.smartgwt.client.widgets.Label; |
13 | |
14 import com.smartgwt.client.widgets.form.DynamicForm; | 9 import com.smartgwt.client.widgets.form.DynamicForm; |
15 | |
16 import com.smartgwt.client.widgets.form.fields.DateRangeItem; | 10 import com.smartgwt.client.widgets.form.fields.DateRangeItem; |
17 | |
18 import com.smartgwt.client.widgets.layout.HLayout; | 11 import com.smartgwt.client.widgets.layout.HLayout; |
19 import com.smartgwt.client.widgets.layout.VLayout; | 12 import com.smartgwt.client.widgets.layout.VLayout; |
20 | 13 |
21 import de.intevation.flys.client.client.FLYSConstants; | 14 import de.intevation.flys.client.client.FLYSConstants; |
22 | |
23 import de.intevation.flys.client.shared.model.Data; | 15 import de.intevation.flys.client.shared.model.Data; |
24 import de.intevation.flys.client.shared.model.DataItem; | 16 import de.intevation.flys.client.shared.model.DataItem; |
25 import de.intevation.flys.client.shared.model.DataList; | 17 import de.intevation.flys.client.shared.model.DataList; |
26 import de.intevation.flys.client.shared.model.DefaultData; | 18 import de.intevation.flys.client.shared.model.DefaultData; |
27 import de.intevation.flys.client.shared.model.DefaultDataItem; | 19 import de.intevation.flys.client.shared.model.DefaultDataItem; |
36 * @author <a href="mailto:raimund.renkert@intevation.de">Raimund Renkert</a> | 28 * @author <a href="mailto:raimund.renkert@intevation.de">Raimund Renkert</a> |
37 */ | 29 */ |
38 public class PeriodPanel | 30 public class PeriodPanel |
39 extends AbstractUIProvider | 31 extends AbstractUIProvider |
40 { | 32 { |
33 private static final long serialVersionUID = -5249560815807538821L; | |
34 | |
41 /** The message class that provides i18n strings. */ | 35 /** The message class that provides i18n strings. */ |
42 protected FLYSConstants MSG = GWT.create(FLYSConstants.class); | 36 protected FLYSConstants MSG = GWT.create(FLYSConstants.class); |
43 | 37 |
44 DateRangeItem inputPanel; | 38 DateRangeItem inputPanel; |
45 | 39 |
57 this.startName = startName; | 51 this.startName = startName; |
58 this.endName = endName; | 52 this.endName = endName; |
59 } | 53 } |
60 | 54 |
61 | 55 |
56 @Override | |
62 public Canvas create(DataList list) { | 57 public Canvas create(DataList list) { |
63 VLayout layout = new VLayout(); | 58 VLayout layout = new VLayout(); |
64 | 59 |
65 Canvas helper = createHelper(); | 60 Canvas helper = createHelper(); |
66 this.helperContainer.addMember(helper); | 61 this.helperContainer.addMember(helper); |
150 /** | 145 /** |
151 * This method returns the selected data. | 146 * This method returns the selected data. |
152 * | 147 * |
153 * @return the selected/inserted data. | 148 * @return the selected/inserted data. |
154 */ | 149 */ |
150 @Override | |
155 public Data[] getData() { | 151 public Data[] getData() { |
156 List<Data> data = new ArrayList<Data>(); | 152 List<Data> data = new ArrayList<Data>(); |
157 | 153 |
158 boolean valid = saveDateValues(); | 154 boolean valid = saveDateValues(); |
159 if(valid) { | 155 if(valid) { |