[josm-dev] Patch for Surveyor plugin

Jonathan Pilborough lists at jonathanp.co.uk
Sun May 18 19:50:28 BST 2008


It seems file attachments aren't allowed here, so:

Index: SetWaypointAction.java
===================================================================
--- SetWaypointAction.java      (revision 7852)
+++ SetWaypointAction.java      (working copy)
@@ -85,7 +85,7 @@
         waypoint.attr.put("name", markerText);
         waypoint.attr.put("sym", iconName);
         synchronized(LiveGpsLock.class) {
-            layer.data.add(new Marker(event.getCoordinates(), markerText, 
iconName));
+            layer.data.add(new Marker(event.getCoordinates(), markerText, 
iconName,null,0,0));
             if(gpsLayer != null) {
                 gpsLayer.data.waypoints.add(waypoint);
             }
@@ -104,7 +104,7 @@
            
             if(markerLayer == null) {
                 // not found, add a new one
-                markerLayer = new MarkerLayer(new GpxData(), 
MARKER_LAYER_NAME, null);
+                markerLayer = new MarkerLayer(new GpxData(), 
MARKER_LAYER_NAME, null,null);
                 Main.main.addLayer(markerLayer);
             }
         }

On Sunday 18 May 2008 19:33:05 Jonathan Pilborough wrote:
> Hi,
>
> I installed JOSM today and was hit by a problem with the Surveyor plugin
> that had already been posted in http://josm.openstreetmap.de/ticket/537.
>
> It seems that the constructors for the MarkerLayer and Marker classes have
> been changed in changeset 553, which makes the surveyor plugin uncompilable
> against the JOSM jar since then, and obviously unrunnable when trying to
> create markers.
>
> I have added dummy values to the Surveyor plugin where this was a problem 
> and it seemed to fix the problem - my updated source file is attached.
>
> I have only done simple testing on this patch, hopefully someone with more
> experience of the source than me can take a look at it - I have no idea
> whether the new constructor arguments are important, or what they are used
> for.



-- 
Regards,
Jonathan Pilborough




More information about the josm-dev mailing list