Chromium Code Reviews| Index: chrome/browser/ui/webui/devtools_bridge_ui.cc |
| diff --git a/chrome/browser/ui/webui/devtools_bridge_ui.cc b/chrome/browser/ui/webui/devtools_bridge_ui.cc |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..d854c25a57e2dd07422eb82bea580e26ebd4e0c7 |
| --- /dev/null |
| +++ b/chrome/browser/ui/webui/devtools_bridge_ui.cc |
| @@ -0,0 +1,26 @@ |
| +// Copyright 2014 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#include "chrome/browser/ui/webui/devtools_bridge_ui.h" |
| + |
| +#include "chrome/browser/devtools/device/cloud/devtools_bridge_client.h" |
| +#include "chrome/browser/profiles/profile.h" |
| +#include "chrome/common/url_constants.h" |
| +#include "content/public/browser/web_ui_data_source.h" |
| + |
| +DevToolsBridgeUI::DevToolsBridgeUI(content::WebUI* web_ui) |
| + : content::WebUIController(web_ui) { |
| + Profile* profile = Profile::FromWebUI(web_ui); |
| + |
| + content::WebUIDataSource* source = content::WebUIDataSource::Create( |
| + chrome::kChromeUIDevToolsBridgeClientHost); |
| + source->DisableContentSecurityPolicy(); |
|
dgozman
2014/11/26 11:33:25
I think we could do without this.
|
| + |
| + DevToolsBridgeClient::AddResources(source); |
|
pfeldman
2014/11/26 11:56:42
Merge these all.
|
| + |
| + content::WebUIDataSource::Add(profile, source); |
| +} |
| + |
| +DevToolsBridgeUI::~DevToolsBridgeUI() { |
| +} |