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

Side by Side Diff: content/shell/browser/shell_devtools_frontend.cc

Issue 257153003: We have a problem in the process on destroying WebContentsImpl because (Closed) Base URL: https://git.chromium.org/chromium/src.git@master
Patch Set: Rebased onto origin/lkgr Created 6 years, 7 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
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 "content/shell/browser/shell_devtools_frontend.h" 5 #include "content/shell/browser/shell_devtools_frontend.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/strings/stringprintf.h" 9 #include "base/strings/stringprintf.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
120 DevToolsManager* manager = DevToolsManager::GetInstance(); 120 DevToolsManager* manager = DevToolsManager::GetInstance();
121 manager->RegisterDevToolsClientHostFor(agent_host_.get(), 121 manager->RegisterDevToolsClientHostFor(agent_host_.get(),
122 frontend_host_.get()); 122 frontend_host_.get());
123 } 123 }
124 124
125 void ShellDevToolsFrontend::DocumentOnLoadCompletedInMainFrame(int32 page_id) { 125 void ShellDevToolsFrontend::DocumentOnLoadCompletedInMainFrame(int32 page_id) {
126 web_contents()->GetMainFrame()->ExecuteJavaScript( 126 web_contents()->GetMainFrame()->ExecuteJavaScript(
127 base::ASCIIToUTF16("InspectorFrontendAPI.setUseSoftMenu(true);")); 127 base::ASCIIToUTF16("InspectorFrontendAPI.setUseSoftMenu(true);"));
128 } 128 }
129 129
130 void ShellDevToolsFrontend::WebContentsDestroyed(WebContents* web_contents) { 130 void ShellDevToolsFrontend::WebContentsDestroyed() {
131 DevToolsManager::GetInstance()->ClientHostClosing(frontend_host_.get()); 131 DevToolsManager::GetInstance()->ClientHostClosing(frontend_host_.get());
132 delete this; 132 delete this;
133 } 133 }
134 134
135 void ShellDevToolsFrontend::InspectedContentsClosing() { 135 void ShellDevToolsFrontend::InspectedContentsClosing() {
136 frontend_shell_->Close(); 136 frontend_shell_->Close();
137 } 137 }
138 138
139 } // namespace content 139 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698