Remember where the dev tools were docked between launches

This commit is contained in:
Adam Roben 2013-04-08 13:53:53 -04:00
parent a2a2cd1936
commit 3c513d6ae8
5 changed files with 62 additions and 4 deletions

View file

@ -4,6 +4,7 @@
#include "browser_context.h"
#include "browser/inspectable_web_contents_impl.h"
#include "common/application_info.h"
#include "base/files/file_path.h"
@ -46,6 +47,7 @@ BrowserContext::BrowserContext() : resource_context_(new ResourceContext) {
JsonPrefStore::GetTaskRunnerForFile(prefs_path, content::BrowserThread::GetBlockingPool()));
auto registry = make_scoped_refptr(new PrefRegistrySimple);
RegisterInternalPrefs(registry);
RegisterPrefs(registry);
prefs_.reset(builder.Create(registry));
@ -54,6 +56,10 @@ BrowserContext::BrowserContext() : resource_context_(new ResourceContext) {
BrowserContext::~BrowserContext() {
}
void BrowserContext::RegisterInternalPrefs(PrefRegistrySimple* registry) {
InspectableWebContentsImpl::RegisterPrefs(registry);
}
net::URLRequestContextGetter* BrowserContext::CreateRequestContext(content::ProtocolHandlerMap* protocol_handlers) {
DCHECK(!url_request_getter_);
url_request_getter_ = new URLRequestContextGetter(