OLD | NEW |
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 "base/string_util.h" | 7 #include "base/string_util.h" |
8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNetworkStateNotifi
er.h" | 9 #include "third_party/WebKit/Source/WebKit/chromium/public/WebNetworkStateNotifi
er.h" |
10 #include "third_party/WebKit/Source/WebKit/chromium/public/WebRuntimeFeatures.h" | 10 #include "third_party/WebKit/Source/WebKit/chromium/public/WebRuntimeFeatures.h" |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 accelerated_painting_enabled(false), | 92 accelerated_painting_enabled(false), |
93 accelerated_filters_enabled(false), | 93 accelerated_filters_enabled(false), |
94 accelerated_plugins_enabled(false), | 94 accelerated_plugins_enabled(false), |
95 memory_info_enabled(false), | 95 memory_info_enabled(false), |
96 fullscreen_enabled(false), | 96 fullscreen_enabled(false), |
97 allow_displaying_insecure_content(true), | 97 allow_displaying_insecure_content(true), |
98 allow_running_insecure_content(false), | 98 allow_running_insecure_content(false), |
99 password_echo_enabled(false), | 99 password_echo_enabled(false), |
100 should_print_backgrounds(false), | 100 should_print_backgrounds(false), |
101 enable_scroll_animator(false), | 101 enable_scroll_animator(false), |
102 hixie76_websocket_protocol_enabled(false), | |
103 visual_word_movement_enabled(false), | 102 visual_word_movement_enabled(false), |
104 css_regions_enabled(false), | 103 css_regions_enabled(false), |
105 css_shaders_enabled(false), | 104 css_shaders_enabled(false), |
106 device_supports_touch(false), | 105 device_supports_touch(false), |
107 #if !defined(WEBCOMPOSITOR_OWNS_SETTINGS) | 106 #if !defined(WEBCOMPOSITOR_OWNS_SETTINGS) |
108 threaded_animation_enabled(false), | 107 threaded_animation_enabled(false), |
109 per_tile_painting_enabled(false), | 108 per_tile_painting_enabled(false), |
110 partial_swap_enabled(false), | 109 partial_swap_enabled(false), |
111 #endif | 110 #endif |
112 default_tile_width(256), | 111 default_tile_width(256), |
(...skipping 263 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
376 web_view->setTabsToLinks(tabs_to_links); | 375 web_view->setTabsToLinks(tabs_to_links); |
377 | 376 |
378 settings->setInteractiveFormValidationEnabled(true); | 377 settings->setInteractiveFormValidationEnabled(true); |
379 | 378 |
380 settings->setFullScreenEnabled(fullscreen_enabled); | 379 settings->setFullScreenEnabled(fullscreen_enabled); |
381 settings->setAllowDisplayOfInsecureContent(allow_displaying_insecure_content); | 380 settings->setAllowDisplayOfInsecureContent(allow_displaying_insecure_content); |
382 settings->setAllowRunningOfInsecureContent(allow_running_insecure_content); | 381 settings->setAllowRunningOfInsecureContent(allow_running_insecure_content); |
383 settings->setPasswordEchoEnabled(password_echo_enabled); | 382 settings->setPasswordEchoEnabled(password_echo_enabled); |
384 settings->setShouldPrintBackgrounds(should_print_backgrounds); | 383 settings->setShouldPrintBackgrounds(should_print_backgrounds); |
385 settings->setEnableScrollAnimator(enable_scroll_animator); | 384 settings->setEnableScrollAnimator(enable_scroll_animator); |
386 settings->setHixie76WebSocketProtocolEnabled( | |
387 hixie76_websocket_protocol_enabled); | |
388 settings->setVisualWordMovementEnabled(visual_word_movement_enabled); | 385 settings->setVisualWordMovementEnabled(visual_word_movement_enabled); |
389 | 386 |
390 settings->setExperimentalCSSRegionsEnabled(css_regions_enabled); | 387 settings->setExperimentalCSSRegionsEnabled(css_regions_enabled); |
391 settings->setExperimentalCSSCustomFilterEnabled(css_shaders_enabled); | 388 settings->setExperimentalCSSCustomFilterEnabled(css_shaders_enabled); |
392 | 389 |
393 settings->setDeviceSupportsTouch(device_supports_touch); | 390 settings->setDeviceSupportsTouch(device_supports_touch); |
394 | 391 |
395 #if !defined(WEBCOMPOSITOR_OWNS_SETTINGS) | 392 #if !defined(WEBCOMPOSITOR_OWNS_SETTINGS) |
396 settings->setThreadedAnimationEnabled(threaded_animation_enabled); | 393 settings->setThreadedAnimationEnabled(threaded_animation_enabled); |
397 | 394 |
398 // Enable per-tile painting if requested on the command line. | 395 // Enable per-tile painting if requested on the command line. |
399 settings->setPerTilePaintingEnabled(per_tile_painting_enabled); | 396 settings->setPerTilePaintingEnabled(per_tile_painting_enabled); |
400 | 397 |
401 // Enable partial swaps if specified form the command line. | 398 // Enable partial swaps if specified form the command line. |
402 settings->setPartialSwapEnabled(partial_swap_enabled); | 399 settings->setPartialSwapEnabled(partial_swap_enabled); |
403 #endif | 400 #endif |
404 | 401 |
405 settings->setDefaultTileSize( | 402 settings->setDefaultTileSize( |
406 WebSize(default_tile_width, default_tile_height)); | 403 WebSize(default_tile_width, default_tile_height)); |
407 settings->setMaxUntiledLayerSize( | 404 settings->setMaxUntiledLayerSize( |
408 WebSize(max_untiled_layer_width, max_untiled_layer_height)); | 405 WebSize(max_untiled_layer_width, max_untiled_layer_height)); |
409 | 406 |
410 settings->setFixedPositionCreatesStackingContext( | 407 settings->setFixedPositionCreatesStackingContext( |
411 fixed_position_creates_stacking_context); | 408 fixed_position_creates_stacking_context); |
412 | 409 |
413 WebNetworkStateNotifier::setOnLine(is_online); | 410 WebNetworkStateNotifier::setOnLine(is_online); |
414 } | 411 } |
415 | 412 |
416 } // namespace webkit_glue | 413 } // namespace webkit_glue |
OLD | NEW |