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

Side by Side Diff: webkit/glue/webpreferences.cc

Issue 9192021: Disallow WebSQL and localStorage in platform apps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: block localStorage Created 8 years, 11 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 | Annotate | Revision Log
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 "webkit/glue/webpreferences.h" 5 #include "webkit/glue/webpreferences.h"
6 6
7 #include <unicode/uchar.h> 7 #include <unicode/uchar.h>
8 8
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
(...skipping 193 matching lines...) Expand 10 before | Expand all | Expand 10 after
204 settings->setUserStyleSheetLocation(user_style_sheet_location); 204 settings->setUserStyleSheetLocation(user_style_sheet_location);
205 else 205 else
206 settings->setUserStyleSheetLocation(WebURL()); 206 settings->setUserStyleSheetLocation(WebURL());
207 settings->setAuthorAndUserStylesEnabled(author_and_user_styles_enabled); 207 settings->setAuthorAndUserStylesEnabled(author_and_user_styles_enabled);
208 settings->setUsesPageCache(uses_page_cache); 208 settings->setUsesPageCache(uses_page_cache);
209 settings->setDownloadableBinaryFontsEnabled(remote_fonts_enabled); 209 settings->setDownloadableBinaryFontsEnabled(remote_fonts_enabled);
210 settings->setJavaScriptCanAccessClipboard(javascript_can_access_clipboard); 210 settings->setJavaScriptCanAccessClipboard(javascript_can_access_clipboard);
211 settings->setXSSAuditorEnabled(xss_auditor_enabled); 211 settings->setXSSAuditorEnabled(xss_auditor_enabled);
212 settings->setDNSPrefetchingEnabled(dns_prefetching_enabled); 212 settings->setDNSPrefetchingEnabled(dns_prefetching_enabled);
213 settings->setLocalStorageEnabled(local_storage_enabled); 213 settings->setLocalStorageEnabled(local_storage_enabled);
214 WebRuntimeFeatures::enableDatabase( 214 WebRuntimeFeatures::enableDatabase(databases_enabled);
215 WebRuntimeFeatures::isDatabaseEnabled() || databases_enabled);
216 settings->setOfflineWebApplicationCacheEnabled(application_cache_enabled); 215 settings->setOfflineWebApplicationCacheEnabled(application_cache_enabled);
217 settings->setCaretBrowsingEnabled(caret_browsing_enabled); 216 settings->setCaretBrowsingEnabled(caret_browsing_enabled);
218 settings->setHyperlinkAuditingEnabled(hyperlink_auditing_enabled); 217 settings->setHyperlinkAuditingEnabled(hyperlink_auditing_enabled);
219 218
220 // This setting affects the behavior of links in an editable region: 219 // This setting affects the behavior of links in an editable region:
221 // clicking the link should select it rather than navigate to it. 220 // clicking the link should select it rather than navigate to it.
222 // Safari uses the same default. It is unlikley an embedder would want to 221 // Safari uses the same default. It is unlikley an embedder would want to
223 // change this, since it would break existing rich text editors. 222 // change this, since it would break existing rich text editors.
224 settings->setEditableLinkBehaviorNeverLive(); 223 settings->setEditableLinkBehaviorNeverLive();
225 224
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after
339 settings->setEnableScrollAnimator(enable_scroll_animator); 338 settings->setEnableScrollAnimator(enable_scroll_animator);
340 settings->setHixie76WebSocketProtocolEnabled( 339 settings->setHixie76WebSocketProtocolEnabled(
341 hixie76_websocket_protocol_enabled); 340 hixie76_websocket_protocol_enabled);
342 settings->setVisualWordMovementEnabled(visual_word_movement_enabled); 341 settings->setVisualWordMovementEnabled(visual_word_movement_enabled);
343 342
344 // Enable per-tile painting if requested on the command line. 343 // Enable per-tile painting if requested on the command line.
345 settings->setPerTilePaintingEnabled(per_tile_painting_enabled); 344 settings->setPerTilePaintingEnabled(per_tile_painting_enabled);
346 345
347 WebNetworkStateNotifier::setOnLine(is_online); 346 WebNetworkStateNotifier::setOnLine(is_online);
348 } 347 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698