Changeset 12070 in josm for trunk/src/org/openstreetmap/josm


Ignore:
Timestamp:
2017-05-06T14:27:02+02:00 (3 years ago)
Author:
michael2402
Message:

Reset the SelectionEventManager listeners for each test.

File:
1 edited

Legend:

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

    r12048 r12070  
    147147        }
    148148    };
     149
     150    /**
     151     * Only to be used during unit tests, to reset the state. Do not use it in plugins/other code.
     152     * Called after the layer manager was reset by the test framework.
     153     */
     154    public void resetState() {
     155        inEDTListeners.clear();
     156        normalListeners.clear();
     157        Main.getLayerManager().addAndFireActiveLayerChangeListener(this);
     158    }
    149159}
Note: See TracChangeset for help on using the changeset viewer.