diff --git a/brightray/browser/browser_main_parts.cc b/brightray/browser/browser_main_parts.cc index 15a7192d0093..8bcaf3621b11 100644 --- a/brightray/browser/browser_main_parts.cc +++ b/brightray/browser/browser_main_parts.cc @@ -7,8 +7,6 @@ #include "browser/browser_context.h" #include "browser/web_ui_controller_factory.h" -#include "net/socket/tcp_listen_socket.h" - namespace brightray { BrowserMainParts::BrowserMainParts() { diff --git a/brightray/browser/devtools_ui.cc b/brightray/browser/devtools_ui.cc index 571dc8adb626..94e581728ab8 100644 --- a/brightray/browser/devtools_ui.cc +++ b/brightray/browser/devtools_ui.cc @@ -93,10 +93,9 @@ class BundledDataSource : public content::URLDataSource { } DevToolsUI::DevToolsUI(BrowserContext* browser_context, content::WebUI* web_ui) - : WebUIController(web_ui), - browser_context_(browser_context) { + : WebUIController(web_ui) { web_ui->SetBindings(0); - content::URLDataSource::Add(browser_context_, new BundledDataSource()); + content::URLDataSource::Add(browser_context, new BundledDataSource()); } } diff --git a/brightray/browser/devtools_ui.h b/brightray/browser/devtools_ui.h index 6ac205ab5488..70ab0f2686da 100644 --- a/brightray/browser/devtools_ui.h +++ b/brightray/browser/devtools_ui.h @@ -17,9 +17,6 @@ class DevToolsUI : public content::WebUIController { explicit DevToolsUI(BrowserContext* browser_context, content::WebUI* web_ui); private: - // Weak reference to the browser context. - BrowserContext* browser_context_; - DISALLOW_COPY_AND_ASSIGN(DevToolsUI); }; diff --git a/brightray/browser/inspectable_web_contents_impl.cc b/brightray/browser/inspectable_web_contents_impl.cc index 48da9f1fb005..08d820d46311 100644 --- a/brightray/browser/inspectable_web_contents_impl.cc +++ b/brightray/browser/inspectable_web_contents_impl.cc @@ -28,10 +28,6 @@ namespace { const char kChromeUIDevToolsURL[] = "chrome-devtools://devtools/devtools.html"; const char kDockSidePref[] = "brightray.devtools.dockside"; -GURL GetDevToolsURL() { - return GURL(kChromeUIDevToolsURL); -} - } // Implemented separately on each platform. @@ -76,7 +72,8 @@ void InspectableWebContentsImpl::ShowDevTools() { frontend_host_.reset(content::DevToolsClientHost::CreateDevToolsFrontendHost(devtools_web_contents_.get(), this)); content::DevToolsManager::GetInstance()->RegisterDevToolsClientHostFor(agent_host_, frontend_host_.get()); - devtools_web_contents_->GetController().LoadURL(GetDevToolsURL(), content::Referrer(), content::PAGE_TRANSITION_AUTO_TOPLEVEL, std::string()); + GURL devtools_url(kChromeUIDevToolsURL); + devtools_web_contents_->GetController().LoadURL(devtools_url, content::Referrer(), content::PAGE_TRANSITION_AUTO_TOPLEVEL, std::string()); } view_->SetDockSide(dock_side_); @@ -145,9 +142,6 @@ void InspectableWebContentsImpl::SearchInPath(int request_id, const std::string& void InspectableWebContentsImpl::InspectedContentsClosing() { } -void InspectableWebContentsImpl::RenderViewCreated(content::RenderViewHost* render_view_host) { -} - void InspectableWebContentsImpl::AboutToNavigateRenderView(content::RenderViewHost* render_view_host) { content::DevToolsClientHost::SetupDevToolsFrontendClient(web_contents()->GetRenderViewHost()); } diff --git a/brightray/browser/inspectable_web_contents_impl.h b/brightray/browser/inspectable_web_contents_impl.h index c47eb871cd6e..f81ccc0185a6 100644 --- a/brightray/browser/inspectable_web_contents_impl.h +++ b/brightray/browser/inspectable_web_contents_impl.h @@ -69,7 +69,6 @@ private: // content::WebContentsObserver - virtual void RenderViewCreated(content::RenderViewHost*) OVERRIDE; virtual void AboutToNavigateRenderView(content::RenderViewHost* render_view_host) OVERRIDE; virtual void DidFinishLoad(int64 frame_id, const GURL& validated_url,