Changeset 26903 in osm for applications/editors/josm
- Timestamp:
- 2011-10-18T19:57:18+02:00 (13 years ago)
- Location:
- applications/editors/josm/plugins/smed/plugs/oseam/src/oseam
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/msg/messages.properties
r26881 r26903 175 175 Source=Source 176 176 Elevation=Elevation 177 StructureHeight=Structure Height 177 Visibility=Visibility 178 Reflectivity=Reflectivity 179 Construction=Construction 178 180 181 NotSet=Not set -
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelCol.java
r26881 r26903 129 129 130 130 stack = new JPanel(); 131 stack.setBorder(BorderFactory.createL oweredBevelBorder());131 stack.setBorder(BorderFactory.createLineBorder(Color.black, 2)); 132 132 stack.setBounds(38, 87, 34, 64); 133 133 stack.setLayout(null); -
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelMore.java
r26881 r26903 51 51 public JLabel statusLabel; 52 52 public JComboBox statusBox; 53 public EnumMap<Sts, Integer> statuses = new EnumMap<Sts, Integer>(Sts.class); 53 54 private ActionListener alStatus = new ActionListener() { 54 55 public void actionPerformed(java.awt.event.ActionEvent e) { 55 if (dlg.mark == null) 56 return; 56 for (Sts sts : statuses.keySet()) { 57 int idx = statuses.get(sts); 58 if (dlg.mark != null && (idx == statusBox.getSelectedIndex())) 59 dlg.mark.setStatus(sts); 60 } 57 61 } 58 62 }; … … 194 198 elevBox.addActionListener(alElev); 195 199 196 heightLabel = new JLabel(Messages.getString(" StructureHeight"), SwingConstants.CENTER);197 heightLabel.setBounds(new Rectangle( 230, 0, 100, 20));200 heightLabel = new JLabel(Messages.getString("Height"), SwingConstants.CENTER); 201 heightLabel.setBounds(new Rectangle(140, 40, 90, 20)); 198 202 this.add(heightLabel, null); 199 203 heightBox = new JTextField(); 200 heightBox.setBounds(new Rectangle( 250, 20, 50, 20));204 heightBox.setBounds(new Rectangle(160, 60, 50, 20)); 201 205 this.add(heightBox, null); 202 206 heightBox.addActionListener(alHeight); 203 207 204 208 sourceLabel = new JLabel(Messages.getString("Source"), SwingConstants.CENTER); 205 sourceLabel.setBounds(new Rectangle(110, 120, 140, 20));209 sourceLabel.setBounds(new Rectangle(110, 80, 130, 20)); 206 210 this.add(sourceLabel, null); 207 211 sourceBox = new JTextField(); 208 sourceBox.setBounds(new Rectangle(110, 100, 1 40, 20));212 sourceBox.setBounds(new Rectangle(110, 100, 130, 20)); 209 213 this.add(sourceBox, null); 210 214 sourceBox.addActionListener(alSource); 211 215 212 216 infoLabel = new JLabel(Messages.getString("Information"), SwingConstants.CENTER); 213 infoLabel.setBounds(new Rectangle(110, 120, 1 40, 20));217 infoLabel.setBounds(new Rectangle(110, 120, 130, 20)); 214 218 this.add(infoLabel, null); 215 219 infoBox = new JTextField(); 216 infoBox.setBounds(new Rectangle(110, 140, 1 40, 20));220 infoBox.setBounds(new Rectangle(110, 140, 130, 20)); 217 221 this.add(infoBox, null); 218 222 infoBox.addActionListener(alInfo); 219 223 220 /*statusLabel = new JLabel(Messages.getString("Status"), SwingConstants.CENTER);221 statusLabel.setBounds(new Rectangle( 150, 0, 100, 20));224 statusLabel = new JLabel(Messages.getString("Status"), SwingConstants.CENTER); 225 statusLabel.setBounds(new Rectangle(250, 0, 100, 20)); 222 226 this.add(statusLabel, null); 223 227 statusBox = new JComboBox(); 224 statusBox.setBounds(new Rectangle(150, 20, 100, 20)); 228 statusBox.setBounds(new Rectangle(250, 20, 100, 20)); 229 addStsItem(Messages.getString("NotSet"), Sts.UNKNOWN); 225 230 this.add(statusBox, null); 226 231 statusBox.addActionListener(alStatus); 227 */ 232 233 constrLabel = new JLabel(Messages.getString("Construction"), SwingConstants.CENTER); 234 constrLabel.setBounds(new Rectangle(250, 40, 100, 20)); 235 this.add(constrLabel, null); 236 constrBox = new JComboBox(); 237 constrBox.setBounds(new Rectangle(250, 60, 100, 20)); 238 this.add(constrBox, null); 239 constrBox.addActionListener(alConstr); 240 241 conspLabel = new JLabel(Messages.getString("Reflectivity"), SwingConstants.CENTER); 242 conspLabel.setBounds(new Rectangle(250, 80, 100, 20)); 243 this.add(conspLabel, null); 244 conspBox = new JComboBox(); 245 conspBox.setBounds(new Rectangle(250, 100, 100, 20)); 246 this.add(conspBox, null); 247 conspBox.addActionListener(alConsp); 248 249 visLabel = new JLabel(Messages.getString("Visibility"), SwingConstants.CENTER); 250 visLabel.setBounds(new Rectangle(250, 120, 100, 20)); 251 this.add(visLabel, null); 252 visBox = new JComboBox(); 253 visBox.setBounds(new Rectangle(250, 140, 100, 20)); 254 this.add(visBox, null); 255 visBox.addActionListener(alVis); 256 228 257 } 229 258 230 259 public void clearSelections() { 231 260 panelPat.clearSelections(); 261 } 262 263 private void addStsItem(String str, Sts sts) { 264 statuses.put(sts, statusBox.getItemCount()); 265 statusBox.addItem(str); 232 266 } 233 267 -
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java
r26881 r26903 188 188 CatSTR.put(Cat.SIS_PTCL, "control"); 189 189 CatSTR.put(Cat.SIS_PTED, "entry"); 190 CatSTR.put(Cat.SIS_IPT, " ipt");190 CatSTR.put(Cat.SIS_IPT, "IPT"); 191 191 CatSTR.put(Cat.SIS_BRTH, "berthing"); 192 192 CatSTR.put(Cat.SIS_DOCK, "dock"); … … 624 624 } 625 625 626 public enum Sts { 627 UNKNOWN, PERM, OCC, REC, NIU, INT, RESV, TEMP, PRIV, MAND, DEST, EXT, ILLUM, HIST, PUB, SYNC, WATCH, UNWAT, DOUBT 628 } 629 630 public static final EnumMap<Sts, String> StsSTR = new EnumMap<Sts, String>(Sts.class); 631 static { 632 StsSTR.put(Sts.PERM, "permanent"); 633 StsSTR.put(Sts.OCC, "occasional"); 634 StsSTR.put(Sts.REC, "recommended"); 635 StsSTR.put(Sts.NIU, "not_in_use"); 636 StsSTR.put(Sts.INT, "intermittent"); 637 StsSTR.put(Sts.RESV, "reserved"); 638 StsSTR.put(Sts.TEMP, "tempory"); 639 StsSTR.put(Sts.PRIV, "private"); 640 StsSTR.put(Sts.MAND, "mandatory"); 641 StsSTR.put(Sts.DEST, "destroyed"); 642 StsSTR.put(Sts.EXT, "extinguished"); 643 StsSTR.put(Sts.ILLUM, "illuminated"); 644 StsSTR.put(Sts.HIST, "historic"); 645 StsSTR.put(Sts.PUB, "public"); 646 StsSTR.put(Sts.SYNC, "synchronized"); 647 StsSTR.put(Sts.WATCH, "watched"); 648 StsSTR.put(Sts.UNWAT, "unwatched"); 649 StsSTR.put(Sts.DOUBT, "existence_doubtful"); 650 } 651 652 private Sts status = Sts.UNKNOWN; 653 654 public Sts getStatus() { 655 return status; 656 } 657 658 public void setStatus(Sts sts) { 659 status = sts; 660 } 661 662 // **********************!!!!!!!!! 626 663 public Light light = new Light(dlg); 627 664
Note:
See TracChangeset
for help on using the changeset viewer.