| Index: chrome/browser/thumbnails/thumbnail_service.h
|
| diff --git a/chrome/browser/thumbnails/thumbnail_service.h b/chrome/browser/thumbnails/thumbnail_service.h
|
| index 53da3e637e590bb942354d8071b5a711a04588ca..9daafa7fb0374665c39a5b047bd1691722535f78 100644
|
| --- a/chrome/browser/thumbnails/thumbnail_service.h
|
| +++ b/chrome/browser/thumbnails/thumbnail_service.h
|
| @@ -16,6 +16,9 @@ class RefCountedMemory;
|
|
|
| namespace thumbnails {
|
|
|
| +class ThumbnailingAlgorithm;
|
| +struct ThumbnailingContext;
|
| +
|
| // An interface abstracting access to thumbnails. Intended as a temporary
|
| // bridge facilitating switch from TopSites as the thumbnail source to a more
|
| // robust way of handling these artefacts.
|
| @@ -24,9 +27,15 @@ class ThumbnailService : public RefcountedProfileKeyedService {
|
| // Sets the given thumbnail for the given URL. Returns true if the thumbnail
|
| // was updated. False means either the URL wasn't known to us, or we felt
|
| // that our current thumbnail was superior to the given one.
|
| - virtual bool SetPageThumbnail(const GURL& url,
|
| - const gfx::Image& thumbnail,
|
| - const ThumbnailScore& score) = 0;
|
| + virtual bool SetPageThumbnail(const ThumbnailingContext& context,
|
| + const gfx::Image& thumbnail) = 0;
|
| +
|
| + // Returns the ThumbnailingAlgorithm used for processing thumbnails.
|
| + // It is always a new instance, the caller owns it. It will encapsulate the
|
| + // process of creating a thumbnail from tab contents. The lifetime of these
|
| + // instances is limited to the act of processing a single tab image. They
|
| + // are permitted to hold the state of such process.
|
| + virtual ThumbnailingAlgorithm* GetThumbnailingAlgorithm() const = 0;
|
|
|
| // Gets a thumbnail for a given page. Returns true iff we have the thumbnail.
|
| // This may be invoked on any thread.
|
|
|