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

Side by Side Diff: chrome/browser/tab_contents/render_view_host_delegate_helper.cc

Issue 397038: For the 249 branch:... (Closed) Base URL: svn://chrome-svn/chrome/branches/249/src/
Patch Set: Created 11 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | chrome/common/chrome_switches.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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/tab_contents/render_view_host_delegate_helper.h" 5 #include "chrome/browser/tab_contents/render_view_host_delegate_helper.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/string_util.h" 8 #include "base/string_util.h"
9 #include "chrome/browser/browser.h" 9 #include "chrome/browser/browser.h"
10 #include "chrome/browser/character_encoding.h" 10 #include "chrome/browser/character_encoding.h"
(...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 prefs->GetBoolean(prefs::kWebKitPluginsEnabled); 166 prefs->GetBoolean(prefs::kWebKitPluginsEnabled);
167 web_prefs.java_enabled = 167 web_prefs.java_enabled =
168 !command_line.HasSwitch(switches::kDisableJava) && 168 !command_line.HasSwitch(switches::kDisableJava) &&
169 prefs->GetBoolean(prefs::kWebKitJavaEnabled); 169 prefs->GetBoolean(prefs::kWebKitJavaEnabled);
170 web_prefs.loads_images_automatically = 170 web_prefs.loads_images_automatically =
171 !command_line.HasSwitch(switches::kDisableImages) && 171 !command_line.HasSwitch(switches::kDisableImages) &&
172 prefs->GetBoolean(prefs::kWebKitLoadsImagesAutomatically); 172 prefs->GetBoolean(prefs::kWebKitLoadsImagesAutomatically);
173 web_prefs.uses_page_cache = 173 web_prefs.uses_page_cache =
174 command_line.HasSwitch(switches::kEnableFastback); 174 command_line.HasSwitch(switches::kEnableFastback);
175 web_prefs.remote_fonts_enabled = 175 web_prefs.remote_fonts_enabled =
176 command_line.HasSwitch(switches::kEnableRemoteFonts); 176 !command_line.HasSwitch(switches::kDisableRemoteFonts);
177 web_prefs.xss_auditor_enabled = 177 web_prefs.xss_auditor_enabled =
178 !command_line.HasSwitch(switches::kDisableXSSAuditor); 178 !command_line.HasSwitch(switches::kDisableXSSAuditor);
179 web_prefs.application_cache_enabled = 179 web_prefs.application_cache_enabled =
180 command_line.HasSwitch(switches::kEnableApplicationCache); 180 command_line.HasSwitch(switches::kEnableApplicationCache);
181 181
182 web_prefs.local_storage_enabled = 182 web_prefs.local_storage_enabled =
183 !command_line.HasSwitch(switches::kDisableLocalStorage); 183 !command_line.HasSwitch(switches::kDisableLocalStorage);
184 web_prefs.databases_enabled = 184 web_prefs.databases_enabled =
185 command_line.HasSwitch(switches::kEnableDatabases); 185 command_line.HasSwitch(switches::kEnableDatabases);
186 web_prefs.experimental_webgl_enabled = 186 web_prefs.experimental_webgl_enabled =
(...skipping 19 matching lines...) Expand all
206 } 206 }
207 DCHECK(!web_prefs.default_encoding.empty()); 207 DCHECK(!web_prefs.default_encoding.empty());
208 208
209 if (is_dom_ui) { 209 if (is_dom_ui) {
210 web_prefs.loads_images_automatically = true; 210 web_prefs.loads_images_automatically = true;
211 web_prefs.javascript_enabled = true; 211 web_prefs.javascript_enabled = true;
212 } 212 }
213 213
214 return web_prefs; 214 return web_prefs;
215 } 215 }
OLDNEW
« no previous file with comments | « no previous file | chrome/common/chrome_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698