Changeset 18019 in josm


Ignore:
Timestamp:
2021-07-14T19:16:41+02:00 (3 months ago)
Author:
Don-vip
Message:

fix #20955 - restrict "Overlapping Areas" test to completely downloaded primitives

Location:
trunk
Files:
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/resources/data/validator/geometry.mapcss

    r17957 r18019  
    211211}
    212212
    213 area:closed:areaStyle ⧉ area:closed:areaStyle {
     213area:completely_downloaded:closed:areaStyle ⧉ area:completely_downloaded:closed:areaStyle {
    214214  throwOther: tr("Overlapping Areas");
    215215}
  • trunk/src/org/openstreetmap/josm/data/osm/IWay.java

    r16119 r18019  
    133133     */
    134134    boolean isInnerNode(INode n);
     135
     136    /**
     137     * Replies true if this way has incomplete nodes, false otherwise.
     138     * @return true if this way has incomplete nodes, false otherwise.
     139     * @since 18019
     140     */
     141    default boolean hasIncompleteNodes() {
     142        return false;
     143    }
    135144}
  • trunk/src/org/openstreetmap/josm/data/osm/Way.java

    r17981 r18019  
    606606    }
    607607
    608     /**
    609      * Replies true if this way has incomplete nodes, false otherwise.
    610      * @return true if this way has incomplete nodes, false otherwise.
    611      * @since 2587
    612      */
     608    @Override
    613609    public boolean hasIncompleteNodes() {
    614610        return Arrays.stream(nodes).anyMatch(Node::isIncomplete);
  • trunk/src/org/openstreetmap/josm/gui/mappaint/mapcss/ConditionFactory.java

    r17867 r18019  
    850850            if (e.osm instanceof IRelation<?>) {
    851851                return !((IRelation<?>) e.osm).hasIncompleteMembers();
     852            } else if (e.osm instanceof IWay<?>) {
     853                return !((IWay<?>) e.osm).hasIncompleteNodes();
     854            } else if (e.osm instanceof INode) {
     855                return ((INode) e.osm).isLatLonKnown();
    852856            } else {
    853857                return true;
Note: See TracChangeset for help on using the changeset viewer.