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 423 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
434 GpuProcessHost::gpu_enabled() && | 434 GpuProcessHost::gpu_enabled() && |
435 !command_line.HasSwitch(switches::kDisableAccelerated2dCanvas); | 435 !command_line.HasSwitch(switches::kDisableAccelerated2dCanvas); |
436 prefs.antialiased_2d_canvas_disabled = | 436 prefs.antialiased_2d_canvas_disabled = |
437 command_line.HasSwitch(switches::kDisable2dCanvasAntialiasing); | 437 command_line.HasSwitch(switches::kDisable2dCanvasAntialiasing); |
438 prefs.antialiased_clips_2d_canvas_enabled = | 438 prefs.antialiased_clips_2d_canvas_enabled = |
439 command_line.HasSwitch(switches::kEnable2dCanvasClipAntialiasing); | 439 command_line.HasSwitch(switches::kEnable2dCanvasClipAntialiasing); |
440 prefs.accelerated_2d_canvas_msaa_sample_count = | 440 prefs.accelerated_2d_canvas_msaa_sample_count = |
441 atoi(command_line.GetSwitchValueASCII( | 441 atoi(command_line.GetSwitchValueASCII( |
442 switches::kAcceleratedCanvas2dMSAASampleCount).c_str()); | 442 switches::kAcceleratedCanvas2dMSAASampleCount).c_str()); |
443 | 443 |
| 444 prefs.inert_visual_viewport = |
| 445 command_line.HasSwitch(switches::kInertVisualViewport); |
| 446 |
444 prefs.pinch_overlay_scrollbar_thickness = 10; | 447 prefs.pinch_overlay_scrollbar_thickness = 10; |
445 prefs.use_solid_color_scrollbars = ui::IsOverlayScrollbarEnabled(); | 448 prefs.use_solid_color_scrollbars = ui::IsOverlayScrollbarEnabled(); |
446 | 449 |
447 #if defined(OS_ANDROID) | 450 #if defined(OS_ANDROID) |
448 // On Android, user gestures are normally required, unless that requirement | 451 // On Android, user gestures are normally required, unless that requirement |
449 // is disabled with a command-line switch or the equivalent field trial is | 452 // is disabled with a command-line switch or the equivalent field trial is |
450 // is set to "Enabled". | 453 // is set to "Enabled". |
451 const std::string autoplay_group_name = base::FieldTrialList::FindFullName( | 454 const std::string autoplay_group_name = base::FieldTrialList::FindFullName( |
452 "MediaElementAutoplay"); | 455 "MediaElementAutoplay"); |
453 prefs.user_gesture_required_for_media_playback = !command_line.HasSwitch( | 456 prefs.user_gesture_required_for_media_playback = !command_line.HasSwitch( |
(...skipping 933 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1387 } else { | 1390 } else { |
1388 render_view_ready_on_process_launch_ = true; | 1391 render_view_ready_on_process_launch_ = true; |
1389 } | 1392 } |
1390 } | 1393 } |
1391 | 1394 |
1392 void RenderViewHostImpl::RenderViewReady() { | 1395 void RenderViewHostImpl::RenderViewReady() { |
1393 delegate_->RenderViewReady(this); | 1396 delegate_->RenderViewReady(this); |
1394 } | 1397 } |
1395 | 1398 |
1396 } // namespace content | 1399 } // namespace content |
OLD | NEW |