Fix and enhance image list handling