Changeset 6584 in josm


Ignore:
Timestamp:
2014-01-01T12:06:54+01:00 (11 years ago)
Author:
simon04
Message:

fix #9503 - Different syntax for .cfg and .mapcss validator files paths (implementation uses MirroredInputStream now)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/validation/tests/MapCSSTagChecker.java

    r6583 r6584  
    55
    66import java.io.BufferedReader;
    7 import java.io.File;
    8 import java.io.FileInputStream;
    97import java.io.InputStreamReader;
    108import java.io.Reader;
     
    4543import org.openstreetmap.josm.gui.mappaint.mapcss.parsergen.ParseException;
    4644import org.openstreetmap.josm.gui.widgets.EditableList;
     45import org.openstreetmap.josm.io.MirroredInputStream;
    4746import org.openstreetmap.josm.tools.CheckParameterUtil;
    4847import org.openstreetmap.josm.tools.GBC;
     
    395394        addMapCSS("geometry");
    396395        for (final String i : sourcesProperty.get()) {
    397             final String file = new File(i).getAbsolutePath();
    398396            try {
    399                 Main.info(tr("Adding {0} to tag checker", file));
    400                 addMapCSS(new BufferedReader(new InputStreamReader(new FileInputStream(i), Utils.UTF_8)));
     397                Main.info(tr("Adding {0} to tag checker", i));
     398                addMapCSS(new BufferedReader(new InputStreamReader(new MirroredInputStream(i), Utils.UTF_8)));
    401399            } catch (Exception ex) {
    402                 Main.warn(new RuntimeException(tr("Failed to add {0} to tag checker", file), ex));
     400                Main.warn(new RuntimeException(tr("Failed to add {0} to tag checker", i), ex));
    403401            }
    404402        }
Note: See TracChangeset for help on using the changeset viewer.