reorder layers and trigger legends