Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(536)

Unified Diff: ui/gfx/image/image_skia_source.h

Issue 1846513002: Make HasRepresentation() work better for vector images. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@deinline_imageskiastorage
Patch Set: Add DCHECK Created 4 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/gfx/image/image_skia.cc ('k') | ui/gfx/image/image_skia_source.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/gfx/image/image_skia_source.h
diff --git a/ui/gfx/image/image_skia_source.h b/ui/gfx/image/image_skia_source.h
index 6250032292bd74c97dbde10b25c7a173c50cf774..9c50760edb6b9d833c85ef193d567eadf2c4a528 100644
--- a/ui/gfx/image/image_skia_source.h
+++ b/ui/gfx/image/image_skia_source.h
@@ -15,13 +15,17 @@ class ImageSkiaRep;
class GFX_EXPORT ImageSkiaSource {
public:
- virtual ~ImageSkiaSource() {}
+ virtual ~ImageSkiaSource();
// Returns the ImageSkiaRep for the given |scale|. ImageSkia caches the
// returned ImageSkiaRep and calls this method only if it doesn't have
// ImageSkiaRep for given |scale|. There is no need for the implementation to
// cache the image.
virtual gfx::ImageSkiaRep GetImageForScale(float scale) = 0;
+
+ // Subclasses should override this to return true when they are capable of
+ // providing an exact representation at any desired scale factor.
+ virtual bool HasRepresentationAtAllScales() const;
};
} // namespace gfx
« no previous file with comments | « ui/gfx/image/image_skia.cc ('k') | ui/gfx/image/image_skia_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698