mirror of
https://github.com/FoggedLens/iD.git
synced 2026-05-24 00:54:03 +02:00
Add validation warning for unsquare buildings
This commit is contained in:
@@ -10,6 +10,10 @@ export function operationCircularize(selectedIDs, context) {
|
||||
var extent = entity.extent(context.graph());
|
||||
var geometry = context.geometry(entityID);
|
||||
var action = actionCircularize(entityID, context.projection);
|
||||
action.onCompletion = function() {
|
||||
// revalidate in case this is a building that's no longer squarable
|
||||
context.validator().validate();
|
||||
};
|
||||
var nodes = utilGetAllNodes(selectedIDs, context.graph());
|
||||
var coords = nodes.map(function(n) { return n.loc; });
|
||||
var _disabled;
|
||||
|
||||
@@ -10,6 +10,13 @@ export function operationOrthogonalize(selectedIDs, context) {
|
||||
var _geometry;
|
||||
var _disabled;
|
||||
var action = chooseAction();
|
||||
if (action) {
|
||||
action.onCompletion = function() {
|
||||
// revalidate in case a building was squared
|
||||
context.validator().validate();
|
||||
};
|
||||
}
|
||||
|
||||
var nodes = utilGetAllNodes(selectedIDs, context.graph());
|
||||
var coords = nodes.map(function(n) { return n.loc; });
|
||||
|
||||
|
||||
Reference in New Issue
Block a user