Removing redundant image-list code