if (newContextIndex < 0 || newContextIndex > mapContent.layers().size() - 1) {
return;
}
if (contextIndex != newContextIndex) {
mapContent.moveLayer(contextIndex, newContextIndex);
pane.redraw();
Collections.swap(layersList, viewerIndex, newViewerIndex);
mapLayerTableViewer.refresh();
}