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

Unified Diff: content/child/blink_platform_impl.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: 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/child/blink_platform_impl.cc
===================================================================
--- content/child/blink_platform_impl.cc (revision 255624)
+++ content/child/blink_platform_impl.cc (working copy)
@@ -28,6 +28,7 @@
#include "base/time/time.h"
#include "content/child/web_socket_stream_handle_impl.h"
#include "content/child/web_url_loader_impl.h"
+#include "content/public/common/content_client.h"
#include "grit/blink_resources.h"
#include "grit/webkit_resources.h"
#include "grit/webkit_strings.h"
@@ -38,7 +39,6 @@
#include "third_party/WebKit/public/platform/WebString.h"
#include "ui/base/layout.h"
#include "webkit/child/webkit_child_helpers.h"
-#include "webkit/common/user_agent/user_agent.h"
#if defined(OS_ANDROID)
#include "base/android/sys_utils.h"
@@ -362,8 +362,12 @@
return new WebSocketStreamHandleImpl(this);
}
+WebString BlinkPlatformImpl::userAgent() {
+ return WebString::fromUTF8(GetContentClient()->GetUserAgent());
tfarina 2014/03/07 22:06:07 Ah, OK. That is what you were trying to say when
+}
+
WebString BlinkPlatformImpl::userAgent(const WebURL& url) {
- return WebString::fromUTF8(webkit_glue::GetUserAgent(url));
+ return userAgent();
}
WebData BlinkPlatformImpl::parseDataURL(

Powered by Google App Engine
This is Rietveld 408576698