]> git.openstreetmap.org Git - potlatch2.git/blobdiff - net/systemeD/potlatch2/controller/SelectedWay.as
add a Douglas-Peucker simplify action (currently accessed by a keypress, but will...
[potlatch2.git] / net / systemeD / potlatch2 / controller / SelectedWay.as
index f0b2c7065518d9ca6e21543d3c5e1e456a5e413c..776b2d0630974467ca347c48fdd83df86b01717a 100644 (file)
@@ -4,6 +4,7 @@ package net.systemeD.potlatch2.controller {
        import flash.ui.Keyboard;
     import net.systemeD.potlatch2.EditController;
     import net.systemeD.potlatch2.tools.Quadrilateralise;
+    import net.systemeD.potlatch2.tools.Simplify;
     import net.systemeD.halcyon.connection.*;
        import net.systemeD.halcyon.MapPaint;
        import net.systemeD.halcyon.Globals;
@@ -61,6 +62,7 @@ package net.systemeD.potlatch2.controller {
                        switch (event.keyCode) {
                                case 81:                                        Quadrilateralise.quadrilateralise(selectedWay); return this;
                 case 82:                    selectedWay.reverseNodes(MainUndoStack.getGlobalStack().addAction); return this;         
+                case 89:                    Simplify.simplify(selectedWay, controller.map, true); return this;         
                                case Keyboard.BACKSPACE:        if (event.shiftKey) { return deleteWay(); } break;
                                case Keyboard.DELETE:           if (event.shiftKey) { return deleteWay(); } break;
                        }