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

Unified Diff: chrome/renderer/chrome_render_view_observer.cc

Issue 6883020: Make icon_messages use the IPC macros for defining the structs and the serialization code, and mo... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 years, 8 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 | « chrome/common/render_messages.h ('k') | content/browser/renderer_host/render_view_host.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/renderer/chrome_render_view_observer.cc
===================================================================
--- chrome/renderer/chrome_render_view_observer.cc (revision 81979)
+++ chrome/renderer/chrome_render_view_observer.cc (working copy)
@@ -8,6 +8,7 @@
#include "base/message_loop.h"
#include "base/metrics/histogram.h"
#include "chrome/common/chrome_switches.h"
+#include "chrome/common/icon_messages.h"
#include "chrome/common/render_messages.h"
#include "chrome/common/thumbnail_score.h"
#include "chrome/common/url_constants.h"
@@ -141,7 +142,7 @@
IPC_MESSAGE_HANDLER(
ViewMsg_GetSerializedHtmlDataForCurrentPageWithLocalLinks,
OnGetSerializedHtmlDataForCurrentPageWithLocalLinks)
- IPC_MESSAGE_HANDLER(ViewMsg_DownloadFavicon, OnDownloadFavicon)
+ IPC_MESSAGE_HANDLER(IconMsg_DownloadFavicon, OnDownloadFavicon)
IPC_MESSAGE_HANDLER(ViewMsg_EnableViewSourceMode, OnEnableViewSourceMode)
IPC_MESSAGE_UNHANDLED(handled = false)
IPC_END_MESSAGE_MAP()
@@ -248,14 +249,14 @@
SkBitmap data_image = ImageFromDataUrl(image_url);
data_image_failed = data_image.empty();
if (!data_image_failed) {
- Send(new ViewHostMsg_DidDownloadFavicon(
+ Send(new IconHostMsg_DidDownloadFavicon(
routing_id(), id, image_url, false, data_image));
}
}
if (data_image_failed ||
!DownloadFavicon(id, image_url, image_size)) {
- Send(new ViewHostMsg_DidDownloadFavicon(
+ Send(new IconHostMsg_DidDownloadFavicon(
routing_id(), id, image_url, true, SkBitmap()));
}
}
@@ -306,8 +307,8 @@
GURL favicon_url(render_view()->webview()->mainFrame()->favIconURL());
if (!favicon_url.is_empty()) {
std::vector<FaviconURL> urls;
- urls.push_back(FaviconURL(favicon_url, FAVICON));
- Send(new ViewHostMsg_UpdateFaviconURL(
+ urls.push_back(FaviconURL(favicon_url, FaviconURL::FAVICON));
+ Send(new IconHostMsg_UpdateFaviconURL(
routing_id(), render_view()->page_id(), urls));
}
}
@@ -317,8 +318,8 @@
return;
std::vector<FaviconURL> urls;
- urls.push_back(FaviconURL(frame->favIconURL(), FAVICON));
- Send(new ViewHostMsg_UpdateFaviconURL(
+ urls.push_back(FaviconURL(frame->favIconURL(), FaviconURL::FAVICON));
+ Send(new IconHostMsg_UpdateFaviconURL(
routing_id(), render_view()->page_id(), urls));
}
@@ -584,7 +585,7 @@
void ChromeRenderViewObserver::DidDownloadFavicon(
ImageResourceFetcher* fetcher, const SkBitmap& image) {
// Notify requester of image download status.
- Send(new ViewHostMsg_DidDownloadFavicon(routing_id(),
+ Send(new IconHostMsg_DidDownloadFavicon(routing_id(),
fetcher->id(),
fetcher->image_url(),
image.isNull(),
« no previous file with comments | « chrome/common/render_messages.h ('k') | content/browser/renderer_host/render_view_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698