Index: components/suggestions/image_fetcher_delegate.h |
diff --git a/components/suggestions/image_fetcher_delegate.h b/components/suggestions/image_fetcher_delegate.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..f2335efe026284aa99307b3ff00d63ab7fd45c83 |
--- /dev/null |
+++ b/components/suggestions/image_fetcher_delegate.h |
@@ -0,0 +1,29 @@ |
+// Copyright 2014 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef COMPONENTS_SUGGESTIONS_IMAGE_FETCHER_DELEGATE_H_ |
+#define COMPONENTS_SUGGESTIONS_IMAGE_FETCHER_DELEGATE_H_ |
+ |
+class GURL; |
+class SkBitmap; |
+ |
+namespace suggestions { |
+ |
+class ImageFetcherDelegate { |
+ public: |
+ ImageFetcherDelegate() {} |
+ |
+ // Called when an image was fetched. |url| represents the website for which |
+ // the image was fetched. |bitmap| is deleted once out of scope. |
+ virtual void OnImageFetched(const GURL& url, const SkBitmap* bitmap) = 0; |
+ |
+ protected: |
+ virtual ~ImageFetcherDelegate() {} |
+ |
+ DISALLOW_COPY_AND_ASSIGN(ImageFetcherDelegate); |
+}; |
+ |
+} // namespace suggestions |
+ |
+#endif // COMPONENTS_SUGGESTIONS_IMAGE_FETCHER_DELEGATE_H_ |