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

Unified Diff: content/public/common/content_client.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
« no previous file with comments | « content/public/common/content_client.h ('k') | content/public/common/content_switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/public/common/content_client.cc
===================================================================
--- content/public/common/content_client.cc (revision 255867)
+++ content/public/common/content_client.cc (working copy)
@@ -7,7 +7,6 @@
#include "base/logging.h"
#include "base/strings/string_piece.h"
#include "ui/gfx/image/image.h"
-#include "webkit/common/user_agent/user_agent.h"
namespace content {
@@ -37,11 +36,10 @@
void SetContentClient(ContentClient* client) {
g_client = client;
- // Set the default user agent as provided by the client. We need to make
- // sure this is done before webkit_glue::GetUserAgent() is called (so that
- // the UA doesn't change).
+ // TODO(jam): find out which static on Windows is causing this to have to be
+ // called on startup.
if (client)
- webkit_glue::SetUserAgent(client->GetUserAgent());
+ client->GetUserAgent();
}
ContentClient* GetContentClient() {
@@ -60,11 +58,6 @@
return InternalTestInitializer::SetUtility(u);
}
-const std::string& GetUserAgent(const GURL& url) {
- DCHECK(g_client);
- return webkit_glue::GetUserAgent(url);
-}
-
ContentClient::ContentClient()
: browser_(NULL), plugin_(NULL), renderer_(NULL), utility_(NULL) {
}
« no previous file with comments | « content/public/common/content_client.h ('k') | content/public/common/content_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698