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

Side by Side Diff: webkit/appcache/appcache_interceptor.cc

Issue 7397008: Deprecate RegisterProtocolFactory/(Un)RegisterInterceptor. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix indent. Created 9 years, 5 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "webkit/appcache/appcache_interceptor.h" 5 #include "webkit/appcache/appcache_interceptor.h"
6 6
7 #include "webkit/appcache/appcache_backend_impl.h" 7 #include "webkit/appcache/appcache_backend_impl.h"
8 #include "webkit/appcache/appcache_host.h" 8 #include "webkit/appcache/appcache_host.h"
9 #include "webkit/appcache/appcache_interfaces.h" 9 #include "webkit/appcache/appcache_interfaces.h"
10 #include "webkit/appcache/appcache_request_handler.h" 10 #include "webkit/appcache/appcache_request_handler.h"
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
56 int64* cache_id, 56 int64* cache_id,
57 GURL* manifest_url) { 57 GURL* manifest_url) {
58 DCHECK(*cache_id == kNoCacheId); 58 DCHECK(*cache_id == kNoCacheId);
59 DCHECK(manifest_url->is_empty()); 59 DCHECK(manifest_url->is_empty());
60 AppCacheRequestHandler* handler = GetHandler(request); 60 AppCacheRequestHandler* handler = GetHandler(request);
61 if (handler) 61 if (handler)
62 handler->GetExtraResponseInfo(cache_id, manifest_url); 62 handler->GetExtraResponseInfo(cache_id, manifest_url);
63 } 63 }
64 64
65 AppCacheInterceptor::AppCacheInterceptor() { 65 AppCacheInterceptor::AppCacheInterceptor() {
66 net::URLRequest::RegisterRequestInterceptor(this); 66 net::URLRequest::Deprecated::RegisterRequestInterceptor(this);
67 } 67 }
68 68
69 AppCacheInterceptor::~AppCacheInterceptor() { 69 AppCacheInterceptor::~AppCacheInterceptor() {
70 net::URLRequest::UnregisterRequestInterceptor(this); 70 net::URLRequest::Deprecated::UnregisterRequestInterceptor(this);
71 } 71 }
72 72
73 net::URLRequestJob* AppCacheInterceptor::MaybeIntercept( 73 net::URLRequestJob* AppCacheInterceptor::MaybeIntercept(
74 net::URLRequest* request) { 74 net::URLRequest* request) {
75 AppCacheRequestHandler* handler = GetHandler(request); 75 AppCacheRequestHandler* handler = GetHandler(request);
76 if (!handler) 76 if (!handler)
77 return NULL; 77 return NULL;
78 return handler->MaybeLoadResource(request); 78 return handler->MaybeLoadResource(request);
79 } 79 }
80 80
81 net::URLRequestJob* AppCacheInterceptor::MaybeInterceptRedirect( 81 net::URLRequestJob* AppCacheInterceptor::MaybeInterceptRedirect(
82 net::URLRequest* request, 82 net::URLRequest* request,
83 const GURL& location) { 83 const GURL& location) {
84 AppCacheRequestHandler* handler = GetHandler(request); 84 AppCacheRequestHandler* handler = GetHandler(request);
85 if (!handler) 85 if (!handler)
86 return NULL; 86 return NULL;
87 return handler->MaybeLoadFallbackForRedirect(request, location); 87 return handler->MaybeLoadFallbackForRedirect(request, location);
88 } 88 }
89 89
90 net::URLRequestJob* AppCacheInterceptor::MaybeInterceptResponse( 90 net::URLRequestJob* AppCacheInterceptor::MaybeInterceptResponse(
91 net::URLRequest* request) { 91 net::URLRequest* request) {
92 AppCacheRequestHandler* handler = GetHandler(request); 92 AppCacheRequestHandler* handler = GetHandler(request);
93 if (!handler) 93 if (!handler)
94 return NULL; 94 return NULL;
95 return handler->MaybeLoadFallbackForResponse(request); 95 return handler->MaybeLoadFallbackForResponse(request);
96 } 96 }
97 97
98 } // namespace appcache 98 } // namespace appcache
OLDNEW
« no previous file with comments | « net/url_request/url_request_unittest.cc ('k') | webkit/appcache/appcache_request_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698