Chromium Code Reviews| 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/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
| (...skipping 534 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 545 prefs.lazy_layout_enabled = | 545 prefs.lazy_layout_enabled = |
| 546 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); | 546 command_line.HasSwitch(switches::kEnableExperimentalWebKitFeatures); |
| 547 prefs.region_based_columns_enabled = | 547 prefs.region_based_columns_enabled = |
| 548 command_line.HasSwitch(switches::kEnableRegionBasedColumns); | 548 command_line.HasSwitch(switches::kEnableRegionBasedColumns); |
| 549 prefs.threaded_html_parser = | 549 prefs.threaded_html_parser = |
| 550 !command_line.HasSwitch(switches::kDisableThreadedHTMLParser); | 550 !command_line.HasSwitch(switches::kDisableThreadedHTMLParser); |
| 551 prefs.experimental_websocket_enabled = | 551 prefs.experimental_websocket_enabled = |
| 552 command_line.HasSwitch(switches::kEnableExperimentalWebSocket); | 552 command_line.HasSwitch(switches::kEnableExperimentalWebSocket); |
| 553 prefs.pinch_virtual_viewport_enabled = | 553 prefs.pinch_virtual_viewport_enabled = |
| 554 command_line.HasSwitch(cc::switches::kEnablePinchVirtualViewport); | 554 command_line.HasSwitch(cc::switches::kEnablePinchVirtualViewport); |
| 555 prefs.pinch_overlay_scrollbar_thickness = 10; | |
|
jamesr
2013/06/21 19:11:36
if we don't have pinch viewport enabled, why set t
| |
| 555 | 556 |
| 556 #if defined(OS_ANDROID) | 557 #if defined(OS_ANDROID) |
| 557 prefs.user_gesture_required_for_media_playback = !command_line.HasSwitch( | 558 prefs.user_gesture_required_for_media_playback = !command_line.HasSwitch( |
| 558 switches::kDisableGestureRequirementForMediaPlayback); | 559 switches::kDisableGestureRequirementForMediaPlayback); |
| 559 #endif | 560 #endif |
| 560 | 561 |
| 561 bool touch_device_present = false; | 562 bool touch_device_present = false; |
| 562 touch_device_present = ui::IsTouchDevicePresent(); | 563 touch_device_present = ui::IsTouchDevicePresent(); |
| 563 const std::string touch_enabled_switch = | 564 const std::string touch_enabled_switch = |
| 564 command_line.HasSwitch(switches::kTouchEvents) ? | 565 command_line.HasSwitch(switches::kTouchEvents) ? |
| (...skipping 3104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3669 } | 3670 } |
| 3670 | 3671 |
| 3671 BrowserPluginGuestManager* | 3672 BrowserPluginGuestManager* |
| 3672 WebContentsImpl::GetBrowserPluginGuestManager() const { | 3673 WebContentsImpl::GetBrowserPluginGuestManager() const { |
| 3673 return static_cast<BrowserPluginGuestManager*>( | 3674 return static_cast<BrowserPluginGuestManager*>( |
| 3674 GetBrowserContext()->GetUserData( | 3675 GetBrowserContext()->GetUserData( |
| 3675 browser_plugin::kBrowserPluginGuestManagerKeyName)); | 3676 browser_plugin::kBrowserPluginGuestManagerKeyName)); |
| 3676 } | 3677 } |
| 3677 | 3678 |
| 3678 } // namespace content | 3679 } // namespace content |
| OLD | NEW |