Manage the life of BrowserContext in Session

This commit is contained in:
Cheng Zhao 2015-09-05 22:39:48 +08:00
parent fafb28e41a
commit 0b1a3f3ef3
5 changed files with 44 additions and 29 deletions

View file

@ -168,9 +168,9 @@ void AtomBrowserContext::RegisterPrefs(PrefRegistrySimple* pref_registry) {
namespace brightray {
// static
BrowserContext* BrowserContext::Create(const std::string& partition,
bool in_memory) {
return new atom::AtomBrowserContext(partition, in_memory);
scoped_refptr<BrowserContext> BrowserContext::Create(
const std::string& partition, bool in_memory) {
return make_scoped_refptr(new atom::AtomBrowserContext(partition, in_memory));
}
} // namespace brightray