Pulled out for use in the nav_panel.py page sorting.