| 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/renderer_host/render_view_host_impl.h" | 5 #include "content/browser/renderer_host/render_view_host_impl.h" |
| 6 | 6 |
| 7 #include <set> | 7 #include <set> |
| 8 #include <string> | 8 #include <string> |
| 9 #include <utility> | 9 #include <utility> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 444 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 455 GpuDataManagerImpl::GetInstance()->UpdateRendererWebPrefs(&prefs); | 455 GpuDataManagerImpl::GetInstance()->UpdateRendererWebPrefs(&prefs); |
| 456 | 456 |
| 457 if (ChildProcessSecurityPolicyImpl::GetInstance()->HasWebUIBindings( | 457 if (ChildProcessSecurityPolicyImpl::GetInstance()->HasWebUIBindings( |
| 458 GetProcess()->GetID())) { | 458 GetProcess()->GetID())) { |
| 459 prefs.loads_images_automatically = true; | 459 prefs.loads_images_automatically = true; |
| 460 prefs.javascript_enabled = true; | 460 prefs.javascript_enabled = true; |
| 461 } | 461 } |
| 462 | 462 |
| 463 prefs.is_online = !net::NetworkChangeNotifier::IsOffline(); | 463 prefs.is_online = !net::NetworkChangeNotifier::IsOffline(); |
| 464 | 464 |
| 465 prefs.fixed_position_creates_stacking_context = !command_line.HasSwitch( | |
| 466 switches::kDisableFixedPositionCreatesStackingContext); | |
| 467 | |
| 468 prefs.gesture_tap_highlight_enabled = !command_line.HasSwitch( | 465 prefs.gesture_tap_highlight_enabled = !command_line.HasSwitch( |
| 469 switches::kDisableGestureTapHighlight); | 466 switches::kDisableGestureTapHighlight); |
| 470 | 467 |
| 471 prefs.number_of_cpu_cores = base::SysInfo::NumberOfProcessors(); | 468 prefs.number_of_cpu_cores = base::SysInfo::NumberOfProcessors(); |
| 472 | 469 |
| 473 prefs.viewport_meta_enabled = | 470 prefs.viewport_meta_enabled = |
| 474 command_line.HasSwitch(switches::kEnableViewportMeta); | 471 command_line.HasSwitch(switches::kEnableViewportMeta); |
| 475 | 472 |
| 476 prefs.viewport_enabled = | 473 prefs.viewport_enabled = |
| 477 command_line.HasSwitch(switches::kEnableViewport) || | 474 command_line.HasSwitch(switches::kEnableViewport) || |
| (...skipping 1205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1683 FrameTree* frame_tree = delegate_->GetFrameTree(); | 1680 FrameTree* frame_tree = delegate_->GetFrameTree(); |
| 1684 | 1681 |
| 1685 frame_tree->ResetForMainFrameSwap(); | 1682 frame_tree->ResetForMainFrameSwap(); |
| 1686 } | 1683 } |
| 1687 | 1684 |
| 1688 void RenderViewHostImpl::SelectWordAroundCaret() { | 1685 void RenderViewHostImpl::SelectWordAroundCaret() { |
| 1689 Send(new ViewMsg_SelectWordAroundCaret(GetRoutingID())); | 1686 Send(new ViewMsg_SelectWordAroundCaret(GetRoutingID())); |
| 1690 } | 1687 } |
| 1691 | 1688 |
| 1692 } // namespace content | 1689 } // namespace content |
| OLD | NEW |