Fix sorting of container list (see #10242) (rebased onto develop)



This is the same as gh-644 but rebased onto develop.

----

Fix https://trac.openmicroscopy.org.uk/ome/ticket/10242
Screenshot attached to ticket