Modified image loading from gallery