From 15525d48024d325c8a52766d8ca727191251a8d4 Mon Sep 17 00:00:00 2001 From: Patrick Scott Date: Mon, 21 Sep 2009 13:39:37 -0400 Subject: Update the correct favicon when starting the load. The WebView's original url and current url are incorrect during the provisional load. Use the given url instead when updating the favicon. --- src/com/android/browser/BrowserBookmarksAdapter.java | 11 ++--------- 1 file changed, 2 insertions(+), 9 deletions(-) (limited to 'src/com/android/browser/BrowserBookmarksAdapter.java') diff --git a/src/com/android/browser/BrowserBookmarksAdapter.java b/src/com/android/browser/BrowserBookmarksAdapter.java index bd2916674..36af1fc8a 100644 --- a/src/com/android/browser/BrowserBookmarksAdapter.java +++ b/src/com/android/browser/BrowserBookmarksAdapter.java @@ -258,18 +258,11 @@ class BrowserBookmarksAdapter extends BaseAdapter { * Update the bookmark's favicon. This is a convenience method for updating * a bookmark favicon for the originalUrl and url of the passed in WebView. * @param cr The ContentResolver to use. - * @param WebView The WebView containing the url to update. + * @param originalUrl The original url before any redirects. + * @param url The current url. * @param favicon The favicon bitmap to write to the db. */ /* package */ static void updateBookmarkFavicon(ContentResolver cr, - WebView view, Bitmap favicon) { - if (view != null) { - updateBookmarkFavicon(cr, view.getOriginalUrl(), view.getUrl(), - favicon); - } - } - - private static void updateBookmarkFavicon(ContentResolver cr, String originalUrl, String url, Bitmap favicon) { final Cursor c = queryBookmarksForUrl(cr, originalUrl, url, true); if (c == null) { -- cgit v1.2.3