Index: applications/editors/josm/plugins/smed/build.xml
===================================================================
--- applications/editors/josm/plugins/smed/build.xml	(revision 24765)
+++ applications/editors/josm/plugins/smed/build.xml	(revision 24778)
@@ -28,5 +28,5 @@
 **
 -->
-<project name="smed" basedir=".">
+<project name="SeaMapEditor" basedir=".">
 
 	<!-- enter the SVN commit message -->
Index: applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/OSeaM.java
===================================================================
--- applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/OSeaM.java	(revision 24765)
+++ applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/OSeaM.java	(revision 24778)
@@ -8,4 +8,6 @@
 import javax.swing.ImageIcon;
 import javax.swing.JComponent;
+
+import org.openstreetmap.josm.data.osm.DataSet;
 
 import smed.plug.ifc.SmedPluggable;
@@ -22,4 +24,5 @@
 	public boolean start() {
 		// TODO Auto-generated method stub
+System.out.println("start");
 		return false;
 	}
@@ -27,5 +30,6 @@
 	@Override
 	public boolean stop() {
-		// TODO Auto-generated method stub
+		DataSet.removeSelectionListener(oseam.SmpListener);
+System.out.println("stop");
 		return false;
 	}
@@ -33,4 +37,6 @@
 	@Override
 	public boolean hasFocus() {
+System.out.println("hasFocus");
+		DataSet.addSelectionListener(oseam.SmpListener);
 		return false;
 	}
@@ -38,5 +44,6 @@
 	@Override
 	public boolean lostFocus() {
-		// TODO Auto-generated method stub
+		DataSet.removeSelectionListener(oseam.SmpListener);
+System.out.println("lostFocus");
 		return false;
 	}
Index: applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/dialogs/OSeaMAction.java
===================================================================
--- applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/dialogs/OSeaMAction.java	(revision 24765)
+++ applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/dialogs/OSeaMAction.java	(revision 24778)
@@ -45,39 +45,40 @@
 import oseam.Messages;
 import oseam.OSeaM;
+import oseam.seamarks.SeaMark;
 
 public class OSeaMAction {
 
-	private JPanel oseamPanel = null;
-
-	private JLabel shapeIcon = null;
-	private JLabel lightIcon = null;
-	private JLabel topIcon = null;
-	private JLabel reflIcon = null;
-	private JLabel radarIcon = null;
-	private JLabel fogIcon = null;
-	private JLabel nameLabel = null;
-	private JTextField nameBox = null;
-	private JButton saveButton = null;
-	private ButtonGroup typeButtons = null;
-	private JRadioButton chanButton = null;
-	private JRadioButton hazButton = null;
-	private JRadioButton specButton = null;
-	private JRadioButton lightsButton = null;
-	private ButtonGroup miscButtons = null;
-	private JRadioButton topButton = null;
-	private JRadioButton fogButton = null;
-	private JRadioButton radarButton = null;
-	private JRadioButton litButton = null;
-	private PanelChan panelChan = null;
-	private PanelHaz panelHaz = null;
-	private PanelSpec panelSpec = null;
-	private PanelLights panelLights = null;
-	private PanelTop panelTop = null;
-	private PanelFog panelFog = null;
-	private PanelRadar panelRadar = null;
-	private PanelLit panelLit = null;
+	private OSeaMAction dia = null;
+	private PanelMain panelMain = null;
+
+	private SeaMark mark = null;
+	private Collection<? extends OsmPrimitive> Selection = null;
+	private OsmPrimitive SelNode = null;
+
+	public SelectionChangedListener SmpListener = new SelectionChangedListener() {
+		public void selectionChanged(Collection<? extends OsmPrimitive> newSelection) {
+			Node node;
+			Selection = newSelection;
+
+System.out.println("SmpListener");
+			for (OsmPrimitive osm : Selection) {
+				if (osm instanceof Node) {
+					node = (Node) osm;
+					if (Selection.size() == 1)
+						if (node.compareTo(SelNode) != 0) {
+							SelNode = node;
+System.out.println(node);
+//							parseSeaMark();
+//							mark.paintSign();
+						}
+				}
+			}
+			Selection = null;
+		}
+	};
 
 	public OSeaMAction() {
 
+		dia = this;
 		String str = Main.pref.get("mappaint.style.sources");
 		if (!str.contains("dev.openseamap.org")) {
@@ -90,263 +91,182 @@
 		if (str.equals("#000000") || str.isEmpty())
 			Main.pref.put("color.background", "#606060");
-
-		panelChan = new PanelChan();
-		panelChan.setBounds(new Rectangle(65, 0, 335, 160));
-		panelChan.setVisible(false);
-		panelHaz = new PanelHaz();
-		panelHaz.setBounds(new Rectangle(65, 0, 335, 160));
-		panelHaz.setVisible(false);
-		panelSpec = new PanelSpec();
-		panelSpec.setBounds(new Rectangle(65, 0, 335, 160));
-		panelSpec.setVisible(false);
-		panelLights = new PanelLights();
-		panelLights.setBounds(new Rectangle(65, 0, 335, 160));
-		panelLights.setVisible(false);
-		panelTop = new PanelTop();
-		panelTop.setBounds(new Rectangle(40, 165, 220, 160));
-		panelTop.setVisible(false);
-		panelFog = new PanelFog();
-		panelFog.setBounds(new Rectangle(40, 165, 220, 160));
-		panelFog.setVisible(false);
-		panelRadar = new PanelRadar();
-		panelRadar.setBounds(new Rectangle(40, 165, 220, 160));
-		panelRadar.setVisible(false);
-		panelLit = new PanelLit();
-		panelLit.setBounds(new Rectangle(40, 165, 220, 160));
-		panelLit.setVisible(false);
+System.out.println("newOSeaMAction");
 	}
 
 	public JPanel getOSeaMPanel() {
-		if (oseamPanel == null) {
-			oseamPanel = new JPanel();
-			oseamPanel.setLayout(null);
-			oseamPanel.setSize(new Dimension(400, 360));
-
-			shapeIcon = new JLabel(new ImageIcon(getClass().getResource(
-					"/images/Cardinal_Pillar_South.png")));
-			shapeIcon.setBounds(new Rectangle(265, 170, 130, 185));
-			oseamPanel.add(shapeIcon, null);
-			lightIcon = new JLabel(new ImageIcon(getClass().getResource(
-					"/images/Light_White_120.png")));
-			lightIcon.setBounds(new Rectangle(265, 170, 125, 185));
-			oseamPanel.add(lightIcon, null);
-			topIcon = new JLabel();
-			topIcon.setBounds(new Rectangle(265, 170, 125, 185));
-			oseamPanel.add(topIcon, null);
-			reflIcon = new JLabel(new ImageIcon(getClass().getResource(
-					"/images/Radar_Reflector_355.png")));
-			reflIcon.setBounds(new Rectangle(265, 170, 125, 185));
-			oseamPanel.add(reflIcon, null);
-			radarIcon = new JLabel(new ImageIcon(getClass().getResource(
-					"/images/Radar_Station.png")));
-			radarIcon.setBounds(new Rectangle(265, 170, 130, 185));
-			oseamPanel.add(radarIcon, null);
-			fogIcon = new JLabel(new ImageIcon(getClass().getResource(
-					"/images/Fog_Signal.png")));
-			fogIcon.setBounds(new Rectangle(265, 170, 125, 185));
-			oseamPanel.add(fogIcon, null);
-
-			oseamPanel.add(getChanButton(), null);
-			oseamPanel.add(getHazButton(), null);
-			oseamPanel.add(getSpecButton(), null);
-			oseamPanel.add(getLightsButton(), null);
-			oseamPanel.add(panelChan, null);
-			oseamPanel.add(panelHaz, null);
-			oseamPanel.add(panelSpec, null);
-			oseamPanel.add(panelLights, null);
-			oseamPanel.add(panelTop, null);
-			oseamPanel.add(panelFog, null);
-			oseamPanel.add(panelRadar, null);
-			oseamPanel.add(panelLit, null);
-			typeButtons = new ButtonGroup();
-			typeButtons.add(chanButton);
-			typeButtons.add(hazButton);
-			typeButtons.add(specButton);
-			typeButtons.add(lightsButton);
-			ActionListener alType = new ActionListener() {
-				public void actionPerformed(java.awt.event.ActionEvent e) {
-					if (chanButton.isSelected()) {
-				        chanButton.setBorderPainted(true);
-						panelChan.setVisible(true);
-					} else {
-				        chanButton.setBorderPainted(false);
-						panelChan.setVisible(false);
-					}
-					if (hazButton.isSelected()) {
-				        hazButton.setBorderPainted(true);
-						panelHaz.setVisible(true);
-					} else {
-				        hazButton.setBorderPainted(false);
-						panelHaz.setVisible(false);
-					}
-					if (specButton.isSelected()) {
-				        specButton.setBorderPainted(true);
-						panelSpec.setVisible(true);
-					} else {
-				        specButton.setBorderPainted(false);
-						panelSpec.setVisible(false);
-					}
-					if (lightsButton.isSelected()) {
-				        lightsButton.setBorderPainted(true);
-						panelLights.setVisible(true);
-					} else {
-				        lightsButton.setBorderPainted(false);
-						panelLights.setVisible(false);
-					}
-				}
-			};
-			chanButton.addActionListener(alType);
-			hazButton.addActionListener(alType);
-			specButton.addActionListener(alType);
-			lightsButton.addActionListener(alType);
-
-			oseamPanel.add(getTopButton(), null);
-			oseamPanel.add(getFogButton(), null);
-			oseamPanel.add(getRadarButton(), null);
-			oseamPanel.add(getLitButton(), null);
-			miscButtons = new ButtonGroup();
-			miscButtons.add(topButton);
-			miscButtons.add(fogButton);
-			miscButtons.add(radarButton);
-			miscButtons.add(litButton);
-			ActionListener alMisc = new ActionListener() {
-				public void actionPerformed(java.awt.event.ActionEvent e) {
-					if (topButton.isSelected()) {
-						topButton.setBorderPainted(true);
-						panelTop.setVisible(true);
-					} else {
-						topButton.setBorderPainted(false);
-						panelTop.setVisible(false);
-					}
-					if (fogButton.isSelected()) {
-						fogButton.setBorderPainted(true);
-						panelFog.setVisible(true);
-					} else {
-						fogButton.setBorderPainted(false);
-						panelFog.setVisible(false);
-					}
-					if (radarButton.isSelected()) {
-						radarButton.setBorderPainted(true);
-						panelRadar.setVisible(true);
-					} else {
-						radarButton.setBorderPainted(false);
-						panelRadar.setVisible(false);
-					}
-					if (litButton.isSelected()) {
-						litButton.setBorderPainted(true);
-						panelLit.setVisible(true);
-					} else {
-						litButton.setBorderPainted(false);
-						panelLit.setVisible(false);
-					}
-				}
-			};
-			topButton.addActionListener(alMisc);
-			fogButton.addActionListener(alMisc);
-			radarButton.addActionListener(alMisc);
-			litButton.addActionListener(alMisc);
-
-			nameLabel = new JLabel();
-			nameLabel.setBounds(new Rectangle(5, 329, 60, 20));
-			nameLabel.setText(tr("Name:"));
-			oseamPanel.add(nameLabel, null);
-			nameBox = new JTextField();
-			nameBox.setBounds(new Rectangle(60, 330, 200, 20));
-			oseamPanel.add(nameBox, null);
-			saveButton = new JButton();
-			saveButton.setBounds(new Rectangle(285, 330, 100, 20));
-			saveButton.setText(tr("Save"));
-			oseamPanel.add(saveButton, null);
-		}
-		return oseamPanel;
+		if (panelMain == null) {
+			panelMain = new PanelMain();
+			panelMain.setLayout(null);
+			panelMain.setSize(new Dimension(400, 360));
+		}
+		return panelMain;
 	}
-
-	private JRadioButton getChanButton() {
-		if (chanButton == null) {
-			chanButton = new JRadioButton(new ImageIcon(getClass().getResource(
-					"/images/ChanButton.png")));
-			chanButton.setBounds(new Rectangle(0, 0, 62, 40));
-	        chanButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			chanButton.setToolTipText(Messages.getString("ChanTip"));
-		}
-		return chanButton;
+/*
+	private void parseSeaMark() {
+
+		int nodes = 0;
+		Node node = null;
+		Collection<Node> selection = null;
+		Map<String, String> keys;
+		DataSet ds;
+
+		ds = Main.main.getCurrentDataSet();
+
+		if (ds == null) {
+			mark = new MarkUkn(this, Messages.getString("SmpDialogAction.26"));
+			mark.setNode(null);
+			return;
+		}
+
+		selection = ds.getSelectedNodes();
+		nodes = selection.size();
+
+		if (nodes == 0) {
+			mark = new MarkUkn(this, Messages.getString("SmpDialogAction.27"));
+			mark.setNode(null);
+			return;
+		}
+
+		if (nodes > 1) {
+			mark = new MarkUkn(this, Messages.getString("SmpDialogAction.28"));
+			mark.setNode(null);
+			return;
+		}
+
+		Iterator<Node> it = selection.iterator();
+		node = it.next();
+
+		cM01IconVisible.setEnabled(true);
+		cM01IconVisible.setIcon(new ImageIcon(getClass().getResource(
+				"/images/Auge.png"))); //$NON-NLS-1$
+
+		cbM01TypeOfMark.setEnabled(true);
+
+		String type = "";
+		String str = "";
+
+		keys = node.getKeys();
+
+		if (keys.containsKey("seamark:type"))
+			type = keys.get("seamark:type");
+		
+		if (type.equals("buoy_lateral") || type.equals("beacon_lateral")) {
+			mark = new MarkLat(this, node);
+			return;
+
+		} else if (type.equals("buoy_cardinal") || type.equals("beacon_cardinal")) {
+			mark = new MarkCard(this, node);
+			return;
+
+		} else if (type.equals("buoy_safe_water") || type.equals("beacon_safe_water")) {
+			mark = new MarkSaw(this, node);
+			return;
+
+		} else if (type.equals("buoy_special_purpose") || type.equals("beacon_special_purpose")) {
+			mark = new MarkSpec(this, node);
+			return;
+
+		} else if (type.equals("buoy_isolated_danger") || type.equals("beacon_isolated_danger")) {
+			mark = new MarkIsol(this, node);
+			return;
+
+		} else if (type.equals("landmark") || type.equals("light_vessel")
+				|| type.equals("light_major") || type.equals("light_minor")) {
+			mark = new MarkNota(this, node);
+			return;
+
+		} else if (type.equals("light_float")) {
+			if (keys.containsKey("seamark:light_float:colour")) {
+				str = keys.get("seamark:light_float:colour");
+				if (str.equals("red") || str.equals("green")
+						|| str.equals("red;green;red") || str.equals("green;red;green")) {
+					mark = new MarkLat(this, node);
+					return;
+				} else if (str.equals("black;yellow")
+						|| str.equals("black;yellow;black") || str.equals("yellow;black")
+						|| str.equals("yellow;black;yellow")) {
+					mark = new MarkCard(this, node);
+					return;
+				} else if (str.equals("black;red;black")) {
+					mark = new MarkIsol(this, node);
+					return;
+				} else if (str.equals("red;white")) {
+					mark = new MarkSaw(this, node);
+					return;
+				} else if (str.equals("yellow")) {
+					mark = new MarkSpec(this, node);
+					return;
+				}
+			} else if (keys.containsKey("seamark:light_float:topmark:shape")) {
+				str = keys.get("seamark:light_float:topmark:shape");
+				if (str.equals("cylinder") || str.equals("cone, point up")) {
+					mark = new MarkLat(this, node);
+					return;
+				}
+			} else if (keys.containsKey("seamark:light_float:topmark:colour")) {
+				str = keys.get("seamark:light_float:topmark:colour");
+				if (str.equals("red") || str.equals("green")) {
+					mark = new MarkLat(this, node);
+					return;
+				}
+			}
+		}
+
+		if (keys.containsKey("buoy_lateral:category") || keys.containsKey("beacon_lateral:category")) {
+			mark = new MarkLat(this, node);
+			return;
+		} else if (keys.containsKey("buoy_cardinal:category") || keys.containsKey("beacon_cardinal:category")) {
+			mark = new MarkCard(this, node);
+			return;
+		} else if (keys.containsKey("buoy_isolated_danger:category") || keys.containsKey("beacon_isolated_danger:category")) {
+			mark = new MarkIsol(this, node);
+			return;
+		} else if (keys.containsKey("buoy_safe_water:category") || keys.containsKey("beacon_safe_water:category")) {
+			mark = new MarkSaw(this, node);
+			return;
+		} else if (keys.containsKey("buoy_special_purpose:category") || keys.containsKey("beacon_special_purpose:category")) {
+			mark = new MarkSpec(this, node);
+			return;
+		}
+
+		if (keys.containsKey("buoy_lateral:shape") || keys.containsKey("beacon_lateral:shape")) {
+			mark = new MarkLat(this, node);
+			return;
+		} else if (keys.containsKey("buoy_cardinal:shape") || keys.containsKey("beacon_cardinal:shape")) {
+			mark = new MarkCard(this, node);
+			return;
+		} else if (keys.containsKey("buoy_isolated_danger:shape") || keys.containsKey("beacon_isolated_danger:shape")) {
+			mark = new MarkIsol(this, node);
+			return;
+		} else if (keys.containsKey("buoy_safe_water:shape") || keys.containsKey("beacon_safe_water:shape")) {
+			mark = new MarkSaw(this, node);
+			return;
+		} else if (keys.containsKey("buoy_special_purpose:shape") || keys.containsKey("beacon_special_purpose:shape")) {
+			mark = new MarkSpec(this, node);
+			return;
+		}
+
+		if (keys.containsKey("buoy_lateral:colour") || keys.containsKey("beacon_lateral:colour")) {
+			mark = new MarkLat(this, node);
+			return;
+		} else if (keys.containsKey("buoy_cardinal:colour") || keys.containsKey("beacon_cardinal:colour")) {
+			mark = new MarkCard(this, node);
+			return;
+		} else if (keys.containsKey("buoy_isolated_danger:colour") || keys.containsKey("beacon_isolated_danger:colour")) {
+			mark = new MarkIsol(this, node);
+			return;
+		} else if (keys.containsKey("buoy_safe_water:colour") || keys.containsKey("beacon_safe_water:colour")) {
+			mark = new MarkSaw(this, node);
+			return;
+		} else if (keys.containsKey("buoy_special_purpose:colour") || keys.containsKey("beacon_special_purpose:colour")) {
+			mark = new MarkSpec(this, node);
+			return;
+		}
+
+		mark = new MarkUkn(this, Messages.getString("SmpDialogAction.91"));
+		mark.setNode(node);
+		mark.paintSign();
+		return;
 	}
-
-	private JRadioButton getHazButton() {
-		if (hazButton == null) {
-			hazButton = new JRadioButton(new ImageIcon(getClass().getResource(
-					"/images/HazButton.png")));
-			hazButton.setBounds(new Rectangle(0, 40, 62, 40));
-	        hazButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			hazButton.setToolTipText(Messages.getString("HazTip"));
-		}
-		return hazButton;
-	}
-
-	private JRadioButton getSpecButton() {
-		if (specButton == null) {
-			specButton = new JRadioButton(new ImageIcon(getClass().getResource(
-					"/images/SpecButton.png")));
-			specButton.setBounds(new Rectangle(0, 80, 62, 40));
-	        specButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			specButton.setToolTipText(Messages.getString("SpecTip"));
-		}
-		return specButton;
-	}
-
-	private JRadioButton getLightsButton() {
-		if (lightsButton == null) {
-			lightsButton = new JRadioButton(new ImageIcon(getClass().getResource(
-					"/images/LightsButton.png")));
-			lightsButton.setBounds(new Rectangle(0, 120, 62, 40));
-	        lightsButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			lightsButton.setToolTipText(Messages.getString("LightsTip"));
-		}
-		return lightsButton;
-	}
-
-	private JRadioButton getTopButton() {
-		if (topButton == null) {
-			topButton = new JRadioButton(new ImageIcon(getClass().getResource(
-					"/images/TopButton.png")));
-			topButton.setBounds(new Rectangle(0, 165, 34, 32));
-	        topButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			topButton.setToolTipText(Messages.getString("TopmarksTip"));
-		}
-		return topButton;
-	}
-
-	private JRadioButton getFogButton() {
-		if (fogButton == null) {
-			fogButton = new JRadioButton(new ImageIcon(getClass().getResource(
-					"/images/FogButton.png")));
-			fogButton.setBounds(new Rectangle(0, 205, 34, 32));
-	        fogButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			fogButton.setToolTipText(Messages.getString("FogSignalsTip"));
-		}
-		return fogButton;
-	}
-
-	private JRadioButton getRadarButton() {
-		if (radarButton == null) {
-			radarButton = new JRadioButton(new ImageIcon(getClass()
-					.getResource("/images/RadarButton.png")));
-			radarButton.setBounds(new Rectangle(0, 245, 34, 32));
-	        radarButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			radarButton.setToolTipText(Messages.getString("RadarTip"));
-		}
-		return radarButton;
-	}
-
-	private JRadioButton getLitButton() {
-		if (litButton == null) {
-			litButton = new JRadioButton(new ImageIcon(getClass().getResource(
-					"/images/LitButton.png")));
-			litButton.setBounds(new Rectangle(0, 285, 34, 32));
-	        litButton.setBorder(BorderFactory.createLineBorder(Color.magenta, 2));
-			litButton.setToolTipText(Messages.getString("LitTip"));
-		}
-		return litButton;
-	}
-
+*/
 }
Index: applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelMain.java
===================================================================
--- applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelMain.java	(revision 24778)
+++ applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/panels/PanelMain.java	(revision 24778)
@@ -0,0 +1,338 @@
+package oseam.panels;
+
+import static org.openstreetmap.josm.tools.I18n.tr;
+
+import oseam.panels.*;
+
+import java.awt.Color;
+import java.awt.Dimension;
+import java.awt.Font;
+import java.awt.Rectangle;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+import java.awt.event.ComponentListener;
+import java.awt.event.FocusAdapter;
+import java.awt.event.FocusEvent;
+import java.awt.event.ItemEvent;
+import java.awt.event.ItemListener;
+import java.beans.PropertyChangeListener;
+import java.util.Collection;
+import java.util.Iterator;
+import java.util.Map;
+
+import javax.swing.BorderFactory;
+import javax.swing.ButtonGroup;
+import javax.swing.ImageIcon;
+import javax.swing.JButton;
+import javax.swing.JCheckBox;
+import javax.swing.JComboBox;
+import javax.swing.JLabel;
+import javax.swing.JMenuItem;
+import javax.swing.JPanel;
+import javax.swing.JRadioButton;
+import javax.swing.JTextField;
+
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.command.ChangePropertyCommand;
+import org.openstreetmap.josm.command.Command;
+import org.openstreetmap.josm.data.SelectionChangedListener;
+import org.openstreetmap.josm.data.osm.DataSet;
+import org.openstreetmap.josm.data.osm.Node;
+import org.openstreetmap.josm.data.osm.OsmPrimitive;
+import org.openstreetmap.josm.gui.MapView.EditLayerChangeListener;
+import org.openstreetmap.josm.gui.MapView.LayerChangeListener;
+
+import oseam.Messages;
+import oseam.OSeaM;
+
+public class PanelMain extends JPanel {
+
+	private JLabel shapeIcon = null;
+	private JLabel lightIcon = null;
+	private JLabel topIcon = null;
+	private JLabel reflIcon = null;
+	private JLabel radarIcon = null;
+	private JLabel fogIcon = null;
+	private JLabel nameLabel = null;
+	private JTextField nameBox = null;
+	private JButton saveButton = null;
+	private ButtonGroup typeButtons = null;
+	private JRadioButton chanButton = null;
+	private JRadioButton hazButton = null;
+	private JRadioButton specButton = null;
+	private JRadioButton lightsButton = null;
+	private ButtonGroup miscButtons = null;
+	private JRadioButton topButton = null;
+	private JRadioButton fogButton = null;
+	private JRadioButton radarButton = null;
+	private JRadioButton litButton = null;
+	private PanelChan panelChan = null;
+	private PanelHaz panelHaz = null;
+	private PanelSpec panelSpec = null;
+	private PanelLights panelLights = null;
+	private PanelTop panelTop = null;
+	private PanelFog panelFog = null;
+	private PanelRadar panelRadar = null;
+	private PanelLit panelLit = null;
+
+	public PanelMain() {
+
+		panelChan = new PanelChan();
+		panelChan.setBounds(new Rectangle(65, 0, 335, 160));
+		panelChan.setVisible(false);
+		panelHaz = new PanelHaz();
+		panelHaz.setBounds(new Rectangle(65, 0, 335, 160));
+		panelHaz.setVisible(false);
+		panelSpec = new PanelSpec();
+		panelSpec.setBounds(new Rectangle(65, 0, 335, 160));
+		panelSpec.setVisible(false);
+		panelLights = new PanelLights();
+		panelLights.setBounds(new Rectangle(65, 0, 335, 160));
+		panelLights.setVisible(false);
+		panelTop = new PanelTop();
+		panelTop.setBounds(new Rectangle(40, 165, 220, 160));
+		panelTop.setVisible(false);
+		panelFog = new PanelFog();
+		panelFog.setBounds(new Rectangle(40, 165, 220, 160));
+		panelFog.setVisible(false);
+		panelRadar = new PanelRadar();
+		panelRadar.setBounds(new Rectangle(40, 165, 220, 160));
+		panelRadar.setVisible(false);
+		panelLit = new PanelLit();
+		panelLit.setBounds(new Rectangle(40, 165, 220, 160));
+		panelLit.setVisible(false);
+
+		shapeIcon = new JLabel(new ImageIcon(getClass().getResource(
+				"/images/Cardinal_Pillar_South.png")));
+		shapeIcon.setBounds(new Rectangle(265, 170, 130, 185));
+		this.add(shapeIcon, null);
+		lightIcon = new JLabel(new ImageIcon(getClass().getResource(
+				"/images/Light_White_120.png")));
+		lightIcon.setBounds(new Rectangle(265, 170, 125, 185));
+		this.add(lightIcon, null);
+		topIcon = new JLabel();
+		topIcon.setBounds(new Rectangle(265, 170, 125, 185));
+		this.add(topIcon, null);
+		reflIcon = new JLabel(new ImageIcon(getClass().getResource(
+				"/images/Radar_Reflector_355.png")));
+		reflIcon.setBounds(new Rectangle(265, 170, 125, 185));
+		this.add(reflIcon, null);
+		radarIcon = new JLabel(new ImageIcon(getClass().getResource(
+				"/images/Radar_Station.png")));
+		radarIcon.setBounds(new Rectangle(265, 170, 130, 185));
+		this.add(radarIcon, null);
+		fogIcon = new JLabel(new ImageIcon(getClass().getResource(
+				"/images/Fog_Signal.png")));
+		fogIcon.setBounds(new Rectangle(265, 170, 125, 185));
+		this.add(fogIcon, null);
+
+		this.add(getChanButton(), null);
+		this.add(getHazButton(), null);
+		this.add(getSpecButton(), null);
+		this.add(getLightsButton(), null);
+		this.add(panelChan, null);
+		this.add(panelHaz, null);
+		this.add(panelSpec, null);
+		this.add(panelLights, null);
+		this.add(panelTop, null);
+		this.add(panelFog, null);
+		this.add(panelRadar, null);
+		this.add(panelLit, null);
+		typeButtons = new ButtonGroup();
+		typeButtons.add(chanButton);
+		typeButtons.add(hazButton);
+		typeButtons.add(specButton);
+		typeButtons.add(lightsButton);
+		ActionListener alType = new ActionListener() {
+			public void actionPerformed(java.awt.event.ActionEvent e) {
+				if (chanButton.isSelected()) {
+					chanButton.setBorderPainted(true);
+					panelChan.setVisible(true);
+				} else {
+					chanButton.setBorderPainted(false);
+					panelChan.setVisible(false);
+				}
+				if (hazButton.isSelected()) {
+					hazButton.setBorderPainted(true);
+					panelHaz.setVisible(true);
+				} else {
+					hazButton.setBorderPainted(false);
+					panelHaz.setVisible(false);
+				}
+				if (specButton.isSelected()) {
+					specButton.setBorderPainted(true);
+					panelSpec.setVisible(true);
+				} else {
+					specButton.setBorderPainted(false);
+					panelSpec.setVisible(false);
+				}
+				if (lightsButton.isSelected()) {
+					lightsButton.setBorderPainted(true);
+					panelLights.setVisible(true);
+				} else {
+					lightsButton.setBorderPainted(false);
+					panelLights.setVisible(false);
+				}
+			}
+		};
+		chanButton.addActionListener(alType);
+		hazButton.addActionListener(alType);
+		specButton.addActionListener(alType);
+		lightsButton.addActionListener(alType);
+
+		this.add(getTopButton(), null);
+		this.add(getFogButton(), null);
+		this.add(getRadarButton(), null);
+		this.add(getLitButton(), null);
+		miscButtons = new ButtonGroup();
+		miscButtons.add(topButton);
+		miscButtons.add(fogButton);
+		miscButtons.add(radarButton);
+		miscButtons.add(litButton);
+		ActionListener alMisc = new ActionListener() {
+			public void actionPerformed(java.awt.event.ActionEvent e) {
+				if (topButton.isSelected()) {
+					topButton.setBorderPainted(true);
+					panelTop.setVisible(true);
+				} else {
+					topButton.setBorderPainted(false);
+					panelTop.setVisible(false);
+				}
+				if (fogButton.isSelected()) {
+					fogButton.setBorderPainted(true);
+					panelFog.setVisible(true);
+				} else {
+					fogButton.setBorderPainted(false);
+					panelFog.setVisible(false);
+				}
+				if (radarButton.isSelected()) {
+					radarButton.setBorderPainted(true);
+					panelRadar.setVisible(true);
+				} else {
+					radarButton.setBorderPainted(false);
+					panelRadar.setVisible(false);
+				}
+				if (litButton.isSelected()) {
+					litButton.setBorderPainted(true);
+					panelLit.setVisible(true);
+				} else {
+					litButton.setBorderPainted(false);
+					panelLit.setVisible(false);
+				}
+			}
+		};
+		topButton.addActionListener(alMisc);
+		fogButton.addActionListener(alMisc);
+		radarButton.addActionListener(alMisc);
+		litButton.addActionListener(alMisc);
+
+		nameLabel = new JLabel();
+		nameLabel.setBounds(new Rectangle(5, 329, 60, 20));
+		nameLabel.setText(tr("Name:"));
+		this.add(nameLabel, null);
+		nameBox = new JTextField();
+		nameBox.setBounds(new Rectangle(60, 330, 200, 20));
+		this.add(nameBox, null);
+		saveButton = new JButton();
+		saveButton.setBounds(new Rectangle(285, 330, 100, 20));
+		saveButton.setText(tr("Save"));
+		this.add(saveButton, null);
+	}
+
+	private JRadioButton getChanButton() {
+		if (chanButton == null) {
+			chanButton = new JRadioButton(new ImageIcon(getClass().getResource(
+					"/images/ChanButton.png")));
+			chanButton.setBounds(new Rectangle(0, 0, 62, 40));
+			chanButton.setBorder(BorderFactory.createLineBorder(Color.magenta,
+					2));
+			chanButton.setToolTipText(Messages.getString("ChanTip"));
+		}
+		return chanButton;
+	}
+
+	private JRadioButton getHazButton() {
+		if (hazButton == null) {
+			hazButton = new JRadioButton(new ImageIcon(getClass().getResource(
+					"/images/HazButton.png")));
+			hazButton.setBounds(new Rectangle(0, 40, 62, 40));
+			hazButton.setBorder(BorderFactory
+					.createLineBorder(Color.magenta, 2));
+			hazButton.setToolTipText(Messages.getString("HazTip"));
+		}
+		return hazButton;
+	}
+
+	private JRadioButton getSpecButton() {
+		if (specButton == null) {
+			specButton = new JRadioButton(new ImageIcon(getClass().getResource(
+					"/images/SpecButton.png")));
+			specButton.setBounds(new Rectangle(0, 80, 62, 40));
+			specButton.setBorder(BorderFactory.createLineBorder(Color.magenta,
+					2));
+			specButton.setToolTipText(Messages.getString("SpecTip"));
+		}
+		return specButton;
+	}
+
+	private JRadioButton getLightsButton() {
+		if (lightsButton == null) {
+			lightsButton = new JRadioButton(new ImageIcon(getClass()
+					.getResource("/images/LightsButton.png")));
+			lightsButton.setBounds(new Rectangle(0, 120, 62, 40));
+			lightsButton.setBorder(BorderFactory.createLineBorder(
+					Color.magenta, 2));
+			lightsButton.setToolTipText(Messages.getString("LightsTip"));
+		}
+		return lightsButton;
+	}
+
+	private JRadioButton getTopButton() {
+		if (topButton == null) {
+			topButton = new JRadioButton(new ImageIcon(getClass().getResource(
+					"/images/TopButton.png")));
+			topButton.setBounds(new Rectangle(0, 165, 34, 32));
+			topButton.setBorder(BorderFactory
+					.createLineBorder(Color.magenta, 2));
+			topButton.setToolTipText(Messages.getString("TopmarksTip"));
+		}
+		return topButton;
+	}
+
+	private JRadioButton getFogButton() {
+		if (fogButton == null) {
+			fogButton = new JRadioButton(new ImageIcon(getClass().getResource(
+					"/images/FogButton.png")));
+			fogButton.setBounds(new Rectangle(0, 205, 34, 32));
+			fogButton.setBorder(BorderFactory
+					.createLineBorder(Color.magenta, 2));
+			fogButton.setToolTipText(Messages.getString("FogSignalsTip"));
+		}
+		return fogButton;
+	}
+
+	private JRadioButton getRadarButton() {
+		if (radarButton == null) {
+			radarButton = new JRadioButton(new ImageIcon(getClass()
+					.getResource("/images/RadarButton.png")));
+			radarButton.setBounds(new Rectangle(0, 245, 34, 32));
+			radarButton.setBorder(BorderFactory.createLineBorder(Color.magenta,
+					2));
+			radarButton.setToolTipText(Messages.getString("RadarTip"));
+		}
+		return radarButton;
+	}
+
+	private JRadioButton getLitButton() {
+		if (litButton == null) {
+			litButton = new JRadioButton(new ImageIcon(getClass().getResource(
+					"/images/LitButton.png")));
+			litButton.setBounds(new Rectangle(0, 285, 34, 32));
+			litButton.setBorder(BorderFactory
+					.createLineBorder(Color.magenta, 2));
+			litButton.setToolTipText(Messages.getString("LitTip"));
+		}
+		return litButton;
+	}
+
+}
Index: applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java
===================================================================
--- applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java	(revision 24778)
+++ applications/editors/josm/plugins/smed/plugs/oseam/src/oseam/seamarks/SeaMark.java	(revision 24778)
@@ -0,0 +1,207 @@
+package oseam.seamarks;
+
+import java.util.Iterator;
+
+import org.openstreetmap.josm.Main;
+import org.openstreetmap.josm.command.ChangePropertyCommand;
+import org.openstreetmap.josm.data.osm.Node;
+
+abstract public class SeaMark {
+
+	/**
+	 * CONSTANTS
+	 */
+
+	/**
+	 * Colours
+	 */
+
+	public final static int UNKNOWN_COLOUR = 0;
+	public final static int RED = 1;
+	public final static int GREEN = 2;
+	public final static int RED_GREEN_RED = 3;
+	public final static int GREEN_RED_GREEN = 4;
+	public final static int RED_WHITE = 5;
+	public final static int BLACK_YELLOW = 6;
+	public final static int BLACK_YELLOW_BLACK = 7;
+	public final static int YELLOW_BLACK = 8;
+	public final static int YELLOW_BLACK_YELLOW = 9;
+	public final static int BLACK_RED_BLACK = 10;
+	public final static int YELLOW = 11;
+	public final static int WHITE_LIGHT = 1;
+	public final static int RED_LIGHT = 2;
+	public final static int GREEN_LIGHT = 3;
+
+	/**
+	 * Types - correspond to TypeIndex
+	 */
+	public final static int UNKNOWN_TYPE = 0;
+	public final static int LATERAL = 1;
+	public final static int CARDINAL = 2;
+	public final static int SAFE_WATER = 3;
+	public final static int ISOLATED_DANGER = 4;
+	public final static int SPECIAL_PURPOSE = 5;
+	public final static int LIGHT = 6;
+
+	/**
+	 * Categories - correspond to CatIndex
+	 */
+	public final static int UNKNOWN_CAT = 0;
+	public final static int PORT_HAND = 1;
+	public final static int STARBOARD_HAND = 2;
+	public final static int PREF_PORT_HAND = 3;
+	public final static int PREF_STARBOARD_HAND = 4;
+	public final static int CARD_NORTH = 1;
+	public final static int CARD_EAST = 2;
+	public final static int CARD_SOUTH = 3;
+	public final static int CARD_WEST = 4;
+	public final static int LIGHT_HOUSE = 1;
+	public final static int LIGHT_MAJOR = 2;
+	public final static int LIGHT_MINOR = 3;
+	public final static int LIGHT_VESSEL = 4;
+
+	/**
+	 * Regions
+	 */
+	public final static boolean IALA_A = false;
+	public final static boolean IALA_B = true;
+
+	/**
+	 * Shapes - correspond to StyleIndex
+	 */
+	public final static int UNKNOWN_SHAPE = 0;
+	public final static int LAT_CAN = 1;
+	public final static int LAT_CONE = 1;
+	public final static int LAT_PILLAR = 2;
+	public final static int LAT_SPAR = 3;
+	public final static int LAT_BEACON = 4;
+	public final static int LAT_TOWER = 5;
+	public final static int LAT_FLOAT = 6;
+	public final static int LAT_PERCH = 7;
+	public final static int CARD_PILLAR = 1;
+	public final static int CARD_SPAR = 2;
+	public final static int CARD_BEACON = 3;
+	public final static int CARD_TOWER = 4;
+	public final static int CARD_FLOAT = 5;
+	public final static int SAFE_PILLAR = 1;
+	public final static int SAFE_SPAR = 2;
+	public final static int SAFE_SPHERE = 3;
+	public final static int SAFE_BEACON = 4;
+	public final static int SAFE_FLOAT = 5;
+	public final static int ISOL_PILLAR = 1;
+	public final static int ISOL_SPAR = 2;
+	public final static int ISOL_BEACON = 3;
+	public final static int ISOL_TOWER = 4;
+	public final static int ISOL_FLOAT = 5;
+	public final static int SPEC_PILLAR = 1;
+	public final static int SPEC_CAN = 2;
+	public final static int SPEC_CONE = 3;
+	public final static int SPEC_SPAR = 4;
+	public final static int SPEC_BEACON = 5;
+	public final static int SPEC_TOWER = 6;
+	public final static int SPEC_FLOAT = 7;
+	public final static int SPEC_SPHERE = 8;
+	public final static int SPEC_BARREL = 9;
+
+	/**
+	 * Topmark Shapes - correspond to TopMarkIndex
+	 */
+
+	public final static int UNKNOWN_TOPMARK = 0;
+	public final static int TOP_YELLOW_X = 1;
+	public final static int TOP_RED_X = 2;
+	public final static int TOP_YELLOW_CAN = 3;
+	public final static int TOP_YELLOW_CONE = 4;
+
+	/**
+	 * Radar Beacons - correspond to Ratyp Index
+	 */
+
+	public final static int UNKNOWN_RATYPE = 0;
+	public final static int RATYPE_RACON = 1;
+	public final static int RATYPE_RAMARK = 2;
+	public final static int RATYPE_LEADING = 3;
+
+	/**
+	 * Fog Signals - correspond to FogSound Index
+	 */
+
+	public final static int UNKNOWN_FOG = 0;
+	public final static int FOG_HORN = 1;
+	public final static int FOG_SIREN = 2;
+	public final static int FOG_DIA = 3;
+	public final static int FOG_BELL = 4;
+	public final static int FOG_WHIS = 5;
+	public final static int FOG_GONG = 6;
+	public final static int FOG_EXPLOS = 7;
+
+	/**
+	 * Variables
+	 */
+
+	public abstract void setLightColour();
+
+	public abstract void paintSign();
+
+	public abstract void saveSign();
+
+	private int Colour = UNKNOWN_COLOUR;
+
+	public int getColour() {
+		return Colour;
+	}
+
+	public void setColour(int colour) {
+		if (colour < UNKNOWN_COLOUR || colour > RED_WHITE) {
+			return;
+		}
+		Colour = colour;
+
+	}
+
+	private String ErrMsg = null;
+
+	public String getErrMsg() {
+		return ErrMsg;
+	}
+
+	public void setErrMsg(String errMsg) {
+		ErrMsg = errMsg;
+	}
+
+	private String Name;
+
+	public String getName() {
+		return Name;
+	}
+
+	public void setName(String name) {
+		Name = name;
+	}
+
+	private boolean valid = true;
+
+	public boolean isValid() {
+		return valid;
+	}
+
+	public void setValid(boolean valid) {
+		this.valid = valid;
+
+	}
+
+	protected void delSeaMarkKeys(Node node) {
+		Iterator<String> it = node.getKeys().keySet().iterator();
+		String str;
+
+		while (it.hasNext()) {
+			str = it.next();
+
+			if (str.contains("seamark") == true)
+				if (str.compareTo("seamark") != 0) {
+					Main.main.undoRedo.add(new ChangePropertyCommand(node, str, null));
+				}
+		}
+	}
+
+}
Index: applications/editors/josm/plugins/smed/src/smed/Smed.java
===================================================================
--- applications/editors/josm/plugins/smed/src/smed/Smed.java	(revision 24765)
+++ applications/editors/josm/plugins/smed/src/smed/Smed.java	(revision 24778)
@@ -57,5 +57,5 @@
 
         try {
-            JarFile file = new JarFile(pluginDirName  + "/smed.jar");
+            JarFile file = new JarFile(pluginDirName  + "/SeaMapEditor.jar");
             FileOutputStream fos = new FileOutputStream(pluginDirName + "/splug/smed_ifc.jar");
             JarOutputStream jos = new JarOutputStream(fos);
