Sort choices in node editor.
This was copied off branch jingxian2