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

Unified Diff: chrome/browser/android/tab_android.cc

Issue 1407353012: Refactor FaviconDriver::OnFaviconAvailable() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@initial_simplify
Patch Set: Created 5 years, 1 month 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
Index: chrome/browser/android/tab_android.cc
diff --git a/chrome/browser/android/tab_android.cc b/chrome/browser/android/tab_android.cc
index 029e63695cdff20bfe14a7672cf6999de2d29ced..6f8ae3fba7294d5999e533690a9a8df3825f33be 100644
--- a/chrome/browser/android/tab_android.cc
+++ b/chrome/browser/android/tab_android.cc
@@ -374,7 +374,16 @@ void TabAndroid::Observe(int type,
}
}
-void TabAndroid::OnFaviconAvailable(const gfx::Image& image) {
+void TabAndroid::OnFaviconUpdated(favicon::FaviconDriver* favicon_driver,
+ NotificationIconType notification_icon_type,
+ const GURL& icon_url,
+ bool icon_url_changed,
+ const gfx::Image& image) {
+ if (notification_icon_type != NON_TOUCH_LARGEST &&
+ notification_icon_type != TOUCH_LARGEST) {
+ return;
+ }
+
SkBitmap favicon = image.AsImageSkia().GetRepresentation(1.0f).sk_bitmap();
if (favicon.empty())
return;
@@ -384,10 +393,6 @@ void TabAndroid::OnFaviconAvailable(const gfx::Image& image) {
gfx::ConvertToJavaBitmap(&favicon).obj());
}
-void TabAndroid::OnFaviconUpdated(favicon::FaviconDriver* favicon_driver,
- bool icon_url_changed) {
-}
-
void TabAndroid::Destroy(JNIEnv* env, jobject obj) {
delete this;
}

Powered by Google App Engine
This is Rietveld 408576698