Fix setting of caption in the thumbnails widget