Changes needed for new Gallery fixes