rlz: Move UrlFetcher to net, part 1
BUG=chromium:118220
TEST=none
Review URL: https://codereview.appspot.com/6200066
git-svn-id: http://rlz.googlecode.com/svn/trunk@128 10bc0f33-e4bf-9a86-80cf-af638054f0c4
diff --git a/lib/financial_ping.cc b/lib/financial_ping.cc
index 28ecd96..96425c6 100644
--- a/lib/financial_ping.cc
+++ b/lib/financial_ping.cc
@@ -51,6 +51,8 @@
#include "content/public/common/url_fetcher_delegate.h"
#include "googleurl/src/gurl.h"
#include "net/base/load_flags.h"
+#include "net/url_request/url_fetcher.h"
+#include "net/url_request/url_fetcher_delegate.h"
#include "net/url_request/url_request_context.h"
#include "net/url_request/url_request_context_getter.h"
@@ -195,13 +197,13 @@
class FinancialPingUrlFetcherDelegate : public content::URLFetcherDelegate {
public:
FinancialPingUrlFetcherDelegate(MessageLoop* loop) : loop_(loop) { }
- virtual void OnURLFetchComplete(const content::URLFetcher* source);
+ virtual void OnURLFetchComplete(const net::URLFetcher* source);
private:
MessageLoop* loop_;
};
void FinancialPingUrlFetcherDelegate::OnURLFetchComplete(
- const content::URLFetcher* source) {
+ const net::URLFetcher* source) {
loop_->Quit();
}
@@ -274,8 +276,8 @@
kFinancialServer, kFinancialPort,
request);
- scoped_ptr<content::URLFetcher> fetcher(content::URLFetcher::Create(
- GURL(url), content::URLFetcher::GET, &delegate));
+ scoped_ptr<net::URLFetcher> fetcher(content::URLFetcher::Create(
+ GURL(url), net::URLFetcher::GET, &delegate));
fetcher->SetLoadFlags(net::LOAD_DISABLE_CACHE |
net::LOAD_DO_NOT_SEND_AUTH_DATA |
@@ -291,7 +293,7 @@
const base::TimeDelta kTimeout = base::TimeDelta::FromMinutes(5);
loop.PostTask(
FROM_HERE,
- base::Bind(&content::URLFetcher::Start, base::Unretained(fetcher.get())));
+ base::Bind(&net::URLFetcher::Start, base::Unretained(fetcher.get())));
loop.PostNonNestableDelayedTask(
FROM_HERE, MessageLoop::QuitClosure(), kTimeout);