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

Side by Side Diff: chrome/browser/profiles/off_the_record_profile_io_data.cc

Issue 10969017: Create a new URLRequestJobFactory for isolated request contexts. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "chrome/browser/profiles/off_the_record_profile_io_data.h" 5 #include "chrome/browser/profiles/off_the_record_profile_io_data.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 // Use a separate in-memory cookie store for the app. 290 // Use a separate in-memory cookie store for the app.
291 // TODO(creis): We should have a cookie delegate for notifying the cookie 291 // TODO(creis): We should have a cookie delegate for notifying the cookie
292 // extensions API, but we need to update it to understand isolated apps first. 292 // extensions API, but we need to update it to understand isolated apps first.
293 context->SetCookieStore(new net::CookieMonster(NULL, NULL)); 293 context->SetCookieStore(new net::CookieMonster(NULL, NULL));
294 294
295 // Use a separate in-memory cache for the app. 295 // Use a separate in-memory cache for the app.
296 net::HttpCache::BackendFactory* app_backend = 296 net::HttpCache::BackendFactory* app_backend =
297 net::HttpCache::DefaultBackend::InMemory(0); 297 net::HttpCache::DefaultBackend::InMemory(0);
298 net::HttpNetworkSession* main_network_session = 298 net::HttpNetworkSession* main_network_session =
299 main_http_factory_->GetSession(); 299 main_http_factory_->GetSession();
300 net::HttpCache* app_http_cache = 300 scoped_ptr<net::HttpTransactionFactory> app_http_cache(
301 new net::HttpCache(main_network_session, app_backend); 301 new net::HttpCache(main_network_session, app_backend));
302 302
303 context->SetHttpTransactionFactory(app_http_cache); 303 context->SetHttpTransactionFactory(app_http_cache.Pass());
304 return context; 304 return context;
305 } 305 }
306 306
307 ChromeURLRequestContext* 307 ChromeURLRequestContext*
308 OffTheRecordProfileIOData::InitializeMediaRequestContext( 308 OffTheRecordProfileIOData::InitializeMediaRequestContext(
309 ChromeURLRequestContext* original_context, 309 ChromeURLRequestContext* original_context,
310 const std::string& app_id) const { 310 const std::string& app_id) const {
311 NOTREACHED(); 311 NOTREACHED();
312 return NULL; 312 return NULL;
313 } 313 }
(...skipping 30 matching lines...) Expand all
344 job_factory->SetProtocolHandler( 344 job_factory->SetProtocolHandler(
345 chrome::kFtpScheme, 345 chrome::kFtpScheme,
346 new net::FtpProtocolHandler(ftp_factory_.get(), ftp_auth_cache)); 346 new net::FtpProtocolHandler(ftp_factory_.get(), ftp_auth_cache));
347 #endif // !defined(DISABLE_FTP_SUPPORT) 347 #endif // !defined(DISABLE_FTP_SUPPORT)
348 } 348 }
349 349
350 chrome_browser_net::LoadTimeStats* OffTheRecordProfileIOData::GetLoadTimeStats( 350 chrome_browser_net::LoadTimeStats* OffTheRecordProfileIOData::GetLoadTimeStats(
351 IOThread::Globals* io_thread_globals) const { 351 IOThread::Globals* io_thread_globals) const {
352 return NULL; 352 return NULL;
353 } 353 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698