if (UploadAction.warnUploadDiscouraged(getEditLayer())) {
return;
}
}
UploadHullBuilder builder = new UploadHullBuilder();
UploadSelectionDialog dialog = new UploadSelectionDialog();
Collection<OsmPrimitive> modifiedCandidates = getModifiedPrimitives(getEditLayer().data.getAllSelected());
Collection<OsmPrimitive> deletedCandidates = getDeletedPrimitives(getEditLayer().data);
if (modifiedCandidates.isEmpty() && deletedCandidates.isEmpty()) {
JOptionPane.showMessageDialog(
Main.parent,
tr("No changes to upload."),
tr("Warning"),
JOptionPane.INFORMATION_MESSAGE
);
return;
}
dialog.populate(
modifiedCandidates,
deletedCandidates
);
dialog.setVisible(true);
if (dialog.isCanceled())
return;
Collection<OsmPrimitive> toUpload = builder.build(dialog.getSelectedPrimitives());
if (toUpload.isEmpty()) {
JOptionPane.showMessageDialog(
Main.parent,
tr("No changes to upload."),
tr("Warning"),