Changeset 3925 in josm


Ignore:
Timestamp:
2011-02-22T00:02:18+01:00 (9 years ago)
Author:
bastiK
Message:

fixed #5963 (patch by Petr_Dlouhy) - Relation editor fails to detect closed path

Location:
trunk
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/gui/dialogs/relation/MemberTableModel.java

    r3789 r3925  
    961961        for (int i=0; i<members.size(); ++i) {
    962962            final RelationMember m = members.get(i);
    963             if (! m.isWay()) {
    964                 con.set(i, new WayConnectionType());
    965                 firstGroupIdx = i;
    966                 continue;
    967             }
    968 
    969             final Way w = m.getWay();
    970             if (w == null || w.isIncomplete()) {
     963            if (!m.isWay() || m.getWay() == null || m.getWay().isIncomplete()) {
     964                if(i > 0) makeLoopIfNeeded(con, i-1);
    971965                con.set(i, new WayConnectionType());
    972966                firstGroupIdx = i;
     
    10231017        makeLoopIfNeeded(con, members.size()-1);
    10241018        connectionType = con;
    1025         //        for (int i=0; i<con.size(); ++i) {
    1026         //            System.err.println(con.get(i));
    1027         //        }
    10281019    }
    10291020
  • trunk/src/org/openstreetmap/josm/gui/dialogs/relation/WayConnectionType.java

    r3788 r3925  
    4040    public boolean isOnewayHead = false;
    4141    public boolean isOnewayTail = false;
    42 //    public boolean isOnewayOppositeConnected = true;
    4342
    4443    public WayConnectionType(boolean linkPrev, boolean linkNext, Direction direction) {
Note: See TracChangeset for help on using the changeset viewer.