Index: applications/editors/josm/plugins/smed/src/panels/PanelChan.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelChan.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelChan.java	(revision 30738)
@@ -28,16 +28,16 @@
 			panelStbd.setVisible(false);
 			panelSaw.setVisible(false);
-			dlg.panelMain.moreButton.setVisible(false);
-			dlg.panelMain.saveButton.setEnabled(false);
+			SmedAction.panelMain.moreButton.setVisible(false);
+			SmedAction.panelMain.saveButton.setEnabled(false);
 			topmarkButton.setVisible(false);
 			lightButton.setVisible(false);
-			Shp shp = dlg.panelMain.mark.getShape();
+			Shp shp = SmedAction.panelMain.mark.getShape();
 			if (portButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.LAM_PORT);
+				SmedAction.panelMain.mark.setCategory(Cat.LAM_PORT);
 				if (panelPort.shapes.containsKey(shp)) {
 					panelPort.shapes.get(shp).setSelected(true);
 				} else {
 					panelPort.shapeButtons.clearSelection();
-					dlg.panelMain.mark.setShape(Shp.UNKSHP);
+					SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 				}
 				panelPort.alShape.actionPerformed(null);
@@ -48,10 +48,10 @@
 			}
 			if (stbdButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.LAM_STBD);
+				SmedAction.panelMain.mark.setCategory(Cat.LAM_STBD);
 				if (panelStbd.shapes.containsKey(shp)) {
 					panelStbd.shapes.get(shp).setSelected(true);
 				} else {
 					panelStbd.shapeButtons.clearSelection();
-					dlg.panelMain.mark.setShape(Shp.UNKSHP);
+					SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 				}
 				panelStbd.alShape.actionPerformed(null);
@@ -62,10 +62,10 @@
 			}
 			if (prefStbdButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.LAM_PSTBD);
+				SmedAction.panelMain.mark.setCategory(Cat.LAM_PSTBD);
 				if (panelPort.shapes.containsKey(shp)) {
 					panelPort.shapes.get(shp).setSelected(true);
 				} else {
 					panelPort.shapeButtons.clearSelection();
-					dlg.panelMain.mark.setShape(Shp.UNKSHP);
+					SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 				}
 				panelPort.alShape.actionPerformed(null);
@@ -76,10 +76,10 @@
 			}
 			if (prefPortButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.LAM_PPORT);
+				SmedAction.panelMain.mark.setCategory(Cat.LAM_PPORT);
 				if (panelStbd.shapes.containsKey(shp)) {
 					panelStbd.shapes.get(shp).setSelected(true);
 				} else {
 					panelStbd.shapeButtons.clearSelection();
-					dlg.panelMain.mark.setShape(Shp.UNKSHP);
+					SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 				}
 				panelStbd.alShape.actionPerformed(null);
@@ -90,5 +90,5 @@
 			}
 			if (safeWaterButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.NOCAT);
+				SmedAction.panelMain.mark.setCategory(Cat.NOCAT);
 				panelSaw.setVisible(true);
 				if (panelSaw.shapes.containsKey(shp)) {
@@ -96,5 +96,5 @@
 				} else {
 					panelSaw.shapeButtons.clearSelection();
-					dlg.panelMain.mark.setShape(Shp.UNKSHP);
+					SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 				}
 				panelSaw.alShape.actionPerformed(null);
@@ -104,7 +104,7 @@
 				safeWaterButton.setBorderPainted(false);
 			}
-			topmarkButton.setVisible(dlg.panelMain.mark.testValid());
-			lightButton.setVisible(dlg.panelMain.mark.testValid());
-			dlg.panelMain.panelMore.syncPanel();
+			topmarkButton.setVisible(SmedAction.panelMain.mark.testValid());
+			lightButton.setVisible(SmedAction.panelMain.mark.testValid());
+			SmedAction.panelMain.panelMore.syncPanel();
 		}
 	};
@@ -113,8 +113,8 @@
 		public void actionPerformed(java.awt.event.ActionEvent e) {
 			if (topmarkButton.isSelected()) {
-				if (SeaMark.GrpMAP.get(dlg.panelMain.mark.getObject()) == Grp.SAW) {
-					dlg.panelMain.mark.setTopmark(Top.SPHERE);
-					dlg.panelMain.mark.setTopPattern(Pat.NOPAT);
-					dlg.panelMain.mark.setTopColour(Col.RED);
+				if (SeaMark.GrpMAP.get(SmedAction.panelMain.mark.getObject()) == Grp.SAW) {
+					SmedAction.panelMain.mark.setTopmark(Top.SPHERE);
+					SmedAction.panelMain.mark.setTopPattern(Pat.NOPAT);
+					SmedAction.panelMain.mark.setTopColour(Col.RED);
 				} else {
 					switch (dlg.panelMain.mark.getCategory()) {
Index: applications/editors/josm/plugins/smed/src/panels/PanelChr.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelChr.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelChr.java	(revision 30738)
@@ -67,10 +67,10 @@
 			}
 			String str = charBox.getText();
-			dlg.panelMain.mark.setLightAtt(Att.CHR, 0, str);
+			SmedAction.panelMain.mark.setLightAtt(Att.CHR, 0, str);
 			if (!str.contains("Al")) {
-				col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.COL, 0)));
-				dlg.panelMain.mark.setLightAtt(Att.ALT, 0, Col.UNKCOL);
+				col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.COL, 0)));
+				SmedAction.panelMain.mark.setLightAtt(Att.ALT, 0, Col.UNKCOL);
 			} else {
-				col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.ALT, 0)));
+				col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.ALT, 0)));
 			}
 		}
@@ -80,5 +80,5 @@
 			public void focusLost(java.awt.event.FocusEvent e) {
 			String str = charBox.getText();
-			dlg.panelMain.mark.setLightAtt(Att.CHR, 0, str);
+			SmedAction.panelMain.mark.setLightAtt(Att.CHR, 0, str);
 			EnumSet<Chr> set = EnumSet.noneOf(Chr.class);
 			for (EnumSet<Chr> map : SeaMark.ChrMAP.keySet()) {
@@ -99,8 +99,8 @@
 			}
 			if (!str.contains("Al")) {
-				col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.COL, 0)));
-				dlg.panelMain.mark.setLightAtt(Att.ALT, 0, Col.UNKCOL);
+				col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.COL, 0)));
+				SmedAction.panelMain.mark.setLightAtt(Att.ALT, 0, Col.UNKCOL);
 			} else {
-				col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.ALT, 0)));
+				col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.ALT, 0)));
 			}
 		}
@@ -141,5 +141,5 @@
 
 	public void syncPanel() {
-		String str = (String)dlg.panelMain.mark.getLightAtt(Att.CHR, 0);
+		String str = (String)SmedAction.panelMain.mark.getLightAtt(Att.CHR, 0);
 		charBox.setText(str);
 		EnumSet<Chr> set = EnumSet.noneOf(Chr.class);
@@ -151,9 +151,9 @@
 		}
 		if (!str.contains("Al")) {
-			col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.COL, 0)));
+			col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.COL, 0)));
 		} else {
-			col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.ALT, 0)));
+			col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.ALT, 0)));
 		}
-		col1Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.COL, 0)));
+		col1Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.COL, 0)));
 		for (Chr chr : buttons.keySet()) {
 			JToggleButton button = buttons.get(chr);
Index: applications/editors/josm/plugins/smed/src/panels/PanelCol.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelCol.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelCol.java	(revision 30738)
@@ -41,29 +41,29 @@
 				if (button.isSelected()) {
 					if (ent == Ent.LIGHT) {
-						if (((String) dlg.panelMain.mark.getLightAtt(Att.CHR, 0)).contains("Al")) {
-							if (((button == delButton) && (dlg.panelMain.mark.getLightAtt(Att.ALT, 0) == Col.UNKCOL))
-									|| (dlg.panelMain.mark.getLightAtt(Att.COL, 0) == Col.UNKCOL)) {
-								dlg.panelMain.mark.setLightAtt(Att.COL, 0, col);
-								dlg.panelMain.panelLit.panelChr.col1Label.setBackground(SeaMark.ColMAP.get(col));
+						if (((String) SmedAction.panelMain.mark.getLightAtt(Att.CHR, 0)).contains("Al")) {
+							if (((button == delButton) && (SmedAction.panelMain.mark.getLightAtt(Att.ALT, 0) == Col.UNKCOL))
+									|| (SmedAction.panelMain.mark.getLightAtt(Att.COL, 0) == Col.UNKCOL)) {
+								SmedAction.panelMain.mark.setLightAtt(Att.COL, 0, col);
+								SmedAction.panelMain.panelLit.panelChr.col1Label.setBackground(SeaMark.ColMAP.get(col));
 							} else {
-								dlg.panelMain.mark.setLightAtt(Att.ALT, 0, col);
-								dlg.panelMain.panelLit.panelChr.col2Label.setBackground(SeaMark.ColMAP.get(col));
+								SmedAction.panelMain.mark.setLightAtt(Att.ALT, 0, col);
+								SmedAction.panelMain.panelLit.panelChr.col2Label.setBackground(SeaMark.ColMAP.get(col));
 							}
 						} else {
-							dlg.panelMain.mark.setLightAtt(Att.COL, 0, col);
-							dlg.panelMain.panelLit.panelChr.col1Label.setBackground(SeaMark.ColMAP.get(col));
-							dlg.panelMain.panelLit.panelChr.col2Label.setBackground(SeaMark.ColMAP.get(col));
+							SmedAction.panelMain.mark.setLightAtt(Att.COL, 0, col);
+							SmedAction.panelMain.panelLit.panelChr.col1Label.setBackground(SeaMark.ColMAP.get(col));
+							SmedAction.panelMain.panelLit.panelChr.col2Label.setBackground(SeaMark.ColMAP.get(col));
 						}
 						button.setBorderPainted(true);
 					} else {
 						if (button == delButton) {
-							dlg.panelMain.mark.subColour(ent, stackIdx);
+							SmedAction.panelMain.mark.subColour(ent, stackIdx);
 						} else if (button == addButton) {
 							if (stackCol.size() != 0)
 								stackIdx++;
 							if (stackCol.size() == 0)
-								dlg.panelMain.mark.setColour(ent, col);
+								SmedAction.panelMain.mark.setColour(ent, col);
 							else
-								switch (dlg.panelMain.mark.getPattern(ent)) {
+								switch (SmedAction.panelMain.mark.getPattern(ent)) {
 								case NOPAT:
 									break;
@@ -71,16 +71,16 @@
 								case CROSS:
 									if (stackCol.size() < 2)
-										dlg.panelMain.mark.addColour(ent, stackIdx, col);
+										SmedAction.panelMain.mark.addColour(ent, stackIdx, col);
 									break;
 								case SQUARED:
 									if (stackCol.size() < 4)
-										dlg.panelMain.mark.addColour(ent, stackIdx, col);
+										SmedAction.panelMain.mark.addColour(ent, stackIdx, col);
 									break;
 								default:
-									dlg.panelMain.mark.addColour(ent, stackIdx, col);
+									SmedAction.panelMain.mark.addColour(ent, stackIdx, col);
 									break;
 								}
 						} else {
-							dlg.panelMain.mark.setColour(ent, stackIdx, col);
+							SmedAction.panelMain.mark.setColour(ent, stackIdx, col);
 						}
 						syncPanel();
@@ -150,5 +150,5 @@
 			for (Col col : colours.keySet()) {
 				JRadioButton button = colours.get(col);
-				if (dlg.panelMain.mark.getLightAtt(Att.COL, 0) == col) {
+				if (SmedAction.panelMain.mark.getLightAtt(Att.COL, 0) == col) {
 					button.setBorderPainted(true);
 				} else
@@ -157,5 +157,5 @@
 		} else {
 			int idx;
-			for (idx = 0; dlg.panelMain.mark.getColour(ent, idx) != Col.UNKCOL; idx++) {
+			for (idx = 0; SmedAction.panelMain.mark.getColour(ent, idx) != Col.UNKCOL; idx++) {
 				if (stackCol.size() <= idx) {
 					stackCol.add(idx, new JRadioButton(new ImageIcon(getClass().getResource("/images/ColourButton.png"))));
@@ -185,5 +185,5 @@
 					JRadioButton btnI = stackCol.get(idx);
 					btnI.setBounds(2, (2 + (idx * height)), 30, height);
-					btnI.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getColour(ent, idx)));
+					btnI.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getColour(ent, idx)));
 					if (stackIdx == idx) {
 						btnI.setBorderPainted(true);
Index: applications/editors/josm/plugins/smed/src/panels/PanelFog.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelFog.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelFog.java	(revision 30738)
@@ -30,5 +30,5 @@
 				JRadioButton button = fogs.get(fog);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setFogSound(fog);
+					SmedAction.panelMain.mark.setFogSound(fog);
 					button.setBorderPainted(true);
 				} else
@@ -41,5 +41,5 @@
 	private FocusListener flGroup = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setFogGroup(groupBox.getText());
+			SmedAction.panelMain.mark.setFogGroup(groupBox.getText());
 		}
 	};
@@ -48,5 +48,5 @@
 	private FocusListener flPeriod = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setFogPeriod(periodBox.getText());
+			SmedAction.panelMain.mark.setFogPeriod(periodBox.getText());
 		}
 	};
@@ -55,5 +55,5 @@
 	private FocusListener flSeq = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setFogSequence(seqBox.getText());
+			SmedAction.panelMain.mark.setFogSequence(seqBox.getText());
 		}
 	};
@@ -62,5 +62,5 @@
 	private FocusListener flRange = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setFogRange(rangeBox.getText());
+			SmedAction.panelMain.mark.setFogRange(rangeBox.getText());
 		}
 	};
@@ -120,10 +120,10 @@
 		for (Fog fog : fogs.keySet()) {
 			JRadioButton button = fogs.get(fog);
-			button.setBorderPainted(dlg.panelMain.mark.getFogSound() == fog);
+			button.setBorderPainted(SmedAction.panelMain.mark.getFogSound() == fog);
 		}
-		groupBox.setText(dlg.panelMain.mark.getFogGroup());
-		seqBox.setText(dlg.panelMain.mark.getFogSequence());
-		periodBox.setText(dlg.panelMain.mark.getFogPeriod());
-		rangeBox.setText(dlg.panelMain.mark.getFogRange());
+		groupBox.setText(SmedAction.panelMain.mark.getFogGroup());
+		seqBox.setText(SmedAction.panelMain.mark.getFogSequence());
+		periodBox.setText(SmedAction.panelMain.mark.getFogPeriod());
+		rangeBox.setText(SmedAction.panelMain.mark.getFogRange());
 	}
 
Index: applications/editors/josm/plugins/smed/src/panels/PanelHaz.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelHaz.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelHaz.java	(revision 30738)
@@ -24,9 +24,9 @@
 	private ActionListener alCat = new ActionListener() {
 		public void actionPerformed(java.awt.event.ActionEvent e) {
-			dlg.panelMain.mark.setObjPattern(Pat.HSTRP);
+			SmedAction.panelMain.mark.setObjPattern(Pat.HSTRP);
 			if (northButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.CAM_NORTH);
-				dlg.panelMain.mark.setObjColour(Col.BLACK);
-				dlg.panelMain.mark.addObjColour(Col.YELLOW);
+				SmedAction.panelMain.mark.setCategory(Cat.CAM_NORTH);
+				SmedAction.panelMain.mark.setObjColour(Col.BLACK);
+				SmedAction.panelMain.mark.addObjColour(Col.YELLOW);
 				northButton.setBorderPainted(true);
 			} else {
@@ -34,7 +34,7 @@
 			}
 			if (southButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.CAM_SOUTH);
-				dlg.panelMain.mark.setObjColour(Col.YELLOW);
-				dlg.panelMain.mark.addObjColour(Col.BLACK);
+				SmedAction.panelMain.mark.setCategory(Cat.CAM_SOUTH);
+				SmedAction.panelMain.mark.setObjColour(Col.YELLOW);
+				SmedAction.panelMain.mark.addObjColour(Col.BLACK);
 				southButton.setBorderPainted(true);
 			} else {
@@ -42,8 +42,8 @@
 			}
 			if (eastButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.CAM_EAST);
-				dlg.panelMain.mark.setObjColour(Col.BLACK);
-				dlg.panelMain.mark.addObjColour(Col.YELLOW);
-				dlg.panelMain.mark.addObjColour(Col.BLACK);
+				SmedAction.panelMain.mark.setCategory(Cat.CAM_EAST);
+				SmedAction.panelMain.mark.setObjColour(Col.BLACK);
+				SmedAction.panelMain.mark.addObjColour(Col.YELLOW);
+				SmedAction.panelMain.mark.addObjColour(Col.BLACK);
 				eastButton.setBorderPainted(true);
 			} else {
@@ -51,8 +51,8 @@
 			}
 			if (westButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.CAM_WEST);
-				dlg.panelMain.mark.setObjColour(Col.YELLOW);
-				dlg.panelMain.mark.addObjColour(Col.BLACK);
-				dlg.panelMain.mark.addObjColour(Col.YELLOW);
+				SmedAction.panelMain.mark.setCategory(Cat.CAM_WEST);
+				SmedAction.panelMain.mark.setObjColour(Col.YELLOW);
+				SmedAction.panelMain.mark.addObjColour(Col.BLACK);
+				SmedAction.panelMain.mark.addObjColour(Col.YELLOW);
 				westButton.setBorderPainted(true);
 			} else {
@@ -60,15 +60,15 @@
 			}
 			if (isolButton.isSelected()) {
-				dlg.panelMain.mark.setCategory(Cat.NOCAT);
-				dlg.panelMain.mark.setObjColour(Col.BLACK);
-				dlg.panelMain.mark.addObjColour(Col.RED);
-				dlg.panelMain.mark.addObjColour(Col.BLACK);
+				SmedAction.panelMain.mark.setCategory(Cat.NOCAT);
+				SmedAction.panelMain.mark.setObjColour(Col.BLACK);
+				SmedAction.panelMain.mark.addObjColour(Col.RED);
+				SmedAction.panelMain.mark.addObjColour(Col.BLACK);
 				isolButton.setBorderPainted(true);
 			} else {
 				isolButton.setBorderPainted(false);
 			}
-			topmarkButton.setVisible(dlg.panelMain.mark.testValid());
-			lightButton.setVisible(dlg.panelMain.mark.testValid());
-			dlg.panelMain.panelMore.syncPanel();
+			topmarkButton.setVisible(SmedAction.panelMain.mark.testValid());
+			lightButton.setVisible(SmedAction.panelMain.mark.testValid());
+			SmedAction.panelMain.panelMore.syncPanel();
 		}
 	};
@@ -90,15 +90,15 @@
 				JRadioButton button = shapes.get(shp);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setShape(shp);
+					SmedAction.panelMain.mark.setShape(shp);
 					if (isolButton.isSelected())
-						dlg.panelMain.mark.setObject(isdObjects.get(shp));
+						SmedAction.panelMain.mark.setObject(isdObjects.get(shp));
 					else
-						dlg.panelMain.mark.setObject(carObjects.get(shp));
+						SmedAction.panelMain.mark.setObject(carObjects.get(shp));
 					button.setBorderPainted(true);
 				} else
 					button.setBorderPainted(false);
 			}
-			topmarkButton.setVisible(dlg.panelMain.mark.testValid());
-			lightButton.setVisible(dlg.panelMain.mark.testValid());
+			topmarkButton.setVisible(SmedAction.panelMain.mark.testValid());
+			lightButton.setVisible(SmedAction.panelMain.mark.testValid());
 		}
 	};
@@ -107,31 +107,31 @@
 		public void actionPerformed(java.awt.event.ActionEvent e) {
 			if (topmarkButton.isSelected()) {
-				dlg.panelMain.mark.setTopPattern(Pat.NOPAT);
-				dlg.panelMain.mark.setTopColour(Col.BLACK);
-				switch (dlg.panelMain.mark.getCategory()) {
+				SmedAction.panelMain.mark.setTopPattern(Pat.NOPAT);
+				SmedAction.panelMain.mark.setTopColour(Col.BLACK);
+				switch (SmedAction.panelMain.mark.getCategory()) {
 				case CAM_NORTH:
-					dlg.panelMain.mark.setTopmark(Top.NORTH);
+					SmedAction.panelMain.mark.setTopmark(Top.NORTH);
 					break;
 				case CAM_SOUTH:
-					dlg.panelMain.mark.setTopmark(Top.SOUTH);
+					SmedAction.panelMain.mark.setTopmark(Top.SOUTH);
 					break;
 				case CAM_EAST:
-					dlg.panelMain.mark.setTopmark(Top.EAST);
+					SmedAction.panelMain.mark.setTopmark(Top.EAST);
 					break;
 				case CAM_WEST:
-					dlg.panelMain.mark.setTopmark(Top.WEST);
+					SmedAction.panelMain.mark.setTopmark(Top.WEST);
 					break;
 				default:
-					dlg.panelMain.mark.setTopmark(Top.SPHERES2);
+					SmedAction.panelMain.mark.setTopmark(Top.SPHERES2);
 					break;
 				}
 				topmarkButton.setBorderPainted(true);
 			} else {
-				dlg.panelMain.mark.setTopmark(Top.NOTOP);
-				dlg.panelMain.mark.setTopPattern(Pat.NOPAT);
-				dlg.panelMain.mark.setTopColour(Col.UNKCOL);
+				SmedAction.panelMain.mark.setTopmark(Top.NOTOP);
+				SmedAction.panelMain.mark.setTopPattern(Pat.NOPAT);
+				SmedAction.panelMain.mark.setTopColour(Col.UNKCOL);
 				topmarkButton.setBorderPainted(false);
 			}
-			dlg.panelMain.panelTop.syncPanel();
+			SmedAction.panelMain.panelTop.syncPanel();
 		}
 	};
@@ -140,33 +140,33 @@
 		public void actionPerformed(java.awt.event.ActionEvent e) {
 			if (lightButton.isSelected()) {
-				dlg.panelMain.mark.setLightAtt(Att.COL, 0, Col.WHITE);
-				switch (dlg.panelMain.mark.getCategory()) {
+				SmedAction.panelMain.mark.setLightAtt(Att.COL, 0, Col.WHITE);
+				switch (SmedAction.panelMain.mark.getCategory()) {
 				case CAM_NORTH:
-					dlg.panelMain.mark.setLightAtt(Att.CHR, 0, "Q");
-					dlg.panelMain.mark.setLightAtt(Att.GRP, 0, "");
+					SmedAction.panelMain.mark.setLightAtt(Att.CHR, 0, "Q");
+					SmedAction.panelMain.mark.setLightAtt(Att.GRP, 0, "");
 					break;
 				case CAM_SOUTH:
-					dlg.panelMain.mark.setLightAtt(Att.CHR, 0, "Q+LFl");
-					dlg.panelMain.mark.setLightAtt(Att.GRP, 0, "6");
+					SmedAction.panelMain.mark.setLightAtt(Att.CHR, 0, "Q+LFl");
+					SmedAction.panelMain.mark.setLightAtt(Att.GRP, 0, "6");
 					break;
 				case CAM_EAST:
-					dlg.panelMain.mark.setLightAtt(Att.CHR, 0, "Q");
-					dlg.panelMain.mark.setLightAtt(Att.GRP, 0, "3");
+					SmedAction.panelMain.mark.setLightAtt(Att.CHR, 0, "Q");
+					SmedAction.panelMain.mark.setLightAtt(Att.GRP, 0, "3");
 					break;
 				case CAM_WEST:
-					dlg.panelMain.mark.setLightAtt(Att.CHR, 0, "Q");
-					dlg.panelMain.mark.setLightAtt(Att.GRP, 0, "9");
+					SmedAction.panelMain.mark.setLightAtt(Att.CHR, 0, "Q");
+					SmedAction.panelMain.mark.setLightAtt(Att.GRP, 0, "9");
 					break;
 				default:
-					dlg.panelMain.mark.setLightAtt(Att.CHR, 0, "Fl");
-					dlg.panelMain.mark.setLightAtt(Att.GRP, 0, "2");
+					SmedAction.panelMain.mark.setLightAtt(Att.CHR, 0, "Fl");
+					SmedAction.panelMain.mark.setLightAtt(Att.GRP, 0, "2");
 					break;
 				}
 				lightButton.setBorderPainted(true);
 			} else {
-				dlg.panelMain.mark.clrLight();
+				SmedAction.panelMain.mark.clrLight();
 				lightButton.setBorderPainted(false);
 			}
-			dlg.panelMain.panelLit.syncPanel();
+			SmedAction.panelMain.panelLit.syncPanel();
 		}
 	};
@@ -205,20 +205,20 @@
 
 	public void syncPanel() {
-		northButton.setBorderPainted(dlg.panelMain.mark.getCategory() == Cat.CAM_NORTH);
-		southButton.setBorderPainted(dlg.panelMain.mark.getCategory() == Cat.CAM_SOUTH);
-		eastButton.setBorderPainted(dlg.panelMain.mark.getCategory() == Cat.CAM_EAST);
-		westButton.setBorderPainted(dlg.panelMain.mark.getCategory() == Cat.CAM_WEST);
-		isolButton.setBorderPainted(SeaMark.GrpMAP.get(dlg.panelMain.mark.getObject()) == Grp.ISD);
+		northButton.setBorderPainted(SmedAction.panelMain.mark.getCategory() == Cat.CAM_NORTH);
+		southButton.setBorderPainted(SmedAction.panelMain.mark.getCategory() == Cat.CAM_SOUTH);
+		eastButton.setBorderPainted(SmedAction.panelMain.mark.getCategory() == Cat.CAM_EAST);
+		westButton.setBorderPainted(SmedAction.panelMain.mark.getCategory() == Cat.CAM_WEST);
+		isolButton.setBorderPainted(SeaMark.GrpMAP.get(SmedAction.panelMain.mark.getObject()) == Grp.ISD);
 		for (Shp shp : shapes.keySet()) {
 			JRadioButton button = shapes.get(shp);
-			button.setBorderPainted(dlg.panelMain.mark.getShape() == shp);
-		}
-		topmarkButton.setBorderPainted(dlg.panelMain.mark.getTopmark() != Top.NOTOP);
-		topmarkButton.setSelected(dlg.panelMain.mark.getTopmark() != Top.NOTOP);
-		topmarkButton.setVisible(dlg.panelMain.mark.testValid());
-		Boolean lit = (dlg.panelMain.mark.getLightAtt(Att.COL, 0) != Col.UNKCOL) && !((String)dlg.panelMain.mark.getLightAtt(Att.CHR, 0)).isEmpty();
+			button.setBorderPainted(SmedAction.panelMain.mark.getShape() == shp);
+		}
+		topmarkButton.setBorderPainted(SmedAction.panelMain.mark.getTopmark() != Top.NOTOP);
+		topmarkButton.setSelected(SmedAction.panelMain.mark.getTopmark() != Top.NOTOP);
+		topmarkButton.setVisible(SmedAction.panelMain.mark.testValid());
+		Boolean lit = (SmedAction.panelMain.mark.getLightAtt(Att.COL, 0) != Col.UNKCOL) && !((String)SmedAction.panelMain.mark.getLightAtt(Att.CHR, 0)).isEmpty();
 		lightButton.setBorderPainted(lit);
 		lightButton.setSelected(lit);
-		lightButton.setVisible(dlg.panelMain.mark.testValid());
+		lightButton.setVisible(SmedAction.panelMain.mark.testValid());
 	}
 
Index: applications/editors/josm/plugins/smed/src/panels/PanelLights.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelLights.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelLights.java	(revision 30738)
@@ -25,6 +25,6 @@
 				int idx = landCats.get(cat);
 				if (dlg.node != null && (idx == landCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -38,6 +38,6 @@
 				int idx = trafficCats.get(cat);
 				if (dlg.node != null && (idx == trafficCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -51,6 +51,6 @@
 				int idx = warningCats.get(cat);
 				if (dlg.node != null && (idx == warningCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -64,6 +64,6 @@
 				int idx = platformCats.get(cat);
 				if (dlg.node != null && (idx == platformCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -77,6 +77,6 @@
 				int idx = pilotCats.get(cat);
 				if (dlg.node != null && (idx == pilotCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -90,6 +90,6 @@
 				int idx = rescueCats.get(cat);
 				if (dlg.node != null && (idx == rescueCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -103,6 +103,6 @@
 				int idx = radioCats.get(cat);
 				if (dlg.node != null && (idx == radioCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -116,6 +116,6 @@
 				int idx = radarCats.get(cat);
 				if (dlg.node != null && (idx == radarCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -130,6 +130,6 @@
 				int idx = functions.get(fnc);
 				if (dlg.node != null && (idx == functionBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setFunc(fnc);
-					dlg.panelMain.mark.testValid();
+					SmedAction.panelMain.mark.setFunc(fnc);
+					SmedAction.panelMain.mark.testValid();
 				}
 			}
@@ -157,14 +157,14 @@
 				JRadioButton button = objects.get(obj);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setObject(obj);
+					SmedAction.panelMain.mark.setObject(obj);
 					button.setBorderPainted(true);
 				} else
 					button.setBorderPainted(false);
 			}
-			if (dlg.panelMain.mark.getObject() == Obj.LITVES)
-				dlg.panelMain.mark.setShape(Shp.SUPER);
-			else if (dlg.panelMain.mark.getObject() == Obj.LITFLT)
-				dlg.panelMain.mark.setShape(Shp.FLOAT);
-			else dlg.panelMain.mark.setShape(Shp.UNKSHP);
+			if (SmedAction.panelMain.mark.getObject() == Obj.LITVES)
+				SmedAction.panelMain.mark.setShape(Shp.SUPER);
+			else if (SmedAction.panelMain.mark.getObject() == Obj.LITFLT)
+				SmedAction.panelMain.mark.setShape(Shp.FLOAT);
+			else SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 			functionLabel.setVisible(false);
 			categoryLabel.setVisible(false);
@@ -181,5 +181,5 @@
 			chLabel.setVisible(false);
 			chBox.setVisible(false);
-			dlg.panelMain.mark.setCategory(Cat.NOCAT);
+			SmedAction.panelMain.mark.setCategory(Cat.NOCAT);
 			if (landButton.isSelected()) {
 				functionLabel.setVisible(true);
@@ -227,5 +227,5 @@
 				alRadarCatBox.actionPerformed(null);
 			}
-			dlg.panelMain.mark.testValid();
+			SmedAction.panelMain.mark.testValid();
 		}
 	};
@@ -234,5 +234,5 @@
 	private FocusListener flCh = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setChannel(chBox.getText());
+			SmedAction.panelMain.mark.setChannel(chBox.getText());
 		}
 	};
@@ -462,6 +462,6 @@
 		chLabel.setVisible(false);
 		chBox.setVisible(false);
-		chBox.setText(dlg.panelMain.mark.getChannel());
-		if ((dlg.panelMain.mark.getObject() == Obj.LNDMRK) && ((dlg.panelMain.mark.getCategory() != Cat.NOCAT) || (dlg.panelMain.mark.getFunc() != Fnc.UNKFNC))) {
+		chBox.setText(SmedAction.panelMain.mark.getChannel());
+		if ((SmedAction.panelMain.mark.getObject() == Obj.LNDMRK) && ((SmedAction.panelMain.mark.getCategory() != Cat.NOCAT) || (SmedAction.panelMain.mark.getFunc() != Fnc.UNKFNC))) {
 			functionLabel.setVisible(true);
 			categoryLabel.setVisible(true);
@@ -470,74 +470,74 @@
 			for (Fnc fnc : functions.keySet()) {
 				int item = functions.get(fnc);
-				if (dlg.panelMain.mark.getFunc() == fnc)
+				if (SmedAction.panelMain.mark.getFunc() == fnc)
 					functionBox.setSelectedIndex(item);
 			}
 			for (Cat cat : landCats.keySet()) {
 				int item = landCats.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					landCatBox.setSelectedIndex(item);
 			}
-		} else if (dlg.panelMain.mark.getObject() == Obj.SISTAT) {
+		} else if (SmedAction.panelMain.mark.getObject() == Obj.SISTAT) {
 				categoryLabel.setVisible(true);
 				trafficCatBox.setVisible(true);
 				for (Cat cat : trafficCats.keySet()) {
 					int item = trafficCats.get(cat);
-					if (dlg.panelMain.mark.getCategory() == cat)
+					if (SmedAction.panelMain.mark.getCategory() == cat)
 						trafficCatBox.setSelectedIndex(item);
 				}
 				chLabel.setVisible(true);
 				chBox.setVisible(true);
-		} else if (dlg.panelMain.mark.getObject() == Obj.SISTAW) {
+		} else if (SmedAction.panelMain.mark.getObject() == Obj.SISTAW) {
 			categoryLabel.setVisible(true);
 			warningCatBox.setVisible(true);
 			for (Cat cat : warningCats.keySet()) {
 				int item = warningCats.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					warningCatBox.setSelectedIndex(item);
 			}
 			chLabel.setVisible(true);
 			chBox.setVisible(true);
-		} else if (dlg.panelMain.mark.getObject() == Obj.OFSPLF) {
+		} else if (SmedAction.panelMain.mark.getObject() == Obj.OFSPLF) {
 			categoryLabel.setVisible(true);
 			platformCatBox.setVisible(true);
 			for (Cat cat : platformCats.keySet()) {
 				int item = platformCats.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					platformCatBox.setSelectedIndex(item);
 			}
-		} else if (dlg.panelMain.mark.getObject() == Obj.PILBOP) {
+		} else if (SmedAction.panelMain.mark.getObject() == Obj.PILBOP) {
 			categoryLabel.setVisible(true);
 			pilotCatBox.setVisible(true);
 			for (Cat cat : pilotCats.keySet()) {
 				int item = pilotCats.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					pilotCatBox.setSelectedIndex(item);
 			}
 			chLabel.setVisible(true);
 			chBox.setVisible(true);
-		} else if (dlg.panelMain.mark.getObject() == Obj.RSCSTA) {
+		} else if (SmedAction.panelMain.mark.getObject() == Obj.RSCSTA) {
 			categoryLabel.setVisible(true);
 			rescueCatBox.setVisible(true);
 			for (Cat cat : rescueCats.keySet()) {
 				int item = rescueCats.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					rescueCatBox.setSelectedIndex(item);
 			}
-		} else if (dlg.panelMain.mark.getObject() == Obj.RDOSTA) {
+		} else if (SmedAction.panelMain.mark.getObject() == Obj.RDOSTA) {
 			categoryLabel.setVisible(true);
 			radioCatBox.setVisible(true);
 			for (Cat cat : radioCats.keySet()) {
 				int item = radioCats.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					radioCatBox.setSelectedIndex(item);
 			}
 			chLabel.setVisible(true);
 			chBox.setVisible(true);
-		} else if (dlg.panelMain.mark.getObject() == Obj.RADSTA) {
+		} else if (SmedAction.panelMain.mark.getObject() == Obj.RADSTA) {
 			categoryLabel.setVisible(true);
 			radarCatBox.setVisible(true);
 			for (Cat cat : radarCats.keySet()) {
 				int item = radarCats.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					radarCatBox.setSelectedIndex(item);
 			}
@@ -547,7 +547,7 @@
 		for (Obj obj : objects.keySet()) {
 			JRadioButton button = objects.get(obj);
-			button.setBorderPainted(dlg.panelMain.mark.getObject() == obj);
-		}
-		dlg.panelMain.mark.testValid();
+			button.setBorderPainted(SmedAction.panelMain.mark.getObject() == obj);
+		}
+		SmedAction.panelMain.mark.testValid();
 	}
 	
Index: applications/editors/josm/plugins/smed/src/panels/PanelLit.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelLit.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelLit.java	(revision 30738)
@@ -21,5 +21,5 @@
 	private FocusListener flGroup = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setLightAtt(Att.GRP, 0, groupBox.getText());
+			SmedAction.panelMain.mark.setLightAtt(Att.GRP, 0, groupBox.getText());
 		}
 	};
@@ -28,5 +28,5 @@
 	private FocusListener flPeriod = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setLightAtt(Att.PER, 0, periodBox.getText());
+			SmedAction.panelMain.mark.setLightAtt(Att.PER, 0, periodBox.getText());
 		}
 	};
@@ -35,5 +35,5 @@
 	private FocusListener flSequence = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setLightAtt(Att.SEQ, 0, sequenceBox.getText());
+			SmedAction.panelMain.mark.setLightAtt(Att.SEQ, 0, sequenceBox.getText());
 		}
 	};
@@ -46,5 +46,5 @@
 				int idx = visibilities.get(vis);
 				if (idx == visibilityBox.getSelectedIndex())
-					dlg.panelMain.mark.setLightAtt(Att.VIS, 0, vis);
+					SmedAction.panelMain.mark.setLightAtt(Att.VIS, 0, vis);
 			}
 		}
@@ -54,5 +54,5 @@
 	private FocusListener flHeight = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setLightAtt(Att.HGT, 0, heightBox.getText());
+			SmedAction.panelMain.mark.setLightAtt(Att.HGT, 0, heightBox.getText());
 		}
 	};
@@ -61,5 +61,5 @@
 	private FocusListener flRange = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setLightAtt(Att.RNG, 0, rangeBox.getText());
+			SmedAction.panelMain.mark.setLightAtt(Att.RNG, 0, rangeBox.getText());
 		}
 	};
@@ -68,5 +68,5 @@
 	private FocusListener flOrientation = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setLightAtt(Att.ORT, 0, orientationBox.getText());
+			SmedAction.panelMain.mark.setLightAtt(Att.ORT, 0, orientationBox.getText());
 		}
 	};
@@ -75,5 +75,5 @@
 	private FocusListener flMultiple = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setLightAtt(Att.MLT, 0, multipleBox.getText());
+			SmedAction.panelMain.mark.setLightAtt(Att.MLT, 0, multipleBox.getText());
 		}
 	};
@@ -86,8 +86,8 @@
 				int idx = categories.get(lit);
 				if (idx == categoryBox.getSelectedIndex())
-					dlg.panelMain.mark.setLightAtt(Att.LIT, 0, lit);
-			}
-			if (dlg.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.DIR) {
-				dlg.panelMain.mark.setLightAtt(Att.MLT, 0, "");
+					SmedAction.panelMain.mark.setLightAtt(Att.LIT, 0, lit);
+			}
+			if (SmedAction.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.DIR) {
+				SmedAction.panelMain.mark.setLightAtt(Att.MLT, 0, "");
 				multipleBox.setText("");
 				orientationLabel.setVisible(true);
@@ -95,6 +95,6 @@
 				multipleLabel.setVisible(false);
 				multipleBox.setVisible(false);
-			} else if ((dlg.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.VERT) || (dlg.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.HORIZ)) {
-				dlg.panelMain.mark.setLightAtt(Att.ORT, 0, "");
+			} else if ((SmedAction.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.VERT) || (SmedAction.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.HORIZ)) {
+				SmedAction.panelMain.mark.setLightAtt(Att.ORT, 0, "");
 				orientationBox.setText("");
 				orientationLabel.setVisible(false);
@@ -103,7 +103,7 @@
 				multipleBox.setVisible(true);
 			} else {
-				dlg.panelMain.mark.setLightAtt(Att.MLT, 0, "");
+				SmedAction.panelMain.mark.setLightAtt(Att.MLT, 0, "");
 				multipleBox.setText("");
-				dlg.panelMain.mark.setLightAtt(Att.ORT, 0, "");
+				SmedAction.panelMain.mark.setLightAtt(Att.ORT, 0, "");
 				orientationBox.setText("");
 				orientationLabel.setVisible(false);
@@ -122,5 +122,5 @@
 				int idx = exhibitions.get(exh);
 				if (idx == exhibitionBox.getSelectedIndex())
-					dlg.panelMain.mark.setLightAtt(Att.EXH, 0, exh);
+					SmedAction.panelMain.mark.setLightAtt(Att.EXH, 0, exh);
 			}
 		}
@@ -137,6 +137,6 @@
 			} else {
 				panelSector.setVisible(false);
-				while (dlg.panelMain.mark.getSectorCount() > 1)
-					dlg.panelMain.mark.delLight(1);
+				while (SmedAction.panelMain.mark.getSectorCount() > 1)
+					SmedAction.panelMain.mark.delLight(1);
 			}
 		}
@@ -285,29 +285,29 @@
 		multipleLabel.setVisible(false);
 		multipleBox.setVisible(false);
-		groupBox.setText((String)dlg.panelMain.mark.getLightAtt(Att.GRP, 0));
-		periodBox.setText((String)dlg.panelMain.mark.getLightAtt(Att.PER, 0));
-		sequenceBox.setText((String)dlg.panelMain.mark.getLightAtt(Att.SEQ, 0));
-		heightBox.setText((String)dlg.panelMain.mark.getLightAtt(Att.HGT, 0));
-		rangeBox.setText((String)dlg.panelMain.mark.getLightAtt(Att.RNG, 0));
-		orientationBox.setText((String)dlg.panelMain.mark.getLightAtt(Att.ORT, 0));
-		orientationBox.setVisible(dlg.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.DIR);
-		multipleBox.setText((String)dlg.panelMain.mark.getLightAtt(Att.MLT, 0));
-		multipleBox.setVisible((dlg.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.VERT) || (dlg.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.HORIZ));
+		groupBox.setText((String)SmedAction.panelMain.mark.getLightAtt(Att.GRP, 0));
+		periodBox.setText((String)SmedAction.panelMain.mark.getLightAtt(Att.PER, 0));
+		sequenceBox.setText((String)SmedAction.panelMain.mark.getLightAtt(Att.SEQ, 0));
+		heightBox.setText((String)SmedAction.panelMain.mark.getLightAtt(Att.HGT, 0));
+		rangeBox.setText((String)SmedAction.panelMain.mark.getLightAtt(Att.RNG, 0));
+		orientationBox.setText((String)SmedAction.panelMain.mark.getLightAtt(Att.ORT, 0));
+		orientationBox.setVisible(SmedAction.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.DIR);
+		multipleBox.setText((String)SmedAction.panelMain.mark.getLightAtt(Att.MLT, 0));
+		multipleBox.setVisible((SmedAction.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.VERT) || (SmedAction.panelMain.mark.getLightAtt(Att.LIT, 0) == Lit.HORIZ));
 		for (Vis vis : visibilities.keySet()) {
 			int item = visibilities.get(vis);
-			if (dlg.panelMain.mark.getLightAtt(Att.VIS, 0) == vis)
+			if (SmedAction.panelMain.mark.getLightAtt(Att.VIS, 0) == vis)
 				visibilityBox.setSelectedIndex(item);
 		}
 		for (Lit lit : categories.keySet()) {
 			int item = categories.get(lit);
-			if (dlg.panelMain.mark.getLightAtt(Att.LIT, 0) == lit)
+			if (SmedAction.panelMain.mark.getLightAtt(Att.LIT, 0) == lit)
 				categoryBox.setSelectedIndex(item);
 		}
 		for (Exh exh : exhibitions.keySet()) {
 			int item = exhibitions.get(exh);
-			if (dlg.panelMain.mark.getLightAtt(Att.EXH, 0) == exh)
+			if (SmedAction.panelMain.mark.getLightAtt(Att.EXH, 0) == exh)
 				exhibitionBox.setSelectedIndex(item);
 		}
-		if (dlg.panelMain.mark.isSectored()) {
+		if (SmedAction.panelMain.mark.isSectored()) {
 			singleButton.setBorderPainted(false);
 			sectorButton.setBorderPainted(true);
@@ -317,6 +317,6 @@
 			sectorButton.setBorderPainted(false);
 			panelSector.setVisible(false);
-			while (dlg.panelMain.mark.getSectorCount() > 1)
-				dlg.panelMain.mark.delLight(dlg.panelMain.mark.getSectorCount() - 1);
+			while (SmedAction.panelMain.mark.getSectorCount() > 1)
+				SmedAction.panelMain.mark.delLight(SmedAction.panelMain.mark.getSectorCount() - 1);
 		}
 		panelCol.syncPanel();
Index: applications/editors/josm/plugins/smed/src/panels/PanelMore.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelMore.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelMore.java	(revision 30738)
@@ -19,5 +19,5 @@
 	private FocusListener flInfo = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setInfo(infoBox.getText());
+			SmedAction.panelMain.mark.setInfo(infoBox.getText());
 		}
 	};
@@ -26,5 +26,5 @@
 	private FocusListener flSource = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setSource(sourceBox.getText());
+			SmedAction.panelMain.mark.setSource(sourceBox.getText());
 		}
 	};
@@ -33,5 +33,5 @@
 	private FocusListener flElev = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setElevation(elevBox.getText());
+			SmedAction.panelMain.mark.setElevation(elevBox.getText());
 		}
 	};
@@ -40,5 +40,5 @@
 	private FocusListener flHeight = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setObjectHeight(heightBox.getText());
+			SmedAction.panelMain.mark.setObjectHeight(heightBox.getText());
 		}
 	};
@@ -50,6 +50,6 @@
 			for (Sts sts : statuses.keySet()) {
 				int idx = statuses.get(sts);
-				if (dlg.panelMain.mark != null && (idx == statusBox.getSelectedIndex()))
-					dlg.panelMain.mark.setStatus(sts);
+				if (SmedAction.panelMain.mark != null && (idx == statusBox.getSelectedIndex()))
+					SmedAction.panelMain.mark.setStatus(sts);
 			}
 		}
@@ -62,6 +62,6 @@
 			for (Cns cns : constructions.keySet()) {
 				int idx = constructions.get(cns);
-				if (dlg.panelMain.mark != null && (idx == constrBox.getSelectedIndex()))
-					dlg.panelMain.mark.setConstr(cns);
+				if (SmedAction.panelMain.mark != null && (idx == constrBox.getSelectedIndex()))
+					SmedAction.panelMain.mark.setConstr(cns);
 			}
 		}
@@ -74,6 +74,6 @@
 			for (Con con : conspicuities.keySet()) {
 				int idx = conspicuities.get(con);
-				if (dlg.panelMain.mark != null && (idx == conBox.getSelectedIndex()))
-					dlg.panelMain.mark.setConsp(con);
+				if (SmedAction.panelMain.mark != null && (idx == conBox.getSelectedIndex()))
+					SmedAction.panelMain.mark.setConsp(con);
 			}
 		}
@@ -86,6 +86,6 @@
 			for (Con con : reflectivities.keySet()) {
 				int idx = reflectivities.get(con);
-				if (dlg.panelMain.mark != null && (idx == reflBox.getSelectedIndex()))
-					dlg.panelMain.mark.setRefl(con);
+				if (SmedAction.panelMain.mark != null && (idx == reflBox.getSelectedIndex()))
+					SmedAction.panelMain.mark.setRefl(con);
 			}
 		}
@@ -99,5 +99,5 @@
 		public void actionPerformed(java.awt.event.ActionEvent e) {
 			if (regionAButton.isSelected()) {
-				dlg.panelMain.mark.setRegion(Reg.A);
+				SmedAction.panelMain.mark.setRegion(Reg.A);
 				switch (dlg.panelMain.mark.getCategory()) {
 				case LAM_PORT:
Index: applications/editors/josm/plugins/smed/src/panels/PanelPat.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelPat.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelPat.java	(revision 30738)
@@ -31,10 +31,10 @@
 				JRadioButton button = patterns.get(pat);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setPattern(ent, pat);
+					SmedAction.panelMain.mark.setPattern(ent, pat);
 					button.setBorderPainted(true);
 				} else
 					button.setBorderPainted(false);
 			}
-			switch (dlg.panelMain.mark.getPattern(ent)) {
+			switch (SmedAction.panelMain.mark.getPattern(ent)) {
 			case NOPAT:
 				panelCol.trimStack(1);
@@ -74,5 +74,5 @@
 		for (Pat pat : patterns.keySet()) {
 			JRadioButton button = patterns.get(pat);
-			if (dlg.panelMain.mark.getPattern(ent) == pat) {
+			if (SmedAction.panelMain.mark.getPattern(ent) == pat) {
 				button.setBorderPainted(true);
 			} else
Index: applications/editors/josm/plugins/smed/src/panels/PanelPort.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelPort.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelPort.java	(revision 30738)
@@ -31,56 +31,56 @@
 				JRadioButton button = shapes.get(shp);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setShape(shp);
-					dlg.panelMain.mark.setObject(objects.get(shp));
+					SmedAction.panelMain.mark.setShape(shp);
+					SmedAction.panelMain.mark.setObject(objects.get(shp));
 					button.setBorderPainted(true);
 				} else
 					button.setBorderPainted(false);
 			}
-			if (dlg.panelMain.mark.testValid()) {
-				dlg.panelMain.panelChan.topmarkButton.setVisible(true);
-				dlg.panelMain.panelChan.lightButton.setVisible(true);
-				if (dlg.panelMain.mark.getCategory() == Cat.LAM_PORT) {
-					switch (dlg.panelMain.mark.getRegion()) {
+			if (SmedAction.panelMain.mark.testValid()) {
+				SmedAction.panelMain.panelChan.topmarkButton.setVisible(true);
+				SmedAction.panelMain.panelChan.lightButton.setVisible(true);
+				if (SmedAction.panelMain.mark.getCategory() == Cat.LAM_PORT) {
+					switch (SmedAction.panelMain.mark.getRegion()) {
 					case A:
-						dlg.panelMain.mark.setObjPattern(Pat.NOPAT);
-						dlg.panelMain.mark.setObjColour(Col.RED);
+						SmedAction.panelMain.mark.setObjPattern(Pat.NOPAT);
+						SmedAction.panelMain.mark.setObjColour(Col.RED);
 						break;
 					case B:
-						dlg.panelMain.mark.setObjPattern(Pat.NOPAT);
-						dlg.panelMain.mark.setObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.setObjPattern(Pat.NOPAT);
+						SmedAction.panelMain.mark.setObjColour(Col.GREEN);
 						break;
 					case C:
-						dlg.panelMain.mark.setObjPattern(Pat.HSTRP);
-						dlg.panelMain.mark.setObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.WHITE);
-						dlg.panelMain.mark.addObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.WHITE);
+						SmedAction.panelMain.mark.setObjPattern(Pat.HSTRP);
+						SmedAction.panelMain.mark.setObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.WHITE);
+						SmedAction.panelMain.mark.addObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.WHITE);
 						break;
 					}
 				} else {
-					dlg.panelMain.mark.setObjPattern(Pat.HSTRP);
-					switch (dlg.panelMain.mark.getRegion()) {
+					SmedAction.panelMain.mark.setObjPattern(Pat.HSTRP);
+					switch (SmedAction.panelMain.mark.getRegion()) {
 					case A:
-						dlg.panelMain.mark.setObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.RED);
+						SmedAction.panelMain.mark.setObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.RED);
 						break;
 					case B:
-						dlg.panelMain.mark.setObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.setObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
 						break;
 					case C:
-						dlg.panelMain.mark.setObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.setObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
 						break;
 					}
 				}
-				dlg.panelMain.panelMore.syncPanel();
+				SmedAction.panelMain.panelMore.syncPanel();
 			} else {
-				dlg.panelMain.panelChan.topmarkButton.setVisible(false);
-				dlg.panelMain.panelChan.lightButton.setVisible(false);
+				SmedAction.panelMain.panelChan.topmarkButton.setVisible(false);
+				SmedAction.panelMain.panelChan.lightButton.setVisible(false);
 			}
 		}
@@ -104,5 +104,5 @@
 		for (Shp shp : shapes.keySet()) {
 			JRadioButton button = shapes.get(shp);
-			if (dlg.panelMain.mark.getShape() == shp) {
+			if (SmedAction.panelMain.mark.getShape() == shp) {
 				button.setBorderPainted(true);
 			} else
Index: applications/editors/josm/plugins/smed/src/panels/PanelRadar.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelRadar.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelRadar.java	(revision 30738)
@@ -35,5 +35,5 @@
 				int idx = radioCats.get(cat);
 				if (dlg.node != null && (idx == radioCatBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setRadio(cat);
+					SmedAction.panelMain.mark.setRadio(cat);
 				}
 			}
@@ -52,5 +52,5 @@
 				JRadioButton button = rads.get(rtb);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setRadar(rtb);
+					SmedAction.panelMain.mark.setRadar(rtb);
 				}
 			}
@@ -62,5 +62,5 @@
 	private FocusListener flGroup = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setRaconGroup(groupBox.getText());
+			SmedAction.panelMain.mark.setRaconGroup(groupBox.getText());
 		}
 	};
@@ -69,5 +69,5 @@
 	private FocusListener flPeriod = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setRaconPeriod(periodBox.getText());
+			SmedAction.panelMain.mark.setRaconPeriod(periodBox.getText());
 		}
 	};
@@ -76,5 +76,5 @@
 	private FocusListener flSeq = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setRaconSequence(seqBox.getText());
+			SmedAction.panelMain.mark.setRaconSequence(seqBox.getText());
 		}
 	};
@@ -83,5 +83,5 @@
 	private FocusListener flRange = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setRaconRange(rangeBox.getText());
+			SmedAction.panelMain.mark.setRaconRange(rangeBox.getText());
 		}
 	};
@@ -90,5 +90,5 @@
 	private FocusListener flSector1 = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setRaconSector1(sector1Box.getText());
+			SmedAction.panelMain.mark.setRaconSector1(sector1Box.getText());
 		}
 	};
@@ -97,5 +97,5 @@
 	private FocusListener flSector2 = new FocusAdapter() {
 		public void focusLost(java.awt.event.FocusEvent e) {
-			dlg.panelMain.mark.setRaconSector2(sector2Box.getText());
+			SmedAction.panelMain.mark.setRaconSector2(sector2Box.getText());
 		}
 	};
@@ -204,5 +204,5 @@
 
 	public void syncPanel() {
-		boolean rad = ((dlg.panelMain.mark.getRadar() != Rtb.NORTB) && (dlg.panelMain.mark.getRadar() != Rtb.REFLECTOR));
+		boolean rad = ((SmedAction.panelMain.mark.getRadar() != Rtb.NORTB) && (SmedAction.panelMain.mark.getRadar() != Rtb.REFLECTOR));
 		groupLabel.setVisible(rad);
 		groupBox.setVisible(rad);
@@ -219,15 +219,15 @@
 		sectorsLabel.setVisible(rad);
 		for (Rtb rtb : rads.keySet()) {
-			rads.get(rtb).setBorderPainted(dlg.panelMain.mark.getRadar() == rtb);
-		}
-		groupBox.setText(dlg.panelMain.mark.getRaconGroup());
-		seqBox.setText(dlg.panelMain.mark.getRaconSequence());
-		periodBox.setText(dlg.panelMain.mark.getRaconPeriod());
-		rangeBox.setText(dlg.panelMain.mark.getRaconRange());
-		sector1Box.setText(dlg.panelMain.mark.getRaconSector1());
-		sector2Box.setText(dlg.panelMain.mark.getRaconSector2());
-		aisButton.setSelected(dlg.panelMain.mark.getRadio() != Cat.NOROS);
+			rads.get(rtb).setBorderPainted(SmedAction.panelMain.mark.getRadar() == rtb);
+		}
+		groupBox.setText(SmedAction.panelMain.mark.getRaconGroup());
+		seqBox.setText(SmedAction.panelMain.mark.getRaconSequence());
+		periodBox.setText(SmedAction.panelMain.mark.getRaconPeriod());
+		rangeBox.setText(SmedAction.panelMain.mark.getRaconRange());
+		sector1Box.setText(SmedAction.panelMain.mark.getRaconSector1());
+		sector2Box.setText(SmedAction.panelMain.mark.getRaconSector2());
+		aisButton.setSelected(SmedAction.panelMain.mark.getRadio() != Cat.NOROS);
 		aisButton.setBorderPainted(aisButton.isSelected());
-		radioCatBox.setVisible(dlg.panelMain.mark.getRadio() != Cat.NOROS);
+		radioCatBox.setVisible(SmedAction.panelMain.mark.getRadio() != Cat.NOROS);
 	}
 
Index: applications/editors/josm/plugins/smed/src/panels/PanelSaw.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelSaw.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelSaw.java	(revision 30738)
@@ -27,19 +27,19 @@
 				JRadioButton button = shapes.get(shp);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setShape(shp);
-					dlg.panelMain.mark.setObject(objects.get(shp));
+					SmedAction.panelMain.mark.setShape(shp);
+					SmedAction.panelMain.mark.setObject(objects.get(shp));
 					button.setBorderPainted(true);
 				} else
 					button.setBorderPainted(false);
 			}
-			if (dlg.panelMain.mark.testValid()) {
-				dlg.panelMain.panelChan.topmarkButton.setVisible(true);
-				dlg.panelMain.mark.setObjPattern(Pat.VSTRP);
-				dlg.panelMain.mark.setObjColour(Col.RED);
-				dlg.panelMain.mark.addObjColour(Col.WHITE);
+			if (SmedAction.panelMain.mark.testValid()) {
+				SmedAction.panelMain.panelChan.topmarkButton.setVisible(true);
+				SmedAction.panelMain.mark.setObjPattern(Pat.VSTRP);
+				SmedAction.panelMain.mark.setObjColour(Col.RED);
+				SmedAction.panelMain.mark.addObjColour(Col.WHITE);
 			} else {
-				dlg.panelMain.panelChan.topmarkButton.setVisible(false);
+				SmedAction.panelMain.panelChan.topmarkButton.setVisible(false);
 			}
-			dlg.panelMain.panelMore.syncPanel();
+			SmedAction.panelMain.panelMore.syncPanel();
 		}
 	};
@@ -58,10 +58,10 @@
 		for (Shp shp : shapes.keySet()) {
 			JRadioButton button = shapes.get(shp);
-			if (dlg.panelMain.mark.getShape() == shp) {
+			if (SmedAction.panelMain.mark.getShape() == shp) {
 				button.setBorderPainted(true);
 			} else
 				button.setBorderPainted(false);
 		}
-		dlg.panelMain.mark.testValid();
+		SmedAction.panelMain.mark.testValid();
 	}
 	
Index: applications/editors/josm/plugins/smed/src/panels/PanelSectors.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelSectors.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelSectors.java	(revision 30738)
@@ -123,8 +123,8 @@
 
 		public int getRowCount() {
-			if (dlg.panelMain == null)
+			if (SmedAction.panelMain == null)
 				return 1;
 			else
-				return dlg.panelMain.mark.getSectorCount();
+				return SmedAction.panelMain.mark.getSectorCount();
 		}
 
@@ -152,27 +152,27 @@
 					return row;
 			case 1:
-				if (((String)dlg.panelMain.mark.getLightAtt(Att.CHR, row)).contains("Al")) {
-					if (dlg.panelMain.mark.getLightAtt(Att.COL, row) == Col.UNKCOL) {
+				if (((String)SmedAction.panelMain.mark.getLightAtt(Att.CHR, row)).contains("Al")) {
+					if (SmedAction.panelMain.mark.getLightAtt(Att.COL, row) == Col.UNKCOL) {
 						return Col.UNKCOL;
 					} else {
-						return dlg.panelMain.mark.getLightAtt(Att.ALT, row);
+						return SmedAction.panelMain.mark.getLightAtt(Att.ALT, row);
 					}
 				} else {
-					return dlg.panelMain.mark.getLightAtt(Att.COL, row);
+					return SmedAction.panelMain.mark.getLightAtt(Att.COL, row);
 				}
 			case 6:
-				return (dlg.panelMain.mark.getLightAtt(Att.LIT, row) == Lit.DIR);
+				return (SmedAction.panelMain.mark.getLightAtt(Att.LIT, row) == Lit.DIR);
 			case 7:
 			case 8:
-				if (dlg.panelMain.mark.getLightAtt(Att.LIT, row) == Lit.DIR)
-					return dlg.panelMain.mark.getLightAtt(Att.ORT, row);
+				if (SmedAction.panelMain.mark.getLightAtt(Att.LIT, row) == Lit.DIR)
+					return SmedAction.panelMain.mark.getLightAtt(Att.ORT, row);
 				else
-					return dlg.panelMain.mark.getLightAtt(col - 1, row);
+					return SmedAction.panelMain.mark.getLightAtt(col - 1, row);
 			case 12:
-				return visibilities.get(dlg.panelMain.mark.getLightAtt(Att.VIS, row));
+				return visibilities.get(SmedAction.panelMain.mark.getLightAtt(Att.VIS, row));
 			case 13:
-				return exhibitions.get(dlg.panelMain.mark.getLightAtt(Att.EXH, row));
+				return exhibitions.get(SmedAction.panelMain.mark.getLightAtt(Att.EXH, row));
 			default:
-				return dlg.panelMain.mark.getLightAtt(col - 1, row);
+				return SmedAction.panelMain.mark.getLightAtt(col - 1, row);
 			}
 		}
@@ -184,13 +184,13 @@
 					ImageIcon img = colours.get(colour);
 					if (img == value)
-						if (((String)dlg.panelMain.mark.getLightAtt(Att.CHR, row)).contains("Al")) {
-							if (((colour == Col.UNKCOL) && (dlg.panelMain.mark.getLightAtt(Att.ALT, row) == Col.UNKCOL))
-									|| (dlg.panelMain.mark.getLightAtt(Att.COL, row) == Col.UNKCOL)) {
-								dlg.panelMain.mark.setLightAtt(Att.COL, row, colour);
+						if (((String)SmedAction.panelMain.mark.getLightAtt(Att.CHR, row)).contains("Al")) {
+							if (((colour == Col.UNKCOL) && (SmedAction.panelMain.mark.getLightAtt(Att.ALT, row) == Col.UNKCOL))
+									|| (SmedAction.panelMain.mark.getLightAtt(Att.COL, row) == Col.UNKCOL)) {
+								SmedAction.panelMain.mark.setLightAtt(Att.COL, row, colour);
 							} else {
-								dlg.panelMain.mark.setLightAtt(Att.ALT, row, colour);
+								SmedAction.panelMain.mark.setLightAtt(Att.ALT, row, colour);
 							}
 						} else {
-							dlg.panelMain.mark.setLightAtt(Att.COL, row, colour);
+							SmedAction.panelMain.mark.setLightAtt(Att.COL, row, colour);
 						}
 				}
@@ -200,22 +200,22 @@
 			case 10:
 			case 11:
-				dlg.panelMain.mark.setLightAtt(col - 1, row, value);
+				SmedAction.panelMain.mark.setLightAtt(col - 1, row, value);
 				break;
 			case 6:
 				if ((Boolean) value == true) {
-					dlg.panelMain.mark.setLightAtt(Att.LIT, row, Lit.DIR);
-					dlg.panelMain.mark.setLightAtt(Att.BEG, row, "");
-					dlg.panelMain.mark.setLightAtt(Att.END, row, "");
+					SmedAction.panelMain.mark.setLightAtt(Att.LIT, row, Lit.DIR);
+					SmedAction.panelMain.mark.setLightAtt(Att.BEG, row, "");
+					SmedAction.panelMain.mark.setLightAtt(Att.END, row, "");
 				} else {
-					dlg.panelMain.mark.setLightAtt(Att.LIT, row, Lit.UNKLIT);
-					dlg.panelMain.mark.setLightAtt(Att.ORT, row, "");
+					SmedAction.panelMain.mark.setLightAtt(Att.LIT, row, Lit.UNKLIT);
+					SmedAction.panelMain.mark.setLightAtt(Att.ORT, row, "");
 				}
 				break;
 			case 7:
 			case 8:
-				if (dlg.panelMain.mark.getLightAtt(Att.LIT, row) == Lit.DIR) {
-					dlg.panelMain.mark.setLightAtt(Att.ORT, row, value);
+				if (SmedAction.panelMain.mark.getLightAtt(Att.LIT, row) == Lit.DIR) {
+					SmedAction.panelMain.mark.setLightAtt(Att.ORT, row, value);
 				} else {
-					dlg.panelMain.mark.setLightAtt(col - 1, row, value);
+					SmedAction.panelMain.mark.setLightAtt(col - 1, row, value);
 				}
 				break;
@@ -224,5 +224,5 @@
 					String str = visibilities.get(vis);
 					if (str.equals(value))
-						dlg.panelMain.mark.setLightAtt(Att.VIS, row, vis);
+						SmedAction.panelMain.mark.setLightAtt(Att.VIS, row, vis);
 				}
 				break;
@@ -231,9 +231,9 @@
 					String str = exhibitions.get(exh);
 					if (str.equals(value))
-						dlg.panelMain.mark.setLightAtt(Att.EXH, row, exh);
+						SmedAction.panelMain.mark.setLightAtt(Att.EXH, row, exh);
 				}
 				break;
 			default:
-				dlg.panelMain.mark.setLightAtt(col - 1, row, value);
+				SmedAction.panelMain.mark.setLightAtt(col - 1, row, value);
 			}
 		}
@@ -261,10 +261,10 @@
 		}
 		public Component getTableCellRendererComponent(JTable table, Object value, boolean isSelected, boolean hasFocus, int rowIndex, int vColIndex) {
-			if (!((String)dlg.panelMain.mark.getLightAtt(Att.CHR, rowIndex)).contains("Al")) {
-				col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.COL, rowIndex)));
+			if (!((String)SmedAction.panelMain.mark.getLightAtt(Att.CHR, rowIndex)).contains("Al")) {
+				col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.COL, rowIndex)));
 			} else {
-				col2Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.ALT, rowIndex)));
-			}
-			col1Label.setBackground(SeaMark.ColMAP.get(dlg.panelMain.mark.getLightAtt(Att.COL, rowIndex)));
+				col2Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.ALT, rowIndex)));
+			}
+			col1Label.setBackground(SeaMark.ColMAP.get(SmedAction.panelMain.mark.getLightAtt(Att.COL, rowIndex)));
 			return this;
 		}
@@ -276,5 +276,5 @@
 
 	public void addSector(int idx) {
-		dlg.panelMain.mark.addLight(idx);
+		SmedAction.panelMain.mark.addLight(idx);
 		table.setSize(860, ((table.getRowCount() * 16) + 28));
 		if (table.getRowCount() > 3) {
@@ -287,5 +287,5 @@
 	public void deleteSector(int idx) {
 		if (idx > 0) {
-			dlg.panelMain.mark.delLight(idx);
+			SmedAction.panelMain.mark.delLight(idx);
 			table.setSize(860, ((table.getRowCount() * 16) + 28));
 			if (table.getRowCount() > 3) {
Index: applications/editors/josm/plugins/smed/src/panels/PanelSpec.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelSpec.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelSpec.java	(revision 30738)
@@ -24,5 +24,5 @@
 				int idx = categories.get(cat);
 				if (dlg.node != null && (idx == categoryBox.getSelectedIndex()))
-					dlg.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.setCategory(cat);
 			}
 		}
@@ -35,12 +35,12 @@
 				int idx = moorings.get(cat);
 				if (dlg.node != null && (idx == mooringBox.getSelectedIndex())) {
-					dlg.panelMain.mark.setCategory(cat);
+					SmedAction.panelMain.mark.setCategory(cat);
 					if ((cat == Cat.INB_CALM) || (cat == Cat.INB_SBM)) {
-						dlg.panelMain.mark.setObject(Obj.BOYINB);
-						dlg.panelMain.mark.setShape(Shp.UNKSHP);
+						SmedAction.panelMain.mark.setObject(Obj.BOYINB);
+						SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 					} else {
-						dlg.panelMain.mark.setObject(Obj.MORFAC);
+						SmedAction.panelMain.mark.setObject(Obj.MORFAC);
 						if (cat != Cat.MOR_BUOY)
-							dlg.panelMain.mark.setShape(Shp.UNKSHP);
+							SmedAction.panelMain.mark.setShape(Shp.UNKSHP);
 					}
 				}
@@ -66,20 +66,20 @@
 	public ActionListener alShape = new ActionListener() {
 		public void actionPerformed(java.awt.event.ActionEvent e) {
-			if ((dlg.panelMain.mark.getObject() != Obj.MORFAC) || (dlg.panelMain.mark.getCategory() == Cat.MOR_BUOY)) {
+			if ((SmedAction.panelMain.mark.getObject() != Obj.MORFAC) || (SmedAction.panelMain.mark.getCategory() == Cat.MOR_BUOY)) {
 				for (Shp shp : shapes.keySet()) {
 					JRadioButton button = shapes.get(shp);
 					if (button.isSelected()) {
-						dlg.panelMain.mark.setShape(shp);
-						if (SeaMark.EntMAP.get(dlg.panelMain.mark.getObject()) != Ent.MOORING) {
-							dlg.panelMain.mark.setObject(objects.get(shp));
-							if (dlg.panelMain.mark.getObjColour(0) == Col.UNKCOL) {
-								dlg.panelMain.mark.setObjPattern(Pat.NOPAT);
-								dlg.panelMain.mark.setObjColour(Col.YELLOW);
+						SmedAction.panelMain.mark.setShape(shp);
+						if (SeaMark.EntMAP.get(SmedAction.panelMain.mark.getObject()) != Ent.MOORING) {
+							SmedAction.panelMain.mark.setObject(objects.get(shp));
+							if (SmedAction.panelMain.mark.getObjColour(0) == Col.UNKCOL) {
+								SmedAction.panelMain.mark.setObjPattern(Pat.NOPAT);
+								SmedAction.panelMain.mark.setObjColour(Col.YELLOW);
 							}
 							if (button == cairnButton) {
-								dlg.panelMain.mark.setObjPattern(Pat.NOPAT);
-								dlg.panelMain.mark.setObjColour(Col.UNKCOL);
+								SmedAction.panelMain.mark.setObjPattern(Pat.NOPAT);
+								SmedAction.panelMain.mark.setObjColour(Col.UNKCOL);
 							}
-							topmarkButton.setVisible(dlg.panelMain.mark.testValid());
+							topmarkButton.setVisible(SmedAction.panelMain.mark.testValid());
 						}
 						button.setBorderPainted(true);
@@ -87,5 +87,5 @@
 						button.setBorderPainted(false);
 				}
-				dlg.panelMain.panelMore.syncPanel();
+				SmedAction.panelMain.panelMore.syncPanel();
 			}
 		}
@@ -95,15 +95,15 @@
 		public void actionPerformed(java.awt.event.ActionEvent e) {
 			if (topmarkButton.isSelected()) {
-				dlg.panelMain.mark.setTopmark(Top.X_SHAPE);
-				dlg.panelMain.mark.setTopPattern(Pat.NOPAT);
-				dlg.panelMain.mark.setTopColour(Col.YELLOW);
+				SmedAction.panelMain.mark.setTopmark(Top.X_SHAPE);
+				SmedAction.panelMain.mark.setTopPattern(Pat.NOPAT);
+				SmedAction.panelMain.mark.setTopColour(Col.YELLOW);
 				topmarkButton.setBorderPainted(true);
 			} else {
-				dlg.panelMain.mark.setTopmark(Top.NOTOP);
-				dlg.panelMain.mark.setTopPattern(Pat.NOPAT);
-				dlg.panelMain.mark.setTopColour(Col.UNKCOL);
+				SmedAction.panelMain.mark.setTopmark(Top.NOTOP);
+				SmedAction.panelMain.mark.setTopPattern(Pat.NOPAT);
+				SmedAction.panelMain.mark.setTopColour(Col.UNKCOL);
 				topmarkButton.setBorderPainted(false);
 			}
-			dlg.panelMain.panelTop.syncPanel();
+			SmedAction.panelMain.panelTop.syncPanel();
 		}
 	};
@@ -111,13 +111,13 @@
 	private ActionListener alNotice = new ActionListener() {
 		public void actionPerformed(java.awt.event.ActionEvent e) {
-			dlg.panelMain.mark.clrMark();
+			SmedAction.panelMain.mark.clrMark();
 			if (noticeButton.isSelected()) {
-				dlg.panelMain.mark.setObject(Obj.NOTMRK);
+				SmedAction.panelMain.mark.setObject(Obj.NOTMRK);
 				noticeButton.setBorderPainted(true);
 			} else {
-				dlg.panelMain.mark.setObject(Obj.UNKOBJ);
+				SmedAction.panelMain.mark.setObject(Obj.UNKOBJ);
 				noticeButton.setBorderPainted(false);
 			}
-			dlg.panelMain.syncPanel();
+			SmedAction.panelMain.syncPanel();
 		}
 	};
@@ -125,9 +125,9 @@
 	private ActionListener alMooring = new ActionListener() {
 		public void actionPerformed(java.awt.event.ActionEvent e) {
-			dlg.panelMain.mark.setObject(Obj.UNKOBJ);
-			dlg.panelMain.mark.setCategory(Cat.NOCAT);
-			dlg.panelMain.mark.setTopmark(Top.NOTOP);
+			SmedAction.panelMain.mark.setObject(Obj.UNKOBJ);
+			SmedAction.panelMain.mark.setCategory(Cat.NOCAT);
+			SmedAction.panelMain.mark.setTopmark(Top.NOTOP);
 			if (mooringButton.isSelected()) {
-				dlg.panelMain.mark.setObject(Obj.MORFAC);
+				SmedAction.panelMain.mark.setObject(Obj.MORFAC);
 				categoryBox.setVisible(false);
 				mooringBox.setVisible(true);
@@ -234,5 +234,5 @@
 
 	public void syncPanel() {
-		if (SeaMark.EntMAP.get(dlg.panelMain.mark.getObject()) == Ent.MOORING) {
+		if (SeaMark.EntMAP.get(SmedAction.panelMain.mark.getObject()) == Ent.MOORING) {
 			mooringButton.setBorderPainted(true);
 			categoryBox.setVisible(false);
@@ -248,5 +248,5 @@
 			for (Cat cat : moorings.keySet()) {
 				int item = moorings.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					mooringBox.setSelectedIndex(item);
 			}
@@ -262,10 +262,10 @@
 			cairnButton.setEnabled(true);
 			noticeButton.setEnabled(true);
-			topmarkButton.setBorderPainted(dlg.panelMain.mark.getTopmark() != Top.NOTOP);
-			topmarkButton.setSelected(dlg.panelMain.mark.getTopmark() != Top.NOTOP);
-			topmarkButton.setVisible(dlg.panelMain.mark.testValid());
+			topmarkButton.setBorderPainted(SmedAction.panelMain.mark.getTopmark() != Top.NOTOP);
+			topmarkButton.setSelected(SmedAction.panelMain.mark.getTopmark() != Top.NOTOP);
+			topmarkButton.setVisible(SmedAction.panelMain.mark.testValid());
 			for (Cat cat : categories.keySet()) {
 				int item = categories.get(cat);
-				if (dlg.panelMain.mark.getCategory() == cat)
+				if (SmedAction.panelMain.mark.getCategory() == cat)
 					categoryBox.setSelectedIndex(item);
 			}
@@ -273,5 +273,5 @@
 		for (Shp shp : shapes.keySet()) {
 			JRadioButton button = shapes.get(shp);
-			if (dlg.panelMain.mark.getShape() == shp) {
+			if (SmedAction.panelMain.mark.getShape() == shp) {
 				button.setBorderPainted(true);
 			} else
@@ -279,5 +279,5 @@
 		}
 		noticeButton.setBorderPainted(false);
-		dlg.panelMain.mark.testValid();
+		SmedAction.panelMain.mark.testValid();
 	}
 
Index: applications/editors/josm/plugins/smed/src/panels/PanelStbd.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelStbd.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelStbd.java	(revision 30738)
@@ -31,56 +31,56 @@
 				JRadioButton button = shapes.get(shp);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setShape(shp);
-					dlg.panelMain.mark.setObject(objects.get(shp));
+					SmedAction.panelMain.mark.setShape(shp);
+					SmedAction.panelMain.mark.setObject(objects.get(shp));
 					button.setBorderPainted(true);
 				} else
 					button.setBorderPainted(false);
 			}
-			if (dlg.panelMain.mark.testValid()) {
-				dlg.panelMain.panelChan.topmarkButton.setVisible(true);
-				dlg.panelMain.panelChan.lightButton.setVisible(true);
-				if (dlg.panelMain.mark.getCategory() == Cat.LAM_STBD) {
-					switch (dlg.panelMain.mark.getRegion()) {
+			if (SmedAction.panelMain.mark.testValid()) {
+				SmedAction.panelMain.panelChan.topmarkButton.setVisible(true);
+				SmedAction.panelMain.panelChan.lightButton.setVisible(true);
+				if (SmedAction.panelMain.mark.getCategory() == Cat.LAM_STBD) {
+					switch (SmedAction.panelMain.mark.getRegion()) {
 					case A:
-						dlg.panelMain.mark.setObjPattern(Pat.NOPAT);
-						dlg.panelMain.mark.setObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.setObjPattern(Pat.NOPAT);
+						SmedAction.panelMain.mark.setObjColour(Col.GREEN);
 						break;
 					case B:
-						dlg.panelMain.mark.setObjPattern(Pat.NOPAT);
-						dlg.panelMain.mark.setObjColour(Col.RED);
+						SmedAction.panelMain.mark.setObjPattern(Pat.NOPAT);
+						SmedAction.panelMain.mark.setObjColour(Col.RED);
 						break;
 					case C:
-						dlg.panelMain.mark.setObjPattern(Pat.HSTRP);
-						dlg.panelMain.mark.setObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.WHITE);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.WHITE);
+						SmedAction.panelMain.mark.setObjPattern(Pat.HSTRP);
+						SmedAction.panelMain.mark.setObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.WHITE);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.WHITE);
 						break;
 					}
 				} else {
-					dlg.panelMain.mark.setObjPattern(Pat.HSTRP);
-					switch (dlg.panelMain.mark.getRegion()) {
+					SmedAction.panelMain.mark.setObjPattern(Pat.HSTRP);
+					switch (SmedAction.panelMain.mark.getRegion()) {
 					case A:
-						dlg.panelMain.mark.setObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.setObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
 						break;
 					case B:
-						dlg.panelMain.mark.setObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.RED);
+						SmedAction.panelMain.mark.setObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.RED);
 						break;
 					case C:
-						dlg.panelMain.mark.setObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
-						dlg.panelMain.mark.addObjColour(Col.RED);
-						dlg.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.setObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
+						SmedAction.panelMain.mark.addObjColour(Col.RED);
+						SmedAction.panelMain.mark.addObjColour(Col.GREEN);
 						break;
 					}
 				}
-				dlg.panelMain.panelMore.syncPanel();
+				SmedAction.panelMain.panelMore.syncPanel();
 			} else {
-				dlg.panelMain.panelChan.topmarkButton.setVisible(false);
-				dlg.panelMain.panelChan.lightButton.setVisible(false);
+				SmedAction.panelMain.panelChan.topmarkButton.setVisible(false);
+				SmedAction.panelMain.panelChan.lightButton.setVisible(false);
 			}
 		}
@@ -104,5 +104,5 @@
 		for (Shp shp : shapes.keySet()) {
 			JRadioButton button = shapes.get(shp);
-			if (dlg.panelMain.mark.getShape() == shp) {
+			if (SmedAction.panelMain.mark.getShape() == shp) {
 				button.setBorderPainted(true);
 			} else
Index: applications/editors/josm/plugins/smed/src/panels/PanelTop.java
===================================================================
--- applications/editors/josm/plugins/smed/src/panels/PanelTop.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/panels/PanelTop.java	(revision 30738)
@@ -38,5 +38,5 @@
 				JRadioButton button = tops.get(top);
 				if (button.isSelected()) {
-					dlg.panelMain.mark.setTopmark(top);
+					SmedAction.panelMain.mark.setTopmark(top);
 					button.setBorderPainted(true);
 				} else
@@ -79,5 +79,5 @@
 		for (Top top : tops.keySet()) {
 			JRadioButton button = tops.get(top);
-			if (dlg.panelMain.mark.getTopmark() == top) {
+			if (SmedAction.panelMain.mark.getTopmark() == top) {
 				button.setBorderPainted(true);
 			} else
Index: applications/editors/josm/plugins/smed/src/seamarks/SeaMark.java
===================================================================
--- applications/editors/josm/plugins/smed/src/seamarks/SeaMark.java	(revision 30737)
+++ applications/editors/josm/plugins/smed/src/seamarks/SeaMark.java	(revision 30738)
@@ -1361,18 +1361,18 @@
 		}
 		if (tmp) {
-			dlg.panelMain.moreButton.setVisible(true);
-			dlg.panelMain.saveButton.setEnabled(true);
-			dlg.panelMain.topButton.setEnabled(true);
-			dlg.panelMain.fogButton.setEnabled(true);
-			dlg.panelMain.radButton.setEnabled(true);
-			dlg.panelMain.litButton.setEnabled(true);
+			SmedAction.panelMain.moreButton.setVisible(true);
+			SmedAction.panelMain.saveButton.setEnabled(true);
+			SmedAction.panelMain.topButton.setEnabled(true);
+			SmedAction.panelMain.fogButton.setEnabled(true);
+			SmedAction.panelMain.radButton.setEnabled(true);
+			SmedAction.panelMain.litButton.setEnabled(true);
 			return true;
 		} else {
-			dlg.panelMain.moreButton.setVisible(false);
-			dlg.panelMain.moreButton.setText(">>");
-			dlg.panelMain.topButton.setEnabled(false);
-			dlg.panelMain.fogButton.setEnabled(false);
-			dlg.panelMain.radButton.setEnabled(false);
-			dlg.panelMain.litButton.setEnabled(false);
+			SmedAction.panelMain.moreButton.setVisible(false);
+			SmedAction.panelMain.moreButton.setText(">>");
+			SmedAction.panelMain.topButton.setEnabled(false);
+			SmedAction.panelMain.fogButton.setEnabled(false);
+			SmedAction.panelMain.radButton.setEnabled(false);
+			SmedAction.panelMain.litButton.setEnabled(false);
 			PanelMain.messageBar.setText("Seamark not recognised");
 			return false;
@@ -1398,5 +1398,5 @@
 		setSource("");
 		setFixme("");
-		dlg.panelMain.syncPanel();
+		SmedAction.panelMain.syncPanel();
 		repaint();
 	}
