summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/browser/tab_contents/render_view_host_delegate_helper.cc2
-rw-r--r--chrome/common/chrome_switches.cc3
-rw-r--r--chrome/common/chrome_switches.h1
-rw-r--r--chrome/common/render_messages.cc2
-rw-r--r--webkit/glue/webpreferences.h2
5 files changed, 9 insertions, 1 deletions
diff --git a/chrome/browser/tab_contents/render_view_host_delegate_helper.cc b/chrome/browser/tab_contents/render_view_host_delegate_helper.cc
index 7a7f2d6..ed52587 100644
--- a/chrome/browser/tab_contents/render_view_host_delegate_helper.cc
+++ b/chrome/browser/tab_contents/render_view_host_delegate_helper.cc
@@ -289,6 +289,8 @@ WebPreferences RenderViewHostDelegateHelper::GetWebkitPrefs(
command_line.HasSwitch(switches::kEnableAccelerated2dCanvas);
web_prefs.memory_info_enabled =
command_line.HasSwitch(switches::kEnableMemoryInfo);
+ web_prefs.hyperlink_auditing_enabled =
+ !command_line.HasSwitch(switches::kNoPings);
// The user stylesheet watcher may not exist in a testing profile.
if (profile->GetUserStyleSheetWatcher()) {
web_prefs.user_style_sheet_enabled = true;
diff --git a/chrome/common/chrome_switches.cc b/chrome/common/chrome_switches.cc
index 244f3be..d6ff1d6 100644
--- a/chrome/common/chrome_switches.cc
+++ b/chrome/common/chrome_switches.cc
@@ -767,6 +767,9 @@ const char kNoJsRandomness[] = "no-js-randomness";
// Don't send HTTP-Referer headers.
const char kNoReferrers[] = "no-referrers";
+// Don't send hyperlink auditing pings
+const char kNoPings[] = "no-pings";
+
// Don't use a proxy server, always make direct connections. Overrides any
// other proxy server flags that are passed.
const char kNoProxyServer[] = "no-proxy-server";
diff --git a/chrome/common/chrome_switches.h b/chrome/common/chrome_switches.h
index 82c580d..75aefc5 100644
--- a/chrome/common/chrome_switches.h
+++ b/chrome/common/chrome_switches.h
@@ -223,6 +223,7 @@ extern const char kNoFirstRun[];
extern const char kNoJsRandomness[];
extern const char kNoProxyServer[];
extern const char kNoReferrers[];
+extern const char kNoPings[];
extern const char kNoSandbox[];
extern const char kNoStartupWindow[];
extern const char kNotifyCloudPrintTokenExpired[];
diff --git a/chrome/common/render_messages.cc b/chrome/common/render_messages.cc
index c7975ce..ff80db6 100644
--- a/chrome/common/render_messages.cc
+++ b/chrome/common/render_messages.cc
@@ -479,6 +479,7 @@ void ParamTraits<WebPreferences>::Write(Message* m, const param_type& p) {
WriteParam(m, p.databases_enabled);
WriteParam(m, p.application_cache_enabled);
WriteParam(m, p.tabs_to_links);
+ WriteParam(m, p.hyperlink_auditing_enabled);
WriteParam(m, p.user_style_sheet_enabled);
WriteParam(m, p.user_style_sheet_location);
WriteParam(m, p.author_and_user_styles_enabled);
@@ -527,6 +528,7 @@ bool ParamTraits<WebPreferences>::Read(const Message* m, void** iter,
ReadParam(m, iter, &p->databases_enabled) &&
ReadParam(m, iter, &p->application_cache_enabled) &&
ReadParam(m, iter, &p->tabs_to_links) &&
+ ReadParam(m, iter, &p->hyperlink_auditing_enabled) &&
ReadParam(m, iter, &p->user_style_sheet_enabled) &&
ReadParam(m, iter, &p->user_style_sheet_location) &&
ReadParam(m, iter, &p->author_and_user_styles_enabled) &&
diff --git a/webkit/glue/webpreferences.h b/webkit/glue/webpreferences.h
index bc6d477..c9c8d8d 100644
--- a/webkit/glue/webpreferences.h
+++ b/webkit/glue/webpreferences.h
@@ -106,7 +106,7 @@ struct WebPreferences {
application_cache_enabled(false),
tabs_to_links(true),
caret_browsing_enabled(false),
- hyperlink_auditing_enabled(false),
+ hyperlink_auditing_enabled(true),
user_style_sheet_enabled(false),
author_and_user_styles_enabled(true),
allow_universal_access_from_file_urls(false),