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 "content/browser/web_contents/web_contents_impl.h" | 5 #include "content/browser/web_contents/web_contents_impl.h" |
6 | 6 |
7 #include <utility> | 7 #include <utility> |
8 | 8 |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/metrics/histogram.h" | 10 #include "base/metrics/histogram.h" |
(...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
497 prefs.accelerated_compositing_for_3d_transforms_enabled = | 497 prefs.accelerated_compositing_for_3d_transforms_enabled = |
498 prefs.accelerated_compositing_for_animation_enabled = | 498 prefs.accelerated_compositing_for_animation_enabled = |
499 !command_line.HasSwitch(switches::kDisableAcceleratedLayers); | 499 !command_line.HasSwitch(switches::kDisableAcceleratedLayers); |
500 prefs.accelerated_compositing_for_plugins_enabled = | 500 prefs.accelerated_compositing_for_plugins_enabled = |
501 !command_line.HasSwitch(switches::kDisableAcceleratedPlugins); | 501 !command_line.HasSwitch(switches::kDisableAcceleratedPlugins); |
502 prefs.accelerated_compositing_for_video_enabled = | 502 prefs.accelerated_compositing_for_video_enabled = |
503 !command_line.HasSwitch(switches::kDisableAcceleratedVideo); | 503 !command_line.HasSwitch(switches::kDisableAcceleratedVideo); |
504 prefs.fullscreen_enabled = | 504 prefs.fullscreen_enabled = |
505 !command_line.HasSwitch(switches::kDisableFullScreen); | 505 !command_line.HasSwitch(switches::kDisableFullScreen); |
506 prefs.css_sticky_position_enabled = | 506 prefs.css_sticky_position_enabled = |
507 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 507 command_line.HasSwitch(switches::kEnableExperimentalWebPlatformFeatures); |
508 prefs.css_shaders_enabled = | 508 prefs.css_shaders_enabled = |
509 command_line.HasSwitch(switches::kEnableCssShaders); | 509 command_line.HasSwitch(switches::kEnableCssShaders); |
510 prefs.css_variables_enabled = | 510 prefs.css_variables_enabled = |
511 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 511 command_line.HasSwitch(switches::kEnableExperimentalWebPlatformFeatures); |
512 prefs.css_grid_layout_enabled = | 512 prefs.css_grid_layout_enabled = |
513 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 513 command_line.HasSwitch(switches::kEnableExperimentalWebPlatformFeatures); |
514 prefs.lazy_layout_enabled = | 514 prefs.lazy_layout_enabled = |
515 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 515 command_line.HasSwitch(switches::kEnableExperimentalWebPlatformFeatures); |
516 | 516 |
517 // TODO(abarth, eseidel): Enable threaded_html_parser by default on Android | 517 // TODO(abarth, eseidel): Enable threaded_html_parser by default on Android |
518 // once crbug 230542 is resolved. | 518 // once crbug 230542 is resolved. |
519 #if defined(OS_ANDROID) | 519 #if defined(OS_ANDROID) |
520 prefs.threaded_html_parser = false; | 520 prefs.threaded_html_parser = false; |
521 #else | 521 #else |
522 prefs.threaded_html_parser = | 522 prefs.threaded_html_parser = |
523 !command_line.HasSwitch(switches::kDisableThreadedHTMLParser); | 523 !command_line.HasSwitch(switches::kDisableThreadedHTMLParser); |
524 #endif | 524 #endif |
525 | 525 |
(...skipping 2931 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3457 } | 3457 } |
3458 | 3458 |
3459 BrowserPluginGuestManager* | 3459 BrowserPluginGuestManager* |
3460 WebContentsImpl::GetBrowserPluginGuestManager() const { | 3460 WebContentsImpl::GetBrowserPluginGuestManager() const { |
3461 return static_cast<BrowserPluginGuestManager*>( | 3461 return static_cast<BrowserPluginGuestManager*>( |
3462 GetBrowserContext()->GetUserData( | 3462 GetBrowserContext()->GetUserData( |
3463 browser_plugin::kBrowserPluginGuestManagerKeyName)); | 3463 browser_plugin::kBrowserPluginGuestManagerKeyName)); |
3464 } | 3464 } |
3465 | 3465 |
3466 } // namespace content | 3466 } // namespace content |
OLD | NEW |