gfx::Image has
ToNSImage()
AsNSImage()
CopyNSImage()
and corresponding versions for other platform images. Their differences are subtle.
ToXXXImage() has undefined behavior if the image is null.
AsXXXImage() returns null if the image is null.
CopyXXXImage() has undefined behavior if the image is null *and* returns an owning raw pointer to the image.
Having these three different versions is confusing. We should keep only one, AsXXXImage, that has no undefined behavior.
Comment 1 by rsesek@chromium.org
, Nov 13