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

Unified Diff: content/app/content_main_runner.cc

Issue 191093002: Simplify the user agent code some more since after r255534 it's not affected by the site's URL. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: patchset 15 which works Created 6 years, 9 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/app/content_main_runner.cc
===================================================================
--- content/app/content_main_runner.cc (revision 255867)
+++ content/app/content_main_runner.cc (working copy)
@@ -51,7 +51,6 @@
#include "ui/base/ui_base_paths.h"
#include "ui/base/ui_base_switches.h"
#include "ui/gfx/win/dpi.h"
-#include "webkit/common/user_agent/user_agent.h"
#if defined(USE_TCMALLOC)
#include "third_party/tcmalloc/chromium/src/gperftools/malloc_extension.h"
@@ -380,14 +379,6 @@
command_line.GetSwitchValueASCII(switches::kProcessType);
ContentClientInitializer::Set(process_type, delegate);
- // If a custom user agent was passed on the command line, we need
- // to (re)set it now, rather than using the default one the zygote
- // initialized.
- if (command_line.HasSwitch(switches::kUserAgent)) {
- webkit_glue::SetUserAgent(
- command_line.GetSwitchValueASCII(switches::kUserAgent));
- }
-
// The StatsTable must be initialized in each process; we already
// initialized for the browser process, now we need to initialize
// within the new processes as well.
@@ -747,14 +738,6 @@
if (delegate_)
delegate_->PreSandboxStartup();
- // Set any custom user agent passed on the command line now so the string
- // doesn't change between calls to webkit_glue::GetUserAgent(), otherwise it
- // defaults to the user agent set during SetContentClient().
- if (command_line.HasSwitch(switches::kUserAgent)) {
- webkit_glue::SetUserAgent(
- command_line.GetSwitchValueASCII(switches::kUserAgent));
- }
-
if (!process_type.empty())
CommonSubprocessInit(process_type);
« no previous file with comments | « components/autofill/content/browser/risk/fingerprint.cc ('k') | content/browser/devtools/devtools_http_handler_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698