Changeset 26471 in osm for applications


Ignore:
Timestamp:
2011-08-07T12:01:15+02:00 (13 years ago)
Author:
jttt
Message:

Adapt to latest josm

Location:
applications/editors/josm/plugins/gpxfilter
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/gpxfilter/build.xml

    r26174 r26471  
    3232    <property name="commit.message" value="Commit message"/>
    3333    <!-- enter the *lowest* JOSM version this plugin is currently compatible with -->
    34     <property name="plugin.main.version" value="3835"/>
     34    <property name="plugin.main.version" value="4282"/>
    3535    <!--
    3636      ************************************************
     
    148148    </target>
    149149    <!--
    150     ************************** Publishing the plugin *********************************** 
    151     -->
    152     <!--
    153         ** extracts the JOSM release for the JOSM version in ../core and saves it in the 
     150    ************************** Publishing the plugin ***********************************
     151    -->
     152    <!--
     153        ** extracts the JOSM release for the JOSM version in ../core and saves it in the
    154154        ** property ${coreversion.info.entry.revision}
    155155        **
     
    197197    </target>
    198198    <!--
    199         ** commits the plugin.jar 
     199        ** commits the plugin.jar
    200200        -->
    201201    <target name="commit-dist">
    202202        <echo>
    203203    ***** Properties of published ${plugin.jar} *****
    204     Commit message    : '${commit.message}'                   
     204    Commit message    : '${commit.message}'
    205205    Plugin-Mainversion: ${plugin.main.version}
    206206    JOSM build version: ${coreversion.info.entry.revision}
    207207    Plugin-Version    : ${version.entry.commit.revision}
    208     ***** / Properties of published ${plugin.jar} *****                   
    209                        
     208    ***** / Properties of published ${plugin.jar} *****
     209
    210210    Now commiting ${plugin.jar} ...
    211211    </echo>
  • applications/editors/josm/plugins/gpxfilter/src/gpxfilter/EGpxLayer.java

    r23541 r26471  
    1818import java.awt.geom.Rectangle2D;
    1919import java.io.File;
     20import java.net.MalformedURLException;
     21import java.net.URL;
    2022import java.text.DateFormat;
    2123import java.util.ArrayList;
     
    123125                        data.mergeFrom(newData);
    124126                    }
    125                    
     127
    126128                    if (!EGpxLayer.this.painting) {
    127129                        Main.map.repaint();
     
    934936     */
    935937    private void importAudio(File wavFile, MarkerLayer ml, double firstStartTime, Markers markers) {
    936         String uri = "file:".concat(wavFile.getAbsolutePath());
     938        URL url = null;
     939        try {
     940            url = wavFile.toURI().toURL();
     941        } catch (MalformedURLException e) {
     942            System.err.println("Unable to convert filename " + wavFile.getAbsolutePath() + " to URL");
     943        }
    937944        Collection<WayPoint> waypoints = new ArrayList<WayPoint>();
    938945        boolean timedMarkersOmitted = false;
     
    11031110            }
    11041111            double offset = w.time - firstTime;
    1105             String name;
    1106             if (w.attr.containsKey("name")) {
    1107                 name = w.getString("name");
    1108             } else if (w.attr.containsKey("desc")) {
    1109                 name = w.getString("desc");
    1110             } else {
    1111                 name = AudioMarker.inventName(offset);
    1112             }
    1113             AudioMarker am = AudioMarker.create(w.getCoor(), name, uri, ml, w.time, offset);
     1112            AudioMarker am = new AudioMarker(w.getCoor(), w, url, ml, w.time, offset);
    11141113            /*
    11151114             * timeFromAudio intended for future use to shift markers of this type on
Note: See TracChangeset for help on using the changeset viewer.