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

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

Issue 6201005: Initial support for partitioning cookies for isolated apps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Refactor to use ContentBrowserClient. Created 9 years, 9 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/profile_io_data.h" 5 #include "chrome/browser/profiles/profile_io_data.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after
222 222
223 scoped_refptr<ChromeURLRequestContext> 223 scoped_refptr<ChromeURLRequestContext>
224 ProfileIOData::GetExtensionsRequestContext() const { 224 ProfileIOData::GetExtensionsRequestContext() const {
225 LazyInitialize(); 225 LazyInitialize();
226 scoped_refptr<ChromeURLRequestContext> context = 226 scoped_refptr<ChromeURLRequestContext> context =
227 AcquireExtensionsRequestContext(); 227 AcquireExtensionsRequestContext();
228 DCHECK(context); 228 DCHECK(context);
229 return context; 229 return context;
230 } 230 }
231 231
232 scoped_refptr<ChromeURLRequestContext>
233 ProfileIOData::GetIsolatedAppRequestContext(
234 scoped_refptr<ChromeURLRequestContext> main_context,
235 std::string app_id) const {
236 //const Extension* installed_app) const {
Matt Perry 2011/03/15 00:40:56 remove dead code
Charlie Reis 2011/03/15 06:23:42 Nice catch-- sorry about that.
237 LazyInitialize();
238 scoped_refptr<ChromeURLRequestContext> context =
239 AcquireIsolatedAppRequestContext(main_context, app_id /*installed_app*/);
240 DCHECK(context);
241 return context;
242 }
243
232 void ProfileIOData::LazyInitialize() const { 244 void ProfileIOData::LazyInitialize() const {
233 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO)); 245 DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
234 if (initialized_) 246 if (initialized_)
235 return; 247 return;
236 LazyInitializeInternal(); 248 LazyInitializeInternal();
237 initialized_ = true; 249 initialized_ = true;
238 } 250 }
239 251
240 // static 252 // static
241 void ProfileIOData::ApplyProfileParamsToContext( 253 void ProfileIOData::ApplyProfileParamsToContext(
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after
337 349
338 #if defined(OS_CHROMEOS) 350 #if defined(OS_CHROMEOS)
339 if (chromeos::CrosLibrary::Get()->EnsureLoaded()) { 351 if (chromeos::CrosLibrary::Get()->EnsureLoaded()) {
340 chromeos::CrosLibrary::Get()->GetLibCrosServiceLibrary()-> 352 chromeos::CrosLibrary::Get()->GetLibCrosServiceLibrary()->
341 RegisterNetworkProxyHandler(proxy_service); 353 RegisterNetworkProxyHandler(proxy_service);
342 } 354 }
343 #endif // defined(OS_CHROMEOS) 355 #endif // defined(OS_CHROMEOS)
344 356
345 return proxy_service; 357 return proxy_service;
346 } 358 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698