Changeset 27199 in osm for applications/editors/josm
- Timestamp:
- 2011-12-09T22:33:27+01: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/dialogs/OSeaMAction.java
r27189 r27199 38 38 mark = new SeaMark(dlg); 39 39 mark.setBounds(new Rectangle(235, 0, 165, 160)); 40 panelMain.add(mark , 0);40 panelMain.add(mark); 41 41 mark.parseMark(node); 42 42 } -
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelLights.java
r27189 r27199 124 124 125 125 categoryLabel = new JLabel(Messages.getString("Category"), SwingConstants.CENTER); 126 categoryLabel.setBounds(new Rectangle( 10, 80, 160, 20));126 categoryLabel.setBounds(new Rectangle(5, 80, 160, 20)); 127 127 this.add(categoryLabel, null); 128 128 categoryLabel.setVisible(false); 129 129 130 130 landCatBox = new JComboBox(); 131 landCatBox.setBounds(new Rectangle( 10, 100, 160, 20));131 landCatBox.setBounds(new Rectangle(5, 100, 160, 20)); 132 132 this.add(landCatBox, null); 133 133 landCatBox.addActionListener(alLandCatBox); … … 156 156 157 157 trafficCatBox = new JComboBox(); 158 trafficCatBox.setBounds(new Rectangle( 10, 100, 160, 20));158 trafficCatBox.setBounds(new Rectangle(5, 100, 160, 20)); 159 159 this.add(trafficCatBox, null); 160 160 trafficCatBox.addActionListener(alTrafficCatBox); -
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelMain.java
r27189 r27199 43 43 public void actionPerformed(java.awt.event.ActionEvent e) { 44 44 if (panelMore.isVisible()) { 45 moreButton.setText(" v v v");45 moreButton.setText(">>"); 46 46 panelMore.setVisible(false); 47 47 topButton.setEnabled(true); … … 51 51 } else { 52 52 panelMore.setVisible(true); 53 moreButton.setText(" ^ ^ ^");53 moreButton.setText("<<"); 54 54 miscButtons.clearSelection(); 55 55 panelTop.setVisible(false); … … 121 121 public void actionPerformed(java.awt.event.ActionEvent e) { 122 122 if (topButton.isSelected()) { 123 moreButton.setText(" v v v");123 moreButton.setText(">>"); 124 124 panelMore.setVisible(false); 125 125 topButton.setBorderPainted(true); … … 130 130 } 131 131 if (fogButton.isSelected()) { 132 moreButton.setText(" v v v");132 moreButton.setText(">>"); 133 133 panelMore.setVisible(false); 134 134 fogButton.setBorderPainted(true); … … 139 139 } 140 140 if (radButton.isSelected()) { 141 moreButton.setText(" v v v");141 moreButton.setText(">>"); 142 142 panelMore.setVisible(false); 143 143 radButton.setBorderPainted(true); … … 148 148 } 149 149 if (litButton.isSelected()) { 150 moreButton.setText(" v v v");150 moreButton.setText(">>"); 151 151 panelMore.setVisible(false); 152 152 litButton.setBorderPainted(true); … … 163 163 dlg = dia; 164 164 panelChan = new PanelChan(dlg); 165 panelChan.setBounds(new Rectangle(65, 0, 1 85, 160));165 panelChan.setBounds(new Rectangle(65, 0, 170, 160)); 166 166 panelChan.setVisible(false); 167 167 panelHaz = new PanelHaz(dlg); 168 panelHaz.setBounds(new Rectangle(65, 0, 1 85, 160));168 panelHaz.setBounds(new Rectangle(65, 0, 170, 160)); 169 169 panelHaz.setVisible(false); 170 170 panelSpec = new PanelSpec(dlg); 171 panelSpec.setBounds(new Rectangle(65, 0, 1 85, 160));171 panelSpec.setBounds(new Rectangle(65, 0, 170, 160)); 172 172 panelSpec.setVisible(false); 173 173 panelLights = new PanelLights(dlg); 174 panelLights.setBounds(new Rectangle(65, 0, 1 85, 160));174 panelLights.setBounds(new Rectangle(65, 0, 170, 160)); 175 175 panelLights.setVisible(false); 176 176 panelMore = new PanelMore(dlg); … … 213 213 lightsButton.addActionListener(alType); 214 214 215 this.add(getButton(topButton, 0, 1 65, 34, 32, "Topmarks"), null);216 this.add(getButton(fogButton, 0, 2 05, 34, 32, "FogSignals"), null);217 this.add(getButton(radButton, 0, 2 45, 34, 32, "Radar"), null);218 this.add(getButton(litButton, 0, 2 85, 34, 32, "Lit"), null);215 this.add(getButton(topButton, 0, 185, 34, 32, "Topmarks"), null); 216 this.add(getButton(fogButton, 0, 220, 34, 32, "FogSignals"), null); 217 this.add(getButton(radButton, 0, 255, 34, 32, "Radar"), null); 218 this.add(getButton(litButton, 0, 290, 34, 32, "Lit"), null); 219 219 miscButtons = new ButtonGroup(); 220 220 miscButtons.add(topButton); … … 244 244 245 245 moreButton = new JButton(); 246 moreButton.setBounds(new Rectangle( 190, 145, 40, 15));246 moreButton.setBounds(new Rectangle(0, 165, 34, 15)); 247 247 moreButton.setMargin(new Insets(0, 0, 0, 0)); 248 moreButton.setText(" v v v");248 moreButton.setText(">>"); 249 249 this.add(moreButton, null); 250 250 moreButton.addActionListener(alMore); … … 273 273 saveButton.setEnabled(false); 274 274 moreButton.setVisible(false); 275 moreButton.setText(" v v v");275 moreButton.setText(">>"); 276 276 moreButton.setSelected(false); 277 277 panelChan.setVisible(false); -
applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java
r27189 r27199 1082 1082 } else { 1083 1083 dlg.panelMain.moreButton.setVisible(false); 1084 dlg.panelMain.moreButton.setText(" v v v");1084 dlg.panelMain.moreButton.setText(">>"); 1085 1085 dlg.panelMain.topButton.setEnabled(false); 1086 1086 dlg.panelMain.fogButton.setEnabled(false); … … 1619 1619 1620 1620 Graphics2D g2 = (Graphics2D) g; 1621 1621 1622 if (dlg.mark == null) { 1623 return; 1624 } 1625 1622 1626 String colStr; 1623 1627 String lblStr; … … 1741 1745 System.out.println("Missing image: " + imgStr); 1742 1746 } else { 1743 g .drawImage(new ImageIcon(getClass().getResource(imgStr)).getImage(), 7, -15, null);1744 g .drawString(lblStr, 75, 110);1747 g2.drawImage(new ImageIcon(getClass().getResource(imgStr)).getImage(), 7, -15, null); 1748 g2.drawString(lblStr, 75, 110); 1745 1749 } 1746 1750 } else { 1747 g .drawImage(new ImageIcon(getClass().getResource(colStr)).getImage(), 7, -15, null);1751 g2.drawImage(new ImageIcon(getClass().getResource(colStr)).getImage(), 7, -15, null); 1748 1752 } 1749 1753 } … … 1811 1815 System.out.println("Missing image: " + imgStr); 1812 1816 } else { 1813 g .drawImage(new ImageIcon(getClass().getResource(imgStr)).getImage(), 7, -15, null);1817 g2.drawImage(new ImageIcon(getClass().getResource(imgStr)).getImage(), 7, -15, null); 1814 1818 } 1815 1819 } … … 1918 1922 return; 1919 1923 } else { 1920 g .drawImage(new ImageIcon(getClass().getResource(imgStr)).getImage(), 7, -15, null);1924 g2.drawImage(new ImageIcon(getClass().getResource(imgStr)).getImage(), 7, -15, null); 1921 1925 } 1922 1926 } else { 1923 g .drawImage(new ImageIcon(getClass().getResource(colStr)).getImage(), 7, -15, null);1927 g2.drawImage(new ImageIcon(getClass().getResource(colStr)).getImage(), 7, -15, null); 1924 1928 } 1925 1929 } … … 1941 1945 switch ((Col) getLightAtt(Att.COL, 0)) { 1942 1946 case RED: 1943 g .drawImage(new ImageIcon(getClass().getResource("/images/Light_Red_120.png")).getImage(), 7, -15, null);1947 g2.drawImage(new ImageIcon(getClass().getResource("/images/Light_Red_120.png")).getImage(), 7, -15, null); 1944 1948 break; 1945 1949 case GREEN: 1946 g .drawImage(new ImageIcon(getClass().getResource("/images/Light_Green_120.png")).getImage(), 7, -15, null);1950 g2.drawImage(new ImageIcon(getClass().getResource("/images/Light_Green_120.png")).getImage(), 7, -15, null); 1947 1951 break; 1948 1952 case WHITE: 1949 1953 case YELLOW: 1950 g .drawImage(new ImageIcon(getClass().getResource("/images/Light_White_120.png")).getImage(), 7, -15, null);1954 g2.drawImage(new ImageIcon(getClass().getResource("/images/Light_White_120.png")).getImage(), 7, -15, null); 1951 1955 break; 1952 1956 default: 1953 g .drawImage(new ImageIcon(getClass().getResource("/images/Light_Magenta_120.png")).getImage(), 7, -15, null);1957 g2.drawImage(new ImageIcon(getClass().getResource("/images/Light_Magenta_120.png")).getImage(), 7, -15, null); 1954 1958 } 1955 1959 } … … 2003 2007 if (!tmp.isEmpty()) 2004 2008 c += " " + tmp + "s"; 2005 g .drawString(c, 100, 70);2009 g2.drawString(c, 100, 70); 2006 2010 } 2007 2011 2008 2012 if (getFogSound() != Fog.NONE) { 2009 g .drawImage(new ImageIcon(getClass().getResource("/images/Fog_Signal.png")).getImage(), 7, -15, null);2013 g2.drawImage(new ImageIcon(getClass().getResource("/images/Fog_Signal.png")).getImage(), 7, -15, null); 2010 2014 String str = ""; 2011 2015 if (getFogSound() != Fog.UNKNOWN) … … 2039 2043 if (!getFogPeriod().isEmpty()) 2040 2044 str += getFogPeriod() + "s"; 2041 g .drawString(str, 0, 70);2045 g2.drawString(str, 0, 70); 2042 2046 } 2043 2047 2044 2048 if (RaType != Rtb.NONE) { 2045 2049 if (getRadar() == Rtb.REFLECTOR) { 2046 g .drawImage(new ImageIcon(getClass().getResource("/images/Radar_Reflector_355.png")).getImage(), 7, -15, null);2050 g2.drawImage(new ImageIcon(getClass().getResource("/images/Radar_Reflector_355.png")).getImage(), 7, -15, null); 2047 2051 } else { 2048 g .drawImage(new ImageIcon(getClass().getResource("/images/Radar_Station.png")).getImage(), 7, -15, null);2052 g2.drawImage(new ImageIcon(getClass().getResource("/images/Radar_Station.png")).getImage(), 7, -15, null); 2049 2053 String str = ""; 2050 2054 if (getRadar() == Rtb.RAMARK) … … 2058 2062 if (!getRaconPeriod().isEmpty()) 2059 2063 str += getRaconPeriod() + "s"; 2060 g.drawString(str, 0, 50); 2061 } 2062 } 2063 2064 g2.drawString(str, 0, 50); 2065 } 2066 } 2064 2067 } 2065 2068
Note:
See TracChangeset
for help on using the changeset viewer.