Changeset 22887 in osm for applications/editors/josm/plugins/toms
- Timestamp:
- 2010-08-30T13:18:42+02:00 (14 years ago)
- Location:
- applications/editors/josm/plugins/toms/src
- Files:
-
- 124 deleted
- 15 edited
Legend:
- Unmodified
- Added
- Removed
-
applications/editors/josm/plugins/toms/src/toms/dialogs/SmpDialogAction.java
r22850 r22887 114 114 private JLabel lM01Head = null; 115 115 public JLabel lM01Icon01 = null; 116 public JLabel lM01Icon02 = null; 116 117 public JToggleButton tbM01Region = null; 117 118 public JComboBox cbM01TypeOfMark = null; … … 515 516 lM01Icon01.setText(""); 516 517 518 lM01Icon02 = new JLabel(); 519 lM01Icon02.setBounds(new Rectangle(225, 0, 160, 200)); 520 lM01Icon02.setIcon(null); 521 lM01Icon02.setText(""); 522 517 523 pM01SeaMap = new JPanel(); 518 524 pM01SeaMap.setLayout(null); … … 527 533 pM01SeaMap.add(lM01Head, null); 528 534 pM01SeaMap.add(lM01Icon01, null); 535 pM01SeaMap.add(lM01Icon02, null); 529 536 pM01SeaMap.add(getTbM01Region(), null); 530 537 pM01SeaMap.add(getCbM01TypeOfMark(), null); … … 667 674 tbM01Region.setText("IALA-A"); 668 675 } 676 buoy.paintSign(); 669 677 } 670 678 }); -
applications/editors/josm/plugins/toms/src/toms/seamarks/buoys/Buoy.java
r22746 r22887 272 272 273 273 dlg.lM01Icon01.setIcon(null); 274 dlg.lM01Icon02.setIcon(null); 274 275 } 275 276 -
applications/editors/josm/plugins/toms/src/toms/seamarks/buoys/BuoyCard.java
r22732 r22887 37 37 dlg.tbM01Region.setEnabled(false); 38 38 39 setRegion(Main.pref.get("tomsplugin.IALA").equals("B")); 39 40 if (keys.containsKey("name")) 40 41 setName(keys.get("name")); … … 187 188 188 189 dlg.sM01StatusBar.setText(getErrMsg()); 190 dlg.lM01Icon02.setIcon(null); 189 191 190 192 dlg.tfM01Name.setEnabled(true); … … 239 241 } 240 242 241 if (!image.equals("")) { 243 if (!image.equals("/images/Cardinal")) { 244 image += ".png"; 245 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image))); 246 242 247 if (isFired()) { 243 image += "_Lit";248 dlg.lM01Icon02.setIcon(new ImageIcon(getClass().getResource("/images/Light_White_240.png"))); 244 249 245 250 if (getLightChar() != "") { … … 266 271 } 267 272 268 image += ".png";269 270 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image)));271 273 } else 272 274 dlg.lM01Icon01.setIcon(null); -
applications/editors/josm/plugins/toms/src/toms/seamarks/buoys/BuoyIsol.java
r22746 r22887 45 45 setBuoyIndex(ISOLATED_DANGER); 46 46 setTopMark(true); 47 setRegion(Main.pref.get("tomsplugin.IALA").equals("B")); 47 48 48 49 if (keys.containsKey("name")) … … 107 108 108 109 dlg.sM01StatusBar.setText(getErrMsg()); 110 dlg.lM01Icon02.setIcon(null); 109 111 110 112 dlg.tfM01Name.setEnabled(true); … … 135 137 136 138 if (!image.equals("/images/Cardinal")) { 139 image += ".png"; 140 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image))); 137 141 if (isFired()) { 138 image += "_Lit";142 dlg.lM01Icon02.setIcon(new ImageIcon(getClass().getResource("/images/Light_White_240.png"))); 139 143 if (getLightChar() != "") { 140 144 String c; … … 146 150 } 147 151 } 148 image += ".png";149 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image)));150 152 } else 151 153 dlg.lM01Icon01.setIcon(null); -
applications/editors/josm/plugins/toms/src/toms/seamarks/buoys/BuoyLat.java
r22836 r22887 301 301 302 302 dlg.sM01StatusBar.setText(getErrMsg()); 303 dlg.lM01Icon02.setIcon(null); 303 304 304 305 dlg.tfM01Name.setEnabled(true); … … 535 536 image += "_Cone"; 536 537 } 538 image += ".png"; 539 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image))); 537 540 538 541 if (isFired()) 539 image += "_Lit"; 542 if (getLightColour().equals("R")) 543 dlg.lM01Icon02.setIcon(new ImageIcon(getClass().getResource("/images/Light_Red_240.png"))); 544 else 545 dlg.lM01Icon02.setIcon(new ImageIcon(getClass().getResource("/images/Light_Green_240.png"))); 540 546 if (getLightChar() != "") { 541 547 String c; … … 550 556 } 551 557 552 image += ".png";553 554 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image)));555 558 } else 556 559 dlg.lM01Icon01.setIcon(null); -
applications/editors/josm/plugins/toms/src/toms/seamarks/buoys/BuoySaw.java
r22746 r22887 46 46 setLightColour("W"); 47 47 setBuoyIndex(SAFE_WATER); 48 setRegion(Main.pref.get("tomsplugin.IALA").equals("B")); 48 49 49 50 if (keys.containsKey("name")) … … 105 106 106 107 dlg.sM01StatusBar.setText(getErrMsg()); 108 dlg.lM01Icon02.setIcon(null); 107 109 108 110 dlg.tfM01Name.setEnabled(true); … … 133 135 134 136 if (!image.equals("/images/Safe_Water")) { 137 image += ".png"; 138 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image))); 135 139 136 140 if (hasTopMark()) … … 138 142 139 143 if (isFired()) { 140 image += "_Lit";144 dlg.lM01Icon02.setIcon(new ImageIcon(getClass().getResource("/images/Light_White_240.png"))); 141 145 if (getLightChar() != "") { 142 146 String c; … … 149 153 } 150 154 } 151 image += ".png";152 153 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image)));154 155 } else 155 156 dlg.lM01Icon01.setIcon(null); -
applications/editors/josm/plugins/toms/src/toms/seamarks/buoys/BuoySpec.java
r22865 r22887 56 56 setLightColour("W"); 57 57 setBuoyIndex(SPECIAL_PURPOSE); 58 setRegion(Main.pref.get("tomsplugin.IALA").equals("B")); 58 59 59 60 if (keys.containsKey("name")) … … 85 86 if ((keys.containsKey("seamark:type") && keys.get("seamark:type").equals( 86 87 "beacon_special_purpose")) 87 || keys.containsKey("seamark: special_purpose_beacon:colour")88 || keys.containsKey("seamark: special_purpose_beacon:shape")) {89 if (keys.containsKey("seamark: special_purpose_beacon:shape")90 && keys.get("seamark: soecial_purpose_beacon:shape").equals("tower"))88 || keys.containsKey("seamark:beacon_special_purpose:colour") 89 || keys.containsKey("seamark:beacon_special_purpose:shape")) { 90 if (keys.containsKey("seamark:beacon_special_purpose:shape") 91 && keys.get("seamark:beacon_special_purpose:shape").equals("tower")) 91 92 setStyleIndex(SPEC_TOWER); 92 93 else … … 142 143 143 144 dlg.sM01StatusBar.setText(getErrMsg()); 145 dlg.lM01Icon02.setIcon(null); 144 146 145 147 dlg.tfM01Name.setEnabled(true); … … 174 176 175 177 if (!image.equals("/images/Special_Purpose")) { 176 177 178 if (hasTopMark()) 178 179 image += "_CrossY"; 180 image += ".png"; 181 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image))); 179 182 180 183 if (isFired()) { 181 image += "_Lit";184 dlg.lM01Icon02.setIcon(new ImageIcon(getClass().getResource("/images/Light_White_240.png"))); 182 185 if (getLightChar() != "") { 183 186 String c; … … 190 193 } 191 194 } 192 image += ".png";193 194 dlg.lM01Icon01.setIcon(new ImageIcon(getClass().getResource(image)));195 195 } else 196 196 dlg.lM01Icon01.setIcon(null); -
applications/editors/josm/plugins/toms/src/toms/seamarks/buoys/BuoyUkn.java
r22732 r22887 4 4 package toms.seamarks.buoys; 5 5 6 import org.openstreetmap.josm.Main; 6 7 import org.openstreetmap.josm.data.osm.Node; 7 8 … … 31 32 setValid(false); 32 33 setBuoyIndex(0); 34 setRegion(Main.pref.get("tomsplugin.IALA").equals("B")); 33 35 } 34 36 … … 36 38 super.paintSign(); 37 39 38 if (dlg.lM01Icon01 != null)39 dlg.lM01Icon01.setIcon(null);40 dlg.lM01Icon01.setIcon(null); 41 dlg.lM01Icon02.setIcon(null); 40 42 if (getErrMsg() != null) 41 43 dlg.sM01StatusBar.setText(getErrMsg());
Note:
See TracChangeset
for help on using the changeset viewer.