Last change
on this file since 16162 was 16162, checked in by jttt, 15 years ago |
Use getter for Node.coor and Node.eastNorth
|
-
Property svn:eol-style
set to
native
|
File size:
914 bytes
|
Line | |
---|
1 | package UtilsPlugin;
|
---|
2 |
|
---|
3 | import javax.swing.JMenuItem;
|
---|
4 |
|
---|
5 | import org.openstreetmap.josm.Main;
|
---|
6 | import org.openstreetmap.josm.gui.MainMenu;
|
---|
7 | import org.openstreetmap.josm.gui.MapFrame;
|
---|
8 | import org.openstreetmap.josm.plugins.Plugin;
|
---|
9 |
|
---|
10 | public class UtilsPlugin extends Plugin {
|
---|
11 | JMenuItem SimplifyWay;
|
---|
12 | JMenuItem JoinAreas;
|
---|
13 | JumpToAction JumpToAct = new JumpToAction();
|
---|
14 |
|
---|
15 | public UtilsPlugin() {
|
---|
16 | SimplifyWay = MainMenu.add(Main.main.menu.toolsMenu, new SimplifyWayAction());
|
---|
17 | JoinAreas = MainMenu.add(Main.main.menu.toolsMenu, new JoinAreasAction());
|
---|
18 | SimplifyWay.setEnabled(false);
|
---|
19 | }
|
---|
20 |
|
---|
21 | @Override
|
---|
22 | public void mapFrameInitialized(MapFrame oldFrame, MapFrame newFrame) {
|
---|
23 | if (oldFrame == null && newFrame != null) {
|
---|
24 | SimplifyWay.setEnabled(true);
|
---|
25 | JoinAreas.setEnabled(true);
|
---|
26 | newFrame.statusLine.addMouseListener(JumpToAct);
|
---|
27 | }
|
---|
28 | }
|
---|
29 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.