Changeset 3603 in josm for trunk/src


Ignore:
Timestamp:
2010-10-12T21:24:59+02:00 (14 years ago)
Author:
jttt
Message:

Fix iterator

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/data/osm/QuadBuckets.java

    r3584 r3603  
    154154
    155155        QBLevel findBucket(BBox bbox) {
    156             if (isLeaf())
     156            if (!hasChildren())
    157157                return this;
    158158            else {
     
    361361        QBLevel nextNode()
    362362        {
    363             if (this.isLeaf())
     363            if (!this.hasChildren())
    364364                return this.nextSibling();
    365365            return this.firstChild();
     
    417417                search_contents(search_bbox, result);
    418418            }
    419             if (this.isLeaf())
    420                 return;
    421419
    422420            if (debug) {
     
    449447        int index_of(QBLevel find_this)
    450448        {
    451             if (this.isLeaf())
    452                 return -1;
    453 
    454449            QBLevel[] children = getChildren();
    455450            for (int i = 0; i < QuadTiling.TILES_PER_LEVEL; i++) {
     
    632627                out(this + " is a new iterator qb: " + qb + " size: " + qb.size());
    633628            }
    634             if (qb.root.isLeaf() || qb.root.hasContent()) {
     629            if (!qb.root.hasChildren() || qb.root.hasContent()) {
    635630                current_node = qb.root;
    636631            } else {
Note: See TracChangeset for help on using the changeset viewer.