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 492 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
503 prefs.fullscreen_enabled = | 503 prefs.fullscreen_enabled = |
504 !command_line.HasSwitch(switches::kDisableFullScreen); | 504 !command_line.HasSwitch(switches::kDisableFullScreen); |
505 prefs.css_sticky_position_enabled = | 505 prefs.css_sticky_position_enabled = |
506 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 506 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); |
507 prefs.css_shaders_enabled = | 507 prefs.css_shaders_enabled = |
508 command_line.HasSwitch(switches::kEnableCssShaders); | 508 command_line.HasSwitch(switches::kEnableCssShaders); |
509 prefs.css_variables_enabled = | 509 prefs.css_variables_enabled = |
510 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 510 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); |
511 prefs.css_grid_layout_enabled = | 511 prefs.css_grid_layout_enabled = |
512 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 512 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); |
513 prefs.threaded_html_parser = false; | 513 prefs.threaded_html_parser = |
| 514 !command_line.HasSwitch(switches::kDisableThreadedHTMLParser); |
514 #if defined(OS_ANDROID) | 515 #if defined(OS_ANDROID) |
515 prefs.user_gesture_required_for_media_playback = !command_line.HasSwitch( | 516 prefs.user_gesture_required_for_media_playback = !command_line.HasSwitch( |
516 switches::kDisableGestureRequirementForMediaPlayback); | 517 switches::kDisableGestureRequirementForMediaPlayback); |
517 #endif | 518 #endif |
518 | 519 |
519 bool touch_device_present = false; | 520 bool touch_device_present = false; |
520 touch_device_present = ui::IsTouchDevicePresent(); | 521 touch_device_present = ui::IsTouchDevicePresent(); |
521 const std::string touch_enabled_switch = | 522 const std::string touch_enabled_switch = |
522 command_line.HasSwitch(switches::kTouchEvents) ? | 523 command_line.HasSwitch(switches::kTouchEvents) ? |
523 command_line.GetSwitchValueASCII(switches::kTouchEvents) : | 524 command_line.GetSwitchValueASCII(switches::kTouchEvents) : |
(...skipping 2969 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3493 | 3494 |
3494 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() const { | 3495 BrowserPluginGuest* WebContentsImpl::GetBrowserPluginGuest() const { |
3495 return browser_plugin_guest_.get(); | 3496 return browser_plugin_guest_.get(); |
3496 } | 3497 } |
3497 | 3498 |
3498 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() const { | 3499 BrowserPluginEmbedder* WebContentsImpl::GetBrowserPluginEmbedder() const { |
3499 return browser_plugin_embedder_.get(); | 3500 return browser_plugin_embedder_.get(); |
3500 } | 3501 } |
3501 | 3502 |
3502 } // namespace content | 3503 } // namespace content |
OLD | NEW |