Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/client/ui/ModuleSelection.java @ 45:f99c5f8e4672
Some GUI improvements in the Location/Distance, W/Q and Module panels.
flys-client/trunk@1490 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Thu, 17 Mar 2011 09:54:05 +0000 |
parents | 7142386e86c2 |
children | a2923d63f530 |
comparison
equal
deleted
inserted
replaced
44:3853210f2d18 | 45:f99c5f8e4672 |
---|---|
1 package de.intevation.flys.client.client.ui; | 1 package de.intevation.flys.client.client.ui; |
2 | |
3 import java.util.LinkedHashMap; | |
2 | 4 |
3 import com.google.gwt.core.client.GWT; | 5 import com.google.gwt.core.client.GWT; |
4 | 6 |
5 import com.smartgwt.client.widgets.Canvas; | 7 import com.smartgwt.client.widgets.Canvas; |
6 import com.smartgwt.client.widgets.IButton; | 8 import com.smartgwt.client.widgets.IButton; |
27 */ | 29 */ |
28 public class ModuleSelection extends MapSelection { | 30 public class ModuleSelection extends MapSelection { |
29 | 31 |
30 /** The message class that provides i18n strings.*/ | 32 /** The message class that provides i18n strings.*/ |
31 protected FLYSMessages MESSAGES = GWT.create(FLYSMessages.class); | 33 protected FLYSMessages MESSAGES = GWT.create(FLYSMessages.class); |
34 | |
35 | |
36 /** Constant field name for the plugin selection.*/ | |
37 public static final String FIELD_PLUGIN = "plugin"; | |
38 | |
39 /** Constant value for the WINFO plugin.*/ | |
40 public static final String FIELD_PLUGIN_WINFO = "winfo"; | |
41 | |
42 /** Constant value for the MINFO plugin.*/ | |
43 public static final String FIELD_PLUGIN_MINFO = "minfo"; | |
44 | |
45 /** Constant value for the MAP plugin.*/ | |
46 public static final String FIELD_PLUGIN_MAP = "map"; | |
47 | |
48 /** Constant value for the FIX plugin.*/ | |
49 public static final String FIELD_PLUGIN_FIX = "fix"; | |
50 | |
32 | 51 |
33 /** The module checkboxes.*/ | 52 /** The module checkboxes.*/ |
34 protected RadioGroupItem radio; | 53 protected RadioGroupItem radio; |
35 | 54 |
36 | 55 |
82 | 101 |
83 radio = new RadioGroupItem("plugin"); | 102 radio = new RadioGroupItem("plugin"); |
84 | 103 |
85 label.setWidth(50); | 104 label.setWidth(50); |
86 | 105 |
106 LinkedHashMap values = new LinkedHashMap(); | |
107 values.put(FIELD_PLUGIN_WINFO, messages.winfo()); | |
108 values.put(FIELD_PLUGIN_MINFO, messages.minfo()); | |
109 values.put(FIELD_PLUGIN_MAP, messages.map()); | |
110 values.put(FIELD_PLUGIN_FIX, messages.fix()); | |
111 | |
87 radio.setShowTitle(false); | 112 radio.setShowTitle(false); |
88 radio.setVertical(false); | 113 radio.setVertical(false); |
89 radio.setValueMap( | 114 radio.setValueMap(values); |
90 messages.winfo(), | 115 |
91 messages.minfo(), | 116 LinkedHashMap initial = new LinkedHashMap(); |
92 messages.map(), | 117 initial.put(FIELD_PLUGIN, FIELD_PLUGIN_WINFO); |
93 messages.fix()); | |
94 | 118 |
95 form.setFields(radio); | 119 form.setFields(radio); |
120 form.setValues(initial); | |
96 | 121 |
97 layout.addMember(label); | 122 layout.addMember(label); |
98 layout.addMember(form); | 123 layout.addMember(form); |
99 | 124 |
100 return layout; | 125 return layout; |