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

Unified Diff: content/shell/browser/shell_devtools_frontend.cc

Issue 31043002: Make content shell activate and focus dev tools on show. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « content/shell/browser/shell_devtools_frontend.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/shell/browser/shell_devtools_frontend.cc
diff --git a/content/shell/browser/shell_devtools_frontend.cc b/content/shell/browser/shell_devtools_frontend.cc
index 3c25aa1db20019bb25bf4c699dcdd547cc350c60..aa6afe1aee0829d4adf212ad28fdf88310c8c251 100644
--- a/content/shell/browser/shell_devtools_frontend.cc
+++ b/content/shell/browser/shell_devtools_frontend.cc
@@ -63,9 +63,16 @@ ShellDevToolsFrontend* ShellDevToolsFrontend::Show(
else
shell->LoadURL(delegate->devtools_http_handler()->GetFrontendURL());
+ devtools_frontend->Activate();
+ devtools_frontend->Focus();
+
return devtools_frontend;
}
+void ShellDevToolsFrontend::Activate() {
+ frontend_shell_->ActivateContents(web_contents());
+}
+
void ShellDevToolsFrontend::Focus() {
web_contents()->GetView()->Focus();
}
« no previous file with comments | « content/shell/browser/shell_devtools_frontend.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698