Chromium Code Reviews| Index: ui/compositor/compositor.cc |
| diff --git a/ui/compositor/compositor.cc b/ui/compositor/compositor.cc |
| index d864a02eb51d59b4c57cb60d7272a44edb708e07..df9e3461f95299c08b859f2babcda9ac3d800b1d 100644 |
| --- a/ui/compositor/compositor.cc |
| +++ b/ui/compositor/compositor.cc |
| @@ -93,8 +93,14 @@ Compositor::Compositor(gfx::AcceleratedWidget widget, |
| context_factory_->DoesCreateTestContexts() ? kTestRefreshRate |
| : kDefaultRefreshRate; |
| settings.main_frame_before_activation_enabled = false; |
| - settings.renderer_settings.disable_gpu_vsync = |
| - command_line->HasSwitch(switches::kDisableGpuVsync); |
| + if (command_line->HasSwitch(switches::kDisableGpuVsync)) { |
| + std::string displayVsyncStr = |
|
danakj
2015/07/14 19:43:42
display_vsync_string
Jimmy Jo
2015/07/15 00:47:27
Done.
|
| + command_line->GetSwitchValueASCII(switches::kDisableGpuVsync); |
| + settings.renderer_settings.disable_display_vsync = |
|
brianderson
2015/07/14 01:48:25
Might be easier to read this way:
if (displayVsyn
Jimmy Jo
2015/07/15 00:47:27
Done.
|
| + (displayVsyncStr == "gpu" || displayVsyncStr.empty()); |
| + settings.wait_for_beginframe_interval = |
| + !(displayVsyncStr == "beginframe" || displayVsyncStr.empty()); |
| + } |
| settings.renderer_settings.partial_swap_enabled = |
| !command_line->HasSwitch(cc::switches::kUIDisablePartialSwap); |
| #if defined(OS_WIN) |