Changeset 5100 in josm for trunk/src/org/openstreetmap
- Timestamp:
- 2012-03-18T12:59:28+01:00 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/actions/mapmode/DrawAction.java
r5099 r5100 137 137 * Checks if a map redraw is required and does so if needed. Also updates the status bar 138 138 */ 139 private voidredrawIfRequired() {139 private boolean redrawIfRequired() { 140 140 updateStatusLine(); 141 141 // repaint required if the helper line is active. … … 157 157 158 158 if ((!drawHelperLine || wayIsFinished) && !drawTargetHighlight) 159 return; 159 return false; 160 160 161 161 // update selection to reflect which way being modified … … 177 177 Main.map.mapView.repaint(); 178 178 } 179 return needsRepaint; 179 180 } 180 181 … … 864 865 mousePos = e.getPoint(); 865 866 snapHelper.noSnapNow(); 866 Main.map.mapView.repaint(); 867 boolean repaintIssued = removeHighlighting(); 868 // force repaint in case snapHelper needs one. If removeHighlighting 869 // caused one already, don’t do it again. 870 if(!repaintIssued) { 871 Main.map.mapView.repaint(); 872 } 867 873 } 868 874 … … 1040 1046 /** 1041 1047 * Removes target highlighting from primitives. Issues repaint if required. 1048 * Returns true if a repaint has been issued. 1042 1049 */ 1043 private voidremoveHighlighting() {1050 private boolean removeHighlighting() { 1044 1051 newHighlights = new HashSet<OsmPrimitive>(); 1045 redrawIfRequired(); 1052 return redrawIfRequired(); 1046 1053 } 1047 1054
Note:
See TracChangeset
for help on using the changeset viewer.