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

Unified Diff: chrome/browser/chromeos/login/image_downloader.cc

Issue 8373021: Convert URLFetcher::Delegates to use an interface in content/public/common. Also remove the old U... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: sync and remove unncessary forward declares Created 9 years, 2 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
Index: chrome/browser/chromeos/login/image_downloader.cc
===================================================================
--- chrome/browser/chromeos/login/image_downloader.cc (revision 106929)
+++ chrome/browser/chromeos/login/image_downloader.cc (working copy)
@@ -12,6 +12,7 @@
#include "base/stringprintf.h"
#include "chrome/browser/profiles/profile_manager.h"
#include "content/browser/browser_thread.h"
+#include "content/common/net/url_fetcher.h"
namespace chromeos {
@@ -39,16 +40,13 @@
ImageDownloader::~ImageDownloader() {}
-void ImageDownloader::OnURLFetchComplete(const URLFetcher* source,
- const GURL& url,
- const net::URLRequestStatus& status,
- int response_code,
- const net::ResponseCookies& cookies,
- const std::string& data) {
+void ImageDownloader::OnURLFetchComplete(const URLFetcher* source) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
- if (response_code != 200) {
- LOG(ERROR) << "Response code is " << response_code;
- LOG(ERROR) << "Url is " << url.spec();
+ std::string data;
+ source->GetResponseAsString(&data);
+ if (source->response_code() != 200) {
+ LOG(ERROR) << "Response code is " << source->response_code();
+ LOG(ERROR) << "Url is " << source->url().spec();
LOG(ERROR) << "Data is " << data;
MessageLoop::current()->DeleteSoon(FROM_HERE, this);
return;

Powered by Google App Engine
This is Rietveld 408576698