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

Unified Diff: chrome/browser/ui/webui/options/content_settings_handler.cc

Issue 7310003: Disable chrome://options UI elements if the corresponding preference is not user-modifiable. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: review Created 9 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: chrome/browser/ui/webui/options/content_settings_handler.cc
diff --git a/chrome/browser/ui/webui/options/content_settings_handler.cc b/chrome/browser/ui/webui/options/content_settings_handler.cc
index 9047d9735ae4880a8893d23253cb5bc16901efc5..84fcc19fbb5c32159b47903be06862c534b9704d 100644
--- a/chrome/browser/ui/webui/options/content_settings_handler.cc
+++ b/chrome/browser/ui/webui/options/content_settings_handler.cc
@@ -267,11 +267,6 @@ void ContentSettingsHandler::GetLocalizedValues(
void ContentSettingsHandler::Initialize() {
const HostContentSettingsMap* settings_map = GetContentSettingsMap();
- scoped_ptr<Value> block_3rd_party(Value::CreateBooleanValue(
- settings_map->BlockThirdPartyCookies()));
- web_ui_->CallJavascriptFunction("ContentSettings.setBlockThirdPartyCookies",
- *block_3rd_party.get());
-
notification_registrar_.Add(
this, NotificationType::OTR_PROFILE_CREATED,
NotificationService::AllSources());
@@ -569,9 +564,6 @@ void ContentSettingsHandler::RegisterMessages() {
web_ui_->RegisterMessageCallback("setContentFilter",
NewCallback(this,
&ContentSettingsHandler::SetContentFilter));
- web_ui_->RegisterMessageCallback("setAllowThirdPartyCookies",
- NewCallback(this,
- &ContentSettingsHandler::SetAllowThirdPartyCookies));
web_ui_->RegisterMessageCallback("removeException",
NewCallback(this,
&ContentSettingsHandler::RemoveException));
@@ -606,13 +598,6 @@ void ContentSettingsHandler::SetContentFilter(const ListValue* args) {
}
}
-void ContentSettingsHandler::SetAllowThirdPartyCookies(const ListValue* args) {
- string16 allow = ExtractStringValue(args);
-
- GetContentSettingsMap()->SetBlockThirdPartyCookies(
- LowerCaseEqualsASCII(allow, "true"));
-}
-
void ContentSettingsHandler::RemoveException(const ListValue* args) {
size_t arg_i = 0;
std::string type_string;
« no previous file with comments | « chrome/browser/ui/webui/options/content_settings_handler.h ('k') | chrome/browser/ui/webui/options/core_options_handler.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698