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

Side by Side Diff: chrome/browser/ui/prefs/prefs_tab_helper.cc

Issue 10985083: Upstreaming SpdyProxy-related switches, OTR logic, and histograms (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Alphabetized includes Created 8 years, 2 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/prefs/prefs_tab_helper.h" 5 #include "chrome/browser/ui/prefs/prefs_tab_helper.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "base/stringprintf.h" 10 #include "base/stringprintf.h"
(...skipping 371 matching lines...) Expand 10 before | Expand all | Expand 10 after
382 PrefsTabHelper::~PrefsTabHelper() { 382 PrefsTabHelper::~PrefsTabHelper() {
383 } 383 }
384 384
385 // static 385 // static
386 void PrefsTabHelper::InitIncognitoUserPrefStore( 386 void PrefsTabHelper::InitIncognitoUserPrefStore(
387 OverlayUserPrefStore* pref_store) { 387 OverlayUserPrefStore* pref_store) {
388 // List of keys that cannot be changed in the user prefs file by the incognito 388 // List of keys that cannot be changed in the user prefs file by the incognito
389 // profile. All preferences that store information about the browsing history 389 // profile. All preferences that store information about the browsing history
390 // or behavior of the user should have this property. 390 // or behavior of the user should have this property.
391 pref_store->RegisterOverlayPref(prefs::kBrowserWindowPlacement); 391 pref_store->RegisterOverlayPref(prefs::kBrowserWindowPlacement);
392 #if defined(OS_ANDROID)
393 pref_store->RegisterOverlayPref(prefs::kProxy);
394 #endif
392 } 395 }
393 396
394 // static 397 // static
395 void PrefsTabHelper::RegisterUserPrefs(PrefService* prefs) { 398 void PrefsTabHelper::RegisterUserPrefs(PrefService* prefs) {
396 WebPreferences pref_defaults; 399 WebPreferences pref_defaults;
397 prefs->RegisterBooleanPref(prefs::kWebKitJavascriptEnabled, 400 prefs->RegisterBooleanPref(prefs::kWebKitJavascriptEnabled,
398 pref_defaults.javascript_enabled, 401 pref_defaults.javascript_enabled,
399 PrefService::UNSYNCABLE_PREF); 402 PrefService::UNSYNCABLE_PREF);
400 prefs->RegisterBooleanPref(prefs::kWebKitWebSecurityEnabled, 403 prefs->RegisterBooleanPref(prefs::kWebKitWebSecurityEnabled,
401 pref_defaults.web_security_enabled, 404 pref_defaults.web_security_enabled,
(...skipping 156 matching lines...) Expand 10 before | Expand all | Expand 10 after
558 561
559 void PrefsTabHelper::UpdateRendererPreferences() { 562 void PrefsTabHelper::UpdateRendererPreferences() {
560 renderer_preferences_util::UpdateFromSystemSettings( 563 renderer_preferences_util::UpdateFromSystemSettings(
561 web_contents_->GetMutableRendererPrefs(), GetProfile()); 564 web_contents_->GetMutableRendererPrefs(), GetProfile());
562 web_contents_->GetRenderViewHost()->SyncRendererPrefs(); 565 web_contents_->GetRenderViewHost()->SyncRendererPrefs();
563 } 566 }
564 567
565 Profile* PrefsTabHelper::GetProfile() { 568 Profile* PrefsTabHelper::GetProfile() {
566 return Profile::FromBrowserContext(web_contents_->GetBrowserContext()); 569 return Profile::FromBrowserContext(web_contents_->GetBrowserContext());
567 } 570 }
OLDNEW
« no previous file with comments | « chrome/browser/profiles/off_the_record_profile_impl.cc ('k') | chrome/renderer/page_load_histograms.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698