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

Unified Diff: content/shell/browser/layout_test/layout_test_devtools_frontend.cc

Issue 2177983004: [DevTools] Do not use "settings" query param. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cleanup Created 4 years, 5 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
Index: content/shell/browser/layout_test/layout_test_devtools_frontend.cc
diff --git a/content/shell/browser/layout_test/layout_test_devtools_frontend.cc b/content/shell/browser/layout_test/layout_test_devtools_frontend.cc
index 7e5d0066389719061ea6bafacd6378bad36f87bf..daf127b66f10095607d6abc3c6335425f64842a7 100644
--- a/content/shell/browser/layout_test/layout_test_devtools_frontend.cc
+++ b/content/shell/browser/layout_test/layout_test_devtools_frontend.cc
@@ -30,15 +30,13 @@ LayoutTestDevToolsFrontend* LayoutTestDevToolsFrontend::Show(
gfx::Size());
LayoutTestDevToolsFrontend* devtools_frontend =
new LayoutTestDevToolsFrontend(shell, inspected_contents);
-
- shell->LoadURL(GetDevToolsPathAsURL(settings, frontend_url));
-
+ devtools_frontend->SetPreferences(settings);
+ shell->LoadURL(GetDevToolsPathAsURL(frontend_url));
return devtools_frontend;
}
// static.
GURL LayoutTestDevToolsFrontend::GetDevToolsPathAsURL(
- const std::string& settings,
const std::string& frontend_url) {
if (!frontend_url.empty())
return GURL(frontend_url);
@@ -62,18 +60,16 @@ GURL LayoutTestDevToolsFrontend::GetDevToolsPathAsURL(
#if defined(DEBUG_DEVTOOLS)
url_string += "&debugFrontend=true";
#endif // defined(DEBUG_DEVTOOLS)
- if (!settings.empty())
- url_string += "&settings=" + settings;
return GURL(url_string);
}
void LayoutTestDevToolsFrontend::ReuseFrontend(const std::string& settings,
const std::string frontend_url) {
DisconnectFromTarget();
- preferences()->Clear();
+ SetPreferences(settings);
ready_for_test_ = false;
pending_evaluations_.clear();
- frontend_shell()->LoadURL(GetDevToolsPathAsURL(settings, frontend_url));
+ frontend_shell()->LoadURL(GetDevToolsPathAsURL(frontend_url));
}
void LayoutTestDevToolsFrontend::EvaluateInFrontend(
« no previous file with comments | « content/shell/browser/layout_test/layout_test_devtools_frontend.h ('k') | content/shell/browser/shell_devtools_frontend.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698