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

Unified Diff: components/favicon_base/favicon_callback.h

Issue 291643002: Move favicon callbacks to favicon_base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 7 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 | « components/favicon_base.gypi ('k') | components/favicon_base/favicon_types.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/favicon_base/favicon_callback.h
diff --git a/components/favicon_base/favicon_callback.h b/components/favicon_base/favicon_callback.h
new file mode 100644
index 0000000000000000000000000000000000000000..437c4ec55a7868664884a6d27d931348d14ec338
--- /dev/null
+++ b/components/favicon_base/favicon_callback.h
@@ -0,0 +1,33 @@
+// 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_FAVICON_BASE_FAVICON_CALLBACK_H_
+#define COMPONENTS_FAVICON_BASE_FAVICON_CALLBACK_H_
+
+#include <vector>
+
+#include "base/callback.h"
+
+namespace favicon_base {
+
+struct FaviconBitmapResult;
+struct FaviconImageResult;
+
+// Callback for functions that can be used to return a |gfx::Image| and the
+// |GURL| it is loaded from. They are returned as a |FaviconImageResult| object.
+typedef base::Callback<void(const FaviconImageResult&)> FaviconImageCallback;
+
+// Callback for functions returning raw data for a favicon. In
+// |FaviconBitmapResult|, the data is not yet converted as a |gfx::Image|.
+typedef base::Callback<void(const FaviconBitmapResult&)> FaviconRawCallback;
+
+// Callback for functions returning raw data for a favicon in multiple
+// resolution. In |FaviconBitmapResult|, the data is not yet converted as a
+// |gfx::Image|.
+typedef base::Callback<void(const std::vector<FaviconBitmapResult>&)>
+ FaviconResultsCallback;
+
+} // namespace favicon_base
+
+#endif // COMPONENTS_FAVICON_BASE_FAVICON_CALLBACK_H_
« no previous file with comments | « components/favicon_base.gypi ('k') | components/favicon_base/favicon_types.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698