order phases logically
backport drag-and-drop patch from non-ESR